Kyle suggested:

> Pod itself is a DSL.

Sure. But to allow arbitrary processing and rendering of Pod, a DSL
isn't enough.

> If we're committed to giving guns to books, can we default to having
> the safety on? Can it be so that 'perl6doc foo.pl' does not execute
> any code without an option to allow it?

There is no perl6doc. There is only: perl6 -doc
That is, running the Perl interpreter in a special mode to get
documentation.


> Perl 5 programmers are sometimes surprised to find that 'perl -c
> strange.pl' can execute code. Imagine their surprise to find that
> 'perl6doc' does too.

But the reason will be exactly the same. Namely, because in Perl you
can't tell what's documentation and what's code until you parse the
mixture. And you can't parse Perl (5 or 6) without executing stuff.

Look, I'm sure we *will* have a safety mode of parsing Pod (maybe:
perl -undoc) But it can't be on by default, otherwise no-one can
write anything but vanilla Pod and expect it to work. It's like
saying that 'use' is potentially dangerous (which it *is*) so can we
have it off by default. In Perl, the answer has to be "no".

Damian

Reply via email to