Re: RFC 267 (v1) Eliminate dump() function

2000-09-21 Thread Michael G Schwern

On Thu, Sep 21, 2000 at 03:55:21AM -, Perl6 RFC Librarian wrote:
 Eliminate dump() function

I didn't even know it existed.

-- 

Michael G Schwern  http://www.pobox.com/~schwern/  [EMAIL PROTECTED]
Just Another Stupid Consultant  Perl6 Kwalitee Ashuranse
Any failure I encounter in life is the fault of android weasels.
-- everything i ever needed to know i learned from goats



Re: RFC 267 (v1) Eliminate dump() function

2000-09-21 Thread Randal L. Schwartz

 "Michael" == Michael G Schwern [EMAIL PROTECTED] writes:

Michael On Thu, Sep 21, 2000 at 03:55:21AM -, Perl6 RFC Librarian wrote:
 Eliminate dump() function

Michael I didn't even know it existed.

I do, every time I forget to hit the shift key around certain invocations
of Data::Dumper and then wonder why my program is core dumping.

Doh!

-- 
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
[EMAIL PROTECTED] URL:http://www.stonehenge.com/merlyn/
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!



Re: RFC 267 (v1) Eliminate dump() function

2000-09-21 Thread Bart Lateur

On 21 Sep 2000 03:55:21 -, Perl6 RFC Librarian wrote:

Eliminate dump() function
Get rid of it completely.

I think that, for the rare occasions people want this functionality, one
of the many O (B) modules should offer it, at least in spirit.

-- 
Bart.



Re: RFC 267 (v1) Eliminate dump() function

2000-09-21 Thread Uri Guttman

 "BL" == Bart Lateur [EMAIL PROTECTED] writes:

  BL On 21 Sep 2000 03:55:21 -, Perl6 RFC Librarian wrote:
   Eliminate dump() function
   Get rid of it completely.

  BL I think that, for the rare occasions people want this functionality, one
  BL of the many O (B) modules should offer it, at least in spirit.

one use of a dump type of thing (if it could be made to work) is for the
Perl without perl idea that schwern asked about. this would then be a
form of perlcc without paying for it. i agree that it should be a module
that can be loaded to create a preloaded binary image which can be run
directly.

but dump isn't the way to go as it is broken, you need a flaky undump
program (from emacs), it is not portable, etc.

uri

-- 
Uri Guttman  -  [EMAIL PROTECTED]  --  http://www.sysarch.com
SYStems ARCHitecture, Software Engineering, Perl, Internet, UNIX Consulting
The Perl Books Page  ---  http://www.sysarch.com/cgi-bin/perl_books
The Best Search Engine on the Net  --  http://www.northernlight.com



RFC 267 (v1) Eliminate dump() function

2000-09-20 Thread Perl6 RFC Librarian

This and other RFCs are available on the web at
  http://dev.perl.org/rfc/

=head1 TITLE

Eliminate dump() function

=head1 VERSION

  Maintainer: Dominus [EMAIL PROTECTED]
  Date: 20 Sep 2000
  Mailing List: [EMAIL PROTECTED]
  Number: 267
  Version: 1
  Status: Developing

=head1 ABSTRACT

Get rid of it completely.

=head1 DESCRIPTION

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.

=head1 IMPLEMENTATION

None needed.

=head1 MIGRATION

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};
...


=head1 REFERENCES

perlfunc manpage for discussion of dump()