mirror of
https://github.com/reactos/reactos.git
synced 2024-12-27 17:44:45 +00:00
Updating files somehow confused by CVS.
Old tree cvs reports up-to-date. New tree - different ??? more to come... svn path=/trunk/; revision=3807
This commit is contained in:
parent
5f25774f6e
commit
2ebbba0d7d
16 changed files with 80 additions and 76 deletions
|
@ -7,17 +7,17 @@
|
|||
* UPDATE HISTORY:
|
||||
* 28/12/98: Created
|
||||
*/
|
||||
#include <crtdll/ctype.h>
|
||||
#include <msvcrt/ctype.h>
|
||||
|
||||
|
||||
#undef isalnum
|
||||
int isalnum(int c)
|
||||
{
|
||||
return _isctype(c,_ALPHA | _DIGIT);
|
||||
return _isctype(c,_ALPHA | _DIGIT);
|
||||
}
|
||||
|
||||
#undef iswalnum
|
||||
int iswalnum(wint_t c)
|
||||
{
|
||||
return iswctype(c,_ALPHA | _DIGIT);
|
||||
return iswctype(c,_ALPHA | _DIGIT);
|
||||
}
|
||||
|
|
|
@ -7,17 +7,17 @@
|
|||
* UPDATE HISTORY:
|
||||
* 28/12/98: Created
|
||||
*/
|
||||
#include <msvcrt/ctype.h>
|
||||
|
||||
#include <crtdll/ctype.h>
|
||||
|
||||
#undef isalpha
|
||||
int isalpha(int c)
|
||||
{
|
||||
return _isctype(c,_ALPHA);
|
||||
return _isctype(c, _ALPHA);
|
||||
}
|
||||
|
||||
#undef iswalpha
|
||||
int iswalpha(wint_t c)
|
||||
{
|
||||
return iswctype(c,_ALPHA);
|
||||
return iswctype(c, _ALPHA);
|
||||
}
|
||||
|
|
|
@ -1,14 +1,15 @@
|
|||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#include <crtdll/ctype.h>
|
||||
#include <msvcrt/ctype.h>
|
||||
|
||||
|
||||
#undef iscntrl
|
||||
int iscntrl(int c)
|
||||
{
|
||||
return _isctype(c,_CONTROL);
|
||||
return _isctype(c, _CONTROL);
|
||||
}
|
||||
|
||||
#undef iswcntrl
|
||||
int iswcntrl(wint_t c)
|
||||
{
|
||||
return iswctype(c,_CONTROL);
|
||||
return iswctype(c, _CONTROL);
|
||||
}
|
||||
|
|
|
@ -7,8 +7,8 @@
|
|||
* UPDATE HISTORY:
|
||||
* 28/12/98: Created
|
||||
*/
|
||||
#include <msvcrt/ctype.h>
|
||||
|
||||
#include <crtdll/ctype.h>
|
||||
|
||||
int __iscsymf(int c)
|
||||
{
|
||||
|
|
|
@ -1,14 +1,15 @@
|
|||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#include <crtdll/ctype.h>
|
||||
#include <msvcrt/ctype.h>
|
||||
|
||||
|
||||
#undef isdigit
|
||||
int isdigit(int c)
|
||||
{
|
||||
return _isctype(c,_DIGIT);
|
||||
return _isctype(c, _DIGIT);
|
||||
}
|
||||
|
||||
#undef iswdigit
|
||||
int iswdigit(wint_t c)
|
||||
{
|
||||
return iswctype(c,_DIGIT);
|
||||
return iswctype(c, _DIGIT);
|
||||
}
|
||||
|
|
|
@ -1,13 +1,14 @@
|
|||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#include <crtdll/ctype.h>
|
||||
#include <msvcrt/ctype.h>
|
||||
|
||||
|
||||
#undef islower
|
||||
int islower(int c)
|
||||
{
|
||||
return _isctype(c,_LOWER);
|
||||
return _isctype(c, _LOWER);
|
||||
}
|
||||
|
||||
int iswlower(wint_t c)
|
||||
{
|
||||
return iswctype(c,_LOWER);
|
||||
return iswctype(c, _LOWER);
|
||||
}
|
||||
|
|
|
@ -1,14 +1,15 @@
|
|||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#include <crtdll/ctype.h>
|
||||
#include <msvcrt/ctype.h>
|
||||
|
||||
|
||||
#undef ispunct
|
||||
int ispunct(int c)
|
||||
{
|
||||
return _isctype(c,_PUNCT);
|
||||
return _isctype(c, _PUNCT);
|
||||
}
|
||||
|
||||
#undef iswpunct
|
||||
int iswpunct(wint_t c)
|
||||
{
|
||||
return iswctype(c,_PUNCT);
|
||||
return iswctype(c, _PUNCT);
|
||||
}
|
||||
|
|
|
@ -1,13 +1,14 @@
|
|||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#include <crtdll/ctype.h>
|
||||
#include <msvcrt/ctype.h>
|
||||
|
||||
|
||||
#undef isupper
|
||||
int isupper(int c)
|
||||
{
|
||||
return _isctype(c,_UPPER);
|
||||
return _isctype(c, _UPPER);
|
||||
}
|
||||
|
||||
int iswupper(wint_t c)
|
||||
{
|
||||
return iswctype(c,_UPPER);
|
||||
return iswctype(c, _UPPER);
|
||||
}
|
||||
|
|
|
@ -1,15 +1,16 @@
|
|||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#include <crtdll/ctype.h>
|
||||
#include <msvcrt/ctype.h>
|
||||
|
||||
|
||||
#undef isxdigit
|
||||
int isxdigit(int c)
|
||||
{
|
||||
return _isctype(c,_HEX);
|
||||
return _isctype(c, _HEX);
|
||||
}
|
||||
|
||||
#undef iswxdigit
|
||||
int iswxdigit(wint_t c)
|
||||
{
|
||||
return iswctype(c,_HEX);
|
||||
return iswctype(c, _HEX);
|
||||
}
|
||||
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
|
||||
#include <crtdll/ctype.h>
|
||||
#include <msvcrt/ctype.h>
|
||||
|
||||
|
||||
int __toascii(int c)
|
||||
{
|
||||
return ((unsigned)(c) & 0x7F );
|
||||
return((unsigned)(c) & 0x7F);
|
||||
}
|
||||
|
|
|
@ -1,10 +1,12 @@
|
|||
#include <crtdll/float.h>
|
||||
#include <crtdll/internal/ieee.h>
|
||||
#include <msvcrt/float.h>
|
||||
#include <msvcrt/internal/ieee.h>
|
||||
|
||||
double _chgsign( double __x )
|
||||
|
||||
double _chgsign(double __x)
|
||||
{
|
||||
double_t *x = (double_t *)&x;
|
||||
if ( x->sign == 1 )
|
||||
double_t* x = (double_t*)&x;
|
||||
|
||||
if (x->sign == 1)
|
||||
x->sign = 0;
|
||||
else
|
||||
x->sign = 1;
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
#include <crtdll/float.h>
|
||||
#include <crtdll/math.h>
|
||||
#include <crtdll/internal/ieee.h>
|
||||
#include <msvcrt/float.h>
|
||||
#include <msvcrt/math.h>
|
||||
#include <msvcrt/internal/ieee.h>
|
||||
|
||||
|
||||
#define _FPCLASS_SNAN 0x0001 /* signaling NaN */
|
||||
#define _FPCLASS_QNAN 0x0002 /* quiet NaN */
|
||||
|
@ -28,38 +29,35 @@ typedef int fpclass_t;
|
|||
|
||||
fpclass_t _fpclass(double __d)
|
||||
{
|
||||
double_t *d = (double_t *)&__d;
|
||||
double_t* d = (double_t*)&__d;
|
||||
|
||||
if ( d->exponent == 0 ) {
|
||||
if ( d->mantissah == 0 && d->mantissal == 0 ) {
|
||||
if ( d->sign ==0 )
|
||||
if (d->exponent == 0) {
|
||||
if (d->mantissah == 0 && d->mantissal == 0) {
|
||||
if (d->sign ==0)
|
||||
return FP_NZERO;
|
||||
else
|
||||
return FP_PZERO;
|
||||
} else {
|
||||
if ( d->sign ==0 )
|
||||
if (d->sign ==0)
|
||||
return FP_NDENORM;
|
||||
else
|
||||
return FP_PDENORM;
|
||||
}
|
||||
}
|
||||
if (d->exponent == 0x7ff ) {
|
||||
if ( d->mantissah == 0 && d->mantissal == 0 ) {
|
||||
if ( d->sign ==0 )
|
||||
if (d->exponent == 0x7ff) {
|
||||
if (d->mantissah == 0 && d->mantissal == 0) {
|
||||
if (d->sign ==0)
|
||||
return FP_NINF;
|
||||
else
|
||||
return FP_PINF;
|
||||
}
|
||||
else if ( d->mantissah == 0 && d->mantissal != 0 ) {
|
||||
else if (d->mantissah == 0 && d->mantissal != 0) {
|
||||
return FP_QNAN;
|
||||
}
|
||||
else if ( d->mantissah == 0 && d->mantissal != 0 ) {
|
||||
else if (d->mantissah == 0 && d->mantissal != 0) {
|
||||
return FP_SNAN;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
#include <crtdll/float.h>
|
||||
#include <msvcrt/float.h>
|
||||
|
||||
void _fpreset (void)
|
||||
|
||||
void _fpreset(void)
|
||||
{
|
||||
/* FIXME: This causes an exception */
|
||||
// __asm__ __volatile__("fninit\n\t");
|
||||
|
|
|
@ -16,43 +16,40 @@ License along with the GNU C Library; see the file COPYING.LIB. If
|
|||
not, write to the Free Software Foundation, Inc., 675 Mass Ave,
|
||||
Cambridge, MA 02139, USA. */
|
||||
|
||||
#include <crtdll/math.h>
|
||||
#include <crtdll/float.h>
|
||||
#include <crtdll/internal/ieee.h>
|
||||
#include <msvcrt/math.h>
|
||||
#include <msvcrt/float.h>
|
||||
#include <msvcrt/internal/ieee.h>
|
||||
|
||||
|
||||
int _isnan(double __x)
|
||||
{
|
||||
double_t * x = (double_t *)&__x;
|
||||
return ( x->exponent == 0x7ff && ( x->mantissah != 0 || x->mantissal != 0 ));
|
||||
double_t* x = (double_t*)&__x;
|
||||
return (x->exponent == 0x7ff && (x->mantissah != 0 || x->mantissal != 0));
|
||||
}
|
||||
|
||||
int _isnanl(long double __x)
|
||||
{
|
||||
|
||||
/* Intel's extended format has the normally implicit 1 explicit
|
||||
present. Sigh! */
|
||||
|
||||
long_double_t * x = (long_double_t *)&__x;
|
||||
long_double_t* x = (long_double_t*)&__x;
|
||||
|
||||
|
||||
/* IEEE 854 NaN's have the maximum possible
|
||||
exponent and a nonzero mantissa. */
|
||||
|
||||
return (( x->exponent == 0x7fff)
|
||||
&& ( (x->mantissah & 0x80000000) != 0)
|
||||
&& ( (x->mantissah & (unsigned int)0x7fffffff) != 0 || x->mantissal != 0 ));
|
||||
&& ((x->mantissah & 0x80000000) != 0)
|
||||
&& ((x->mantissah & (unsigned int)0x7fffffff) != 0 || x->mantissal != 0));
|
||||
}
|
||||
|
||||
|
||||
int _isinf(double __x)
|
||||
{
|
||||
double_t * x = (double_t *)&__x;
|
||||
return ( x->exponent == 0x7ff && ( x->mantissah == 0 && x->mantissal == 0 ));
|
||||
double_t* x = (double_t*)&__x;
|
||||
return (x->exponent == 0x7ff && (x->mantissah == 0 && x->mantissal == 0));
|
||||
}
|
||||
|
||||
|
||||
|
||||
int _finite( double x )
|
||||
int _finite(double x)
|
||||
{
|
||||
return !_isinf(x);
|
||||
}
|
||||
|
@ -62,16 +59,14 @@ int _isinfl(long double __x)
|
|||
/* Intel's extended format has the normally implicit 1 explicit
|
||||
present. Sigh! */
|
||||
|
||||
long_double_t * x = (long_double_t *)&__x;
|
||||
long_double_t* x = (long_double_t*)&__x;
|
||||
|
||||
|
||||
/* An IEEE 854 infinity has an exponent with the
|
||||
maximum possible value and a zero mantissa. */
|
||||
|
||||
|
||||
if ( x->exponent == 0x7fff && ( (x->mantissah == 0x80000000 ) && x->mantissal == 0 ))
|
||||
if (x->exponent == 0x7fff && ((x->mantissah == 0x80000000) && x->mantissal == 0))
|
||||
return x->sign ? -1 : 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -1,11 +1,12 @@
|
|||
#include <crtdll/float.h>
|
||||
#include <msvcrt/float.h>
|
||||
|
||||
double _nextafter( double x, double y )
|
||||
|
||||
double _nextafter(double x, double y)
|
||||
{
|
||||
if ( x == y)
|
||||
if (x == y)
|
||||
return x;
|
||||
|
||||
if ( isnan(x) || isnan(y) )
|
||||
if (isnan(x) || isnan(y))
|
||||
return x;
|
||||
|
||||
return x;
|
||||
|
|
|
@ -1,10 +1,11 @@
|
|||
#include <windows.h>
|
||||
#include <crtdll/io.h>
|
||||
#include <msvcrt/io.h>
|
||||
|
||||
int _locking( int _fd, int mode, long nbytes )
|
||||
|
||||
int _locking(int _fd, int mode, long nbytes)
|
||||
{
|
||||
long offset = _lseek(_fd, 0L, 1);
|
||||
if ( !LockFile(_get_osfhandle(_fd),offset,0,nbytes,0) )
|
||||
if (!LockFile(_get_osfhandle(_fd),offset,0,nbytes,0))
|
||||
return -1;
|
||||
|
||||
return 0;
|
||||
|
|
Loading…
Reference in a new issue