#152: Do we need PARROT_CATCH_NULL?
--------------------+-------------------------------------------------------
Reporter: coke | Owner: whiteknight
Type: RFC | Status: new
Priority: minor | Milestone:
Component: core | Version:
Severity: medium | Keywords:
Lang: | Patch:
Platform: |
--------------------+-------------------------------------------------------
Comment(by jkeenan):
Replying to [comment:3 cotto]:
> I don't see any value in making this a configure-time option. It may be
needed for splint, but if not it'd be easiest just to rip it out
wholesale.
Here are the current locations for `PARROT_CATCH_NULL` in our source code:
{{{
$ ack -A2 PARROT_CATCH_NULL *
include/parrot/interpreter.h
296:#ifndef PARROT_CATCH_NULL
297-# ifdef S_SPLINT_S
298:# define PARROT_CATCH_NULL 0
299-# else
300:# define PARROT_CATCH_NULL 1
301-# endif
302-#endif
--
305:#if PARROT_CATCH_NULL
306-PARROT_DATA PMC *PMCNULL; /* Holds single Null PMC */
307-PARROT_DATA STRING *STRINGNULL; /* a single Null STRING */
--
315:#endif /* PARROT_CATCH_NULL */
316-
317-#define STRING_IS_EMPTY(s) ((s)->strlen == 0)
src/interp/inter_create.c
140:#if PARROT_CATCH_NULL
141- PMCNULL = NULL;
142-#endif
src/pmc.c
67:#if PARROT_CATCH_NULL
68-PMC * PMCNULL;
69-#endif
--
90:#if PARROT_CATCH_NULL
91- return pmc == PMCNULL || pmc == NULL;
92-#else
src/string/api.c
32:#if PARROT_CATCH_NULL
33-STRING *STRINGNULL;
34-#endif
--
159:#if PARROT_CATCH_NULL
160- /* initialize STRINGNULL, but not in the constant table */
161- STRINGNULL = Parrot_str_new_init(interp, NULL, 0,
}}}
Can someone evaluate the implications of ripping it out? Will it require
deprecation cycle?
Thank you very much.
kid51
--
Ticket URL: <https://trac.parrot.org/parrot/ticket/152#comment:4>
Parrot <https://trac.parrot.org/parrot/>
Parrot Development
_______________________________________________
parrot-tickets mailing list
[email protected]
http://lists.parrot.org/mailman/listinfo/parrot-tickets