use core::ffi::{c_char, c_int};

use super::sys_stat::__ygg_stat_t;

#[repr(C)]
pub struct FTW {
    pub base: c_int,
    pub level: c_int,
}

pub const FTW_F: c_int = 1;
pub const FTW_D: c_int = 2;
pub const FTW_DNR: c_int = 3;
pub const FTW_DP: c_int = 4;
pub const FTW_NS: c_int = 5;
pub const FTW_SL: c_int = 6;
pub const FTW_SLN: c_int = 7;

pub const FTW_PHYS: c_int = 1;
pub const FTW_MOUNT: c_int = 2;
pub const FTW_DEPTH: c_int = 3;
pub const FTW_CHDIR: c_int = 4;

pub type __ftw_func_t = extern "C" fn(*const c_char, *const __ygg_stat_t, c_int) -> c_int;
pub type __nftw_func_t =
    extern "C" fn(*const c_char, *const __ygg_stat_t, c_int, *mut FTW) -> c_int;

#[no_mangle]
unsafe extern "C" fn ftw(_dir: *const c_char, _func: __ftw_func_t, _fds: c_int) -> c_int {
    todo!("ftw()")
}

#[no_mangle]
unsafe extern "C" fn nftw(
    _dir: *const c_char,
    _func: __nftw_func_t,
    _fds: c_int,
    _flag: c_int,
) -> c_int {
    todo!("nftw()")
}
