Skip to content

Commit

Permalink
Added io.File.fd().
Browse files Browse the repository at this point in the history
io.File.fd() returns the file descriptor.
  • Loading branch information
shin1m committed Nov 16, 2023
1 parent 3d1ae97 commit 669f896
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/io__file.cc
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ void t_type_of<io::t_file>::f_define(t_io* a_library)
(L"seek"sv, t_member<intptr_t(io::t_file::*)(intptr_t, int), &io::t_file::f_seek>())
(a_library->f_symbol_read(), t_member<intptr_t(io::t_file::*)(t_bytes&, size_t, size_t), &io::t_file::f_read>())
(a_library->f_symbol_write(), t_member<size_t(io::t_file::*)(t_bytes&, size_t, size_t), &io::t_file::f_write>())
(L"fd"sv, t_member<int(io::t_file::*)() const, &io::t_file::f_fd>())
(L"tty"sv, t_member<bool(io::t_file::*)(), &io::t_file::f_tty>())
#ifdef __unix__
(L"blocking"sv, t_member<bool(io::t_file::*)(), &io::t_file::f_blocking>())
Expand Down

0 comments on commit 669f896

Please sign in to comment.