From 98c35bb3a760c7adcce27fceb35720d4f503379f Mon Sep 17 00:00:00 2001 From: Arendelle Date: Sun, 23 Nov 2025 09:23:33 +0800 Subject: [PATCH] fix bug caused by MacroModel - a week ago, MacroModel want to merge a huge pr, which edited here I have no idea why he did this change, or simply a bug-scanner ai reported this "problem" - Following error messages just to prove why this patch exists: In file included from ..\include/fast_io/fast_io.h:10: In file included from ..\include/fast_io/fast_io_hosted.h:69: In file included from ..\include/fast_io/fast_io_hosted/platforms/native.h:3: In file included from ..\include/fast_io/fast_io_hosted/platforms/native_base.h:27: In file included from ..\include/fast_io/fast_io_hosted/platforms/posix.h:46: ..\include/fast_io/fast_io_hosted/platforms/systemcall_details.h:34:3: error: no member named 'dup' in the global namespace; did you mean simply 'dup'? 34 | ::dup | ^~~~~ | dup ..\include/fast_io/fast_io_hosted/platforms/systemcall_details.h:11:12: note: 'dup' declared here 11 | inline int dup(int) noexcept | ^ 1 error generated. --- include/fast_io_hosted/platforms/systemcall_details.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/fast_io_hosted/platforms/systemcall_details.h b/include/fast_io_hosted/platforms/systemcall_details.h index 9675aafe..d0560f5a 100644 --- a/include/fast_io_hosted/platforms/systemcall_details.h +++ b/include/fast_io_hosted/platforms/systemcall_details.h @@ -29,9 +29,9 @@ inline int sys_dup(int old_fd) #else auto fd{noexcept_call( #if defined(_WIN32) && !defined(__BIONIC__) - ::_dup + _dup #else - ::dup + dup #endif , old_fd)};