in reply to Re^2: To DEBUG, or to COMMENT. _That_ is the question
in thread To DEBUG, or to COMMENT. _That_ is the question
The -P command-line switch was deprecated in perl version 5.10.0 and removed as of version 5.12.0 (see perl5120delta). But the equivalent behaviour is provided by the module Filter::cpp:
#! perl use strict; use warnings; use Filter::cpp; #define DEBUG #define XYZ 42 #ifdef DEBUG print "Debugging enabled\n"; #else print "Debugging disabled\n"; #endif print XYZ . "\n";
Output:
13:14 >perl 772_SoPW.pl Debugging enabled 42 13:14 >
See perlfilter.
| Athanasius <°(((>< contra mundum | Iustus alius egestas vitae, eros Piratica, |
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: To DEBUG, or to COMMENT. _That_ is the question
by chromatic (Archbishop) on Nov 09, 2013 at 17:50 UTC |