diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2009-12-08 13:48:19 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2009-12-08 13:48:19 -0800 |
commit | 08ee01ea9e6bd1bedd565f9e0e1c1a8938710887 (patch) | |
tree | 9d7c5017323261a681b8458b2dbd7ffe105e56fd /regex.c | |
parent | 0c86abee82a66963ec3c46e36c63ba8df89e1fa9 (diff) | |
download | txr-08ee01ea9e6bd1bedd565f9e0e1c1a8938710887.tar.gz txr-08ee01ea9e6bd1bedd565f9e0e1c1a8938710887.tar.bz2 txr-08ee01ea9e6bd1bedd565f9e0e1c1a8938710887.zip |
All COBJ operations have default implementations now;
no null pointer check over struct cobj_ops operations.
New typechecking function for COBJ objects.
Diffstat (limited to 'regex.c')
-rw-r--r-- | regex.c | 11 |
1 files changed, 5 insertions, 6 deletions
@@ -1136,11 +1136,6 @@ nfam_result_t nfa_machine_feed(nfa_machine_t *nfam, wchar_t ch) return NFAM_INCOMPLETE; } -static val regex_equal(val self, val other) -{ - return self == other ? t : nil; /* eq equality only */ -} - static void regex_destroy(val regex) { nfa_t *pnfa = (nfa_t *) regex->co.handle; @@ -1150,7 +1145,11 @@ static void regex_destroy(val regex) } static struct cobj_ops regex_obj_ops = { - regex_equal, cobj_print_op, regex_destroy, 0, 0 + cobj_equal_op, + cobj_print_op, + regex_destroy, + cobj_mark_op, + cobj_hash_op }; val regex_compile(val regex_sexp) |