File tree Expand file tree Collapse file tree 5 files changed +16
-6
lines changed
fast_io_freestanding_impl/transcoders Expand file tree Collapse file tree 5 files changed +16
-6
lines changed Original file line number Diff line number Diff line change @@ -234,7 +234,7 @@ class basic_transcoder_file : public transcoder_io_observer
234234 other.transhandle = nullptr ;
235235 return *this ;
236236 }
237- inline constexpr void close () noexcept
237+ inline constexpr void close ()
238238 {
239239 this ->transhandle ->destroy ();
240240 this ->transhandle = nullptr ;
Original file line number Diff line number Diff line change 6262namespace fast_io
6363{
6464
65+ namespace posix
66+ {
67+ #if defined(__DARWIN_C_LEVEL) || defined(__MSDOS__)
68+ extern int libc_ioctl (int fd, unsigned long request, ...) noexcept __asm__(" _ioctl" );
69+ #else
70+ extern int libc_ioctl (int fd, unsigned long request, ...) noexcept __asm__(" ioctl" );
71+ #endif
72+ } // namespace posix
73+
6574enum class posix_family
6675{
6776 api,
Original file line number Diff line number Diff line change @@ -291,7 +291,7 @@ class posix_memory_map_file
291291 {
292292 return address_begin[pos];
293293 }
294- inline void close () noexcept
294+ inline void close ()
295295 {
296296 if (this ->address_begin != MAP_FAILED) [[likely]]
297297 {
Original file line number Diff line number Diff line change @@ -1234,7 +1234,7 @@ class win32_9xa_dir_io_observer
12341234 {
12351235 return handle;
12361236 }
1237- inline explicit operator bool () const noexcept
1237+ inline explicit constexpr operator bool () const noexcept
12381238 {
12391239 return !handle.path .empty ();
12401240 }
@@ -1244,6 +1244,7 @@ class win32_9xa_dir_io_observer
12441244 return temp;
12451245 }
12461246};
1247+
12471248inline constexpr bool operator ==(win32_9xa_dir_io_observer const &a,
12481249 win32_9xa_dir_io_observer const &b) noexcept
12491250{
@@ -1310,11 +1311,11 @@ class win32_9xa_dir_file : public win32_9xa_dir_io_observer
13101311 }
13111312 this ->handle = ::std::move (newhandle);
13121313 }
1313- inline void close () noexcept
1314+ inline void close ()
13141315 {
13151316 if (*this ) [[likely]]
13161317 {
1317- ::fast_io::win32::details::close_win32_9xa_dir_handle (this ->handle);
1318+ ::fast_io::win32::details::close_win32_9xa_dir_handle< true > (this ->handle );
13181319 }
13191320 }
13201321
Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ inline int my_random_entropy(int fd) noexcept
4949 return 0 ;
5050 }
5151#else
52- if (::fast_io::posix::ioctl (fd, RNDGETENTCNT, __builtin_addressof (ent)) != 0 )
52+ if (::fast_io::posix::libc_ioctl (fd, RNDGETENTCNT, __builtin_addressof (ent)) != 0 )
5353 {
5454 return 0 ;
5555 }
You can’t perform that action at this time.
0 commit comments