in reply to Secret POD docs

UPDATE: Merlyn's code above out does what I say here! Listen to merlyn.

I know of no secret pod tags, but you could use a pod hack like the following. I wouldn't recommend it, but it does allow for you to hide at least one line from the pod. The basic premise is -- use a bogus tag and the the perl parser will treat it like but pod parser will ignore it. Anything on the same line as that bogus tag will also get ignored. Not good in wide practice.
#!/usr/bin/perl -w =head1 Some function or other =cut sub foo { } =bogustag1 Yet Another function 1 =cut sub foo2 { } =bogustag2 Yet Another function =cut sub foo3 { }

What was wrong with using "#"'s again?

my @a=qw(random brilliant braindead); print $a[rand(@a)];

Replies are listed 'Best First'.
Re: Re: Secret POD docs
by petdance (Parson) on May 07, 2001 at 19:39 UTC
    What was wrong with using "#"'s again?

    I don't want to code my docs differently depending on whether the docs will be visible to the outside world or not.

    xoxo,
    Andy

    %_=split/;/,".;;n;u;e;ot;t;her;c; ".   #   Andy Lester
    'Perl ;@; a;a;j;m;er;y;t;p;n;d;s;o;'.  #   http://petdance.com
    "hack";print map delete$_{$_},split//,q<   andy@petdance.com   >
    
      You've now got conflicting requirements. Can you step back and specify what you want, instead of potshotting at the solutions because it's what you don't want?

      If you want pod tools that have an ifdef, you'll need to write them.

      If you want existing pod tools to work, you'll need to code your internal stuff as non-POD.

      There's no "third solution".

      -- Randal L. Schwartz, Perl hacker