#892: PARROT_IN_OBJECTS_C used only in one file
----------------------+-----------------------------------------------------
 Reporter:  NotFound  |       Owner:       
     Type:  RFC       |      Status:  new  
 Priority:  normal    |   Milestone:       
Component:  none      |     Version:  1.4.0
 Severity:  medium    |    Keywords:       
     Lang:            |       Patch:       
 Platform:            |  
----------------------+-----------------------------------------------------
 In include/parrot/vtable.h there is conditional block undef #ifdef
 PARROT_IN_OBJECTS_C

 PARROT_IN_OBJECTS_C is defined only in src/oo.c, and also in
 src/pmc/class.pmc, but that last usage is wrong. Looking at the generated
 class.c code, the define is done longer after vtable.h has been included.
 Deleting it has no effect.

 The only real usage is in src/oo.c, then. The definitions inside the
 vtable.h block are the PARROT_VTABLE_LOW and NUM_VTABLE_FUNCTIONS macros,
 and the array Parrot_vtable_slot_names. ack'ing for these symbols, they
 are used only in oo.c, and mentioned in few comments elsewhere. The other
 practical usages of the PARROT_VTABLE_LOW value ( 9 ) are handled by the
 code generators and C doesn't see it.

 So I suggest to move that definitions to another file, to avoid having
 that confusing conditional in such an important header.

-- 
Ticket URL: <https://trac.parrot.org/parrot/ticket/892>
Parrot <https://trac.parrot.org/parrot/>
Parrot Development
_______________________________________________
parrot-tickets mailing list
[email protected]
http://lists.parrot.org/mailman/listinfo/parrot-tickets

Reply via email to