The R Project SVN R

Rev

Rev 42402 | Rev 43160 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 42402 Rev 42452
Line 331... Line 331...
331
typedef struct SEXPREC *SEXP;
331
typedef struct SEXPREC *SEXP;
332
 
332
 
333
#define CHAR(x)		R_CHAR(x)
333
#define CHAR(x)		R_CHAR(x)
334
const char *(R_CHAR)(SEXP x);
334
const char *(R_CHAR)(SEXP x);
335
 
335
 
336
/* Various tests, with macro versions in Defn.h */
336
/* Various tests with macro versions below */
337
Rboolean (Rf_isNull)(SEXP s);
337
Rboolean (Rf_isNull)(SEXP s);
338
Rboolean (Rf_isSymbol)(SEXP s);
338
Rboolean (Rf_isSymbol)(SEXP s);
339
Rboolean (Rf_isLogical)(SEXP s);
339
Rboolean (Rf_isLogical)(SEXP s);
340
Rboolean (Rf_isReal)(SEXP s);
340
Rboolean (Rf_isReal)(SEXP s);
341
Rboolean (Rf_isComplex)(SEXP s);
341
Rboolean (Rf_isComplex)(SEXP s);
Line 995... Line 995...
995
SEXP	 Rf_ScalarRaw(Rbyte);
995
SEXP	 Rf_ScalarRaw(Rbyte);
996
SEXP	 Rf_ScalarReal(double);
996
SEXP	 Rf_ScalarReal(double);
997
SEXP	 Rf_ScalarString(SEXP);
997
SEXP	 Rf_ScalarString(SEXP);
998
#endif
998
#endif
999
 
999
 
-
 
1000
#ifdef USE_RINTERNALS
-
 
1001
 
-
 
1002
/* Test macros with function versions above */
-
 
1003
#undef isNull
-
 
1004
#define isNull(s)	(TYPEOF(s) == NILSXP)
-
 
1005
#undef isSymbol
-
 
1006
#define isSymbol(s)	(TYPEOF(s) == SYMSXP)
-
 
1007
#undef isLogical
-
 
1008
#define isLogical(s)	(TYPEOF(s) == LGLSXP)
-
 
1009
#undef isReal
-
 
1010
#define isReal(s)	(TYPEOF(s) == REALSXP)
-
 
1011
#undef isComplex
-
 
1012
#define isComplex(s)	(TYPEOF(s) == CPLXSXP)
-
 
1013
#undef isExpression
-
 
1014
#define isExpression(s) (TYPEOF(s) == EXPRSXP)
-
 
1015
#undef isEnvironment
-
 
1016
#define isEnvironment(s) (TYPEOF(s) == ENVSXP)
-
 
1017
#undef isString
-
 
1018
#define isString(s)	(TYPEOF(s) == STRSXP)
-
 
1019
#undef isObject
-
 
1020
#define isObject(s)	(OBJECT(s) != 0)
-
 
1021
 
-
 
1022
#endif
-
 
1023
 
1000
 
1024
 
1001
#ifdef __cplusplus
1025
#ifdef __cplusplus
1002
}
1026
}
1003
#endif
1027
#endif
1004
 
1028