c_long ftell(FILE* stream);
}
-version (MinGW)
-{
- // No unsafe pointer manipulation.
- extern (D) @trusted
- {
- ///
- void rewind()(FILE* stream) { fseek(stream,0L,SEEK_SET); stream._flag = stream._flag & ~_IOERR; }
- ///
- pure void clearerr()(FILE* stream) { stream._flag = stream._flag & ~(_IOERR|_IOEOF); }
- ///
- pure int feof()(FILE* stream) { return stream._flag&_IOEOF; }
- ///
- pure int ferror()(FILE* stream) { return stream._flag&_IOERR; }
- }
- ///
- int __mingw_snprintf(scope char* s, size_t n, scope const char* fmt, ...);
- ///
- alias __mingw_snprintf _snprintf;
- ///
- alias __mingw_snprintf snprintf;
-
- ///
- int __mingw_vsnprintf(scope char* s, size_t n, scope const char* format, va_list arg);
- ///
- alias __mingw_vsnprintf _vsnprintf;
- ///
- alias __mingw_vsnprintf vsnprintf;
-}
-else version (CRuntime_DigitalMars)
+version (CRuntime_DigitalMars)
{
// No unsafe pointer manipulation.
extern (D) @trusted
pure int fileno(FILE* stream);
}
+ version (MinGW)
+ {
+ int __mingw_snprintf(scope char* s, size_t n, scope const char* fmt, ...);
+ ///
+ alias __mingw_snprintf _snprintf;
+ ///
+ alias __mingw_snprintf snprintf;
+
+ ///
+ int __mingw_vsnprintf(scope char* s, size_t n, scope const char* format, va_list arg);
+ ///
+ alias __mingw_vsnprintf _vsnprintf;
+ ///
+ alias __mingw_vsnprintf vsnprintf;
+ }
+ else
+ {
///
int _snprintf(scope char* s, size_t n, scope const char* format, ...);
///
int _vsnprintf(scope char* s, size_t n, scope const char* format, va_list arg);
///
int vsnprintf(scope char* s, size_t n, scope const char* format, va_list arg);
+ }
///
int _fputc_nolock(int c, FILE *fp);
import core.sys.solaris.sys.types;
}
-// this should be true for most architectures
-version (GNU_StackGrowsDown)
+version (GNU)
+{
+ import gcc.builtins;
+ version (GNU_StackGrowsDown)
+ version = StackGrowsDown;
+}
+else
+{
+ // this should be true for most architectures
version = StackGrowsDown;
+}
/**
* Returns the process ID of the calling process, which is guaranteed to be
import core.sys.darwin.pthread : pthread_mach_thread_np;
}
- version (GNU)
- {
- import gcc.builtins;
- }
-
//
// Entry point for POSIX threads
//
version = InlineAsm_X86_Any;
}
+version (CRuntime_Microsoft)
+{
+ version (InlineAsm_X86_Any)
+ version = MSVC_InlineAsm;
+}
+
version (X86_64) version = StaticallyHaveSSE;
version (X86) version (OSX) version = StaticallyHaveSSE;
ret ;
}
}
- else version (CRuntime_Microsoft)
+ else version (MSVC_InlineAsm)
{
asm pure nothrow @nogc
{
ret ;
}
}
- else version (CRuntime_Microsoft)
+ else version (MSVC_InlineAsm)
{
short cw;
asm pure nothrow @nogc
ret ;
}
}
- else version (CRuntime_Microsoft)
+ else version (MSVC_InlineAsm)
{
short cw;
asm pure nothrow @nogc
ret ;
}
}
- else version (CRuntime_Microsoft)
+ else version (MSVC_InlineAsm)
{
short cw;
asm pure nothrow @nogc