aboutsummaryrefslogtreecommitdiff
path: root/model.h
diff options
context:
space:
mode:
authorTeddy <ted.sybil@gmail.com>2013-08-06 19:11:22 +0800
committerTeddy <ted.sybil@gmail.com>2013-08-06 19:11:22 +0800
commit3406f0a979e2465a993b20c2eb1033729c6a787c (patch)
treed37e6148a211732fc3d59ca428d2bef7309736b8 /model.h
parent033b938b22c7947992195e380fb2f7d1ca200f05 (diff)
added and restructured built-in procedures
Diffstat (limited to 'model.h')
-rw-r--r--model.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/model.h b/model.h
index 0fcf5d3..8a8fc61 100644
--- a/model.h
+++ b/model.h
@@ -24,6 +24,7 @@ const int CLS_CONS_OBJ = 1 << 1;
const int CLS_SYM_OBJ = 1 << 2;
const int CLS_OPT_OBJ = 1 << 3;
const int CLS_NUM_OBJ = 1 << 4;
+const int CLS_BOOL_OBJ = 1 << 5;
#define TO_CONS(ptr) \
@@ -96,6 +97,8 @@ class EvalObj : public FrameObj {
bool is_cons_obj();
/** Check if the object is a number */
bool is_num_obj();
+ /** Check if the object is a boolean */
+ bool is_bool_obj();
virtual void prepare(Cons *pc);
/** Any EvalObj has its external representation */
virtual string ext_repr() = 0;
@@ -247,7 +250,7 @@ class SpecialOptObj: public OptObj {
SpecialOptObj();
};
-typedef EvalObj* (*BuiltinProc)(ArgList *);
+typedef EvalObj* (*BuiltinProc)(ArgList *, const string &);
/** @class BuiltinProcObj
* Wrapping class for builtin procedures (arithmetic operators, etc.)
*/