[% setvar title Eliminate dump() function %]
Note: these documents may be out of date. Do not use as reference! |
To see what is currently happening visit http://www.perl6.org/
Eliminate dump() function
Maintainer: Dominus <mjd@plover.com> Date: 20 Sep 2000 Mailing List: perl6-language@perl.org Number: 267 Version: 1 Status: Developing
Get rid of it completely.
dump is a common subroutine name. People often try to define a dump subroutine and then get puzzled by the dump. They have to name their dump functions 'Dump' or 'dumper' and then they get annoying errors when they call dump instead by mistake.
dump is not very useful anyway; see MIGRATION below.
None needed.
The translator should translate calls to dump() to
kill 6 => $$;
instead.
If the translator fails on dump LABEL, that is probably all right. But if not, then it can translate
... dump LABEL; ... LABEL: ...
to
... ${^Please_Dump} = 1; goto LABEL; ... LABEL: kill 6 => $$ if ${^Please_Dump}; undef ${^Please_Dump}; ...
perlfunc manpage for discussion of dump()