Re: RFC: println()

2000-08-08 Thread Hildo Biersma
Ed Mills wrote: > > I actually saw this in the newsgroups and thought it was a neat idea. What > about > >println $textvar; > > instead of > >print "$textvar\n"; > > Ever so much easier to read and write, prints the arg and appends \n. This is probably what I disliked most about Pasc

Re: RFC 59 (v1) Proposal to utilize C<*> as the prefix t

2000-08-08 Thread Piers Cawley
Perl6 RFC Librarian <[EMAIL PROTECTED]> writes: > This and other RFCs are available on the web at > http://dev.perl.org/rfc/ > > =head1 TITLE > > Proposal to utilize C<*> as the prefix to magic subroutines I freely accept that this is not anything approaching a reasoned critique but: Yecch!

Re: RFC 59 (v1) Proposal to utilize C<*> as the prefix t

2000-08-08 Thread Piers Cawley
Peter Scott <[EMAIL PROTECTED]> writes: > At 12:07 AM 8/8/00 +0200, Bart Lateur wrote: > >On Mon, 07 Aug 2000 10:56:40 -0700, Peter Scott wrote: > > > > >I meant that BEGIN, END, and INIT aren't declared as subs at present but > > >named blocks. I was surprised to discover that they're put in th

wildcard includes

2000-08-08 Thread Peter Bevan
Just a thought, but I think it woul be a good idea to include the 'java-esqe' practice of including packages via foo.barr.* or in Perl's case Foo::Bar::* (assume that the module include syntax remains the same)... I can see that in the case of some module directories, where the modules are fairly

Re: RFC 50 (v1) BiDirectional Support in PERL

2000-08-08 Thread Roman M . Parparov
On Mon, Aug 07, 2000 at 11:51:06PM +0200, Bart Lateur wrote: > On 07 Aug 2000 17:27:55 -0400, Chaim Frenkel wrote: > > >He mentioned two different encodings. Logical and Visual. I'm not clear > >which is which. One orders the characters so that the first char is > >first. The other reorders the c

Re: wildcard includes

2000-08-08 Thread Piers Cawley
"Peter Bevan" <[EMAIL PROTECTED]> writes: > Just a thought, but I think it woul be a good idea to include the > 'java-esqe' practice of including packages via foo.barr.* > or in Perl's case Foo::Bar::* (assume that the module include syntax remains > the same)... > > I can see that in the case o

Re: RFC 25 (v1) Multiway comparisons

2000-08-08 Thread Martyn J. Pearce
On Fri, Aug 04, 2000 at 04:48:24PM -0400, John Porter wrote: > I think this should mean what it means in Icon, namely, that > $x < $y evaluates to false if $x >= $y, and evaluates to > "$y (but true)" if $x < $y. This allows the operators to be > nested, i.e. $x < $y < $z would be ( $x < $y )

Re: Things to remove

2000-08-08 Thread Martyn J. Pearce
> ?pattern? # one-time match Oi! Scott! No! I use this in one-liners, and it's _dead_ handy. Of course, if it's modularized as Dan suggests, which has no effect at language level, I wouldn't be unhappy. Mx. -- See, the stars are shining bright Everything's all right tonight

Re: Different higher-order func notation? (was Re: RFC 23 (v1) Higher order functions)

2000-08-08 Thread Bart Lateur
On Tue, 8 Aug 2000 13:30:22 +1000 (EST), Damian Conway wrote: > > As for the regexp issue, just to clarify there's only one ambiguous case > > we need to work out that I can see: > > > >/.*^foo/; # ok > >But: /.*^foo/m; #ambiguous Hold it. What does this mean? Is the whole rege

Re: Things to remove

2000-08-08 Thread Leon Brocard
Martyn J. Pearce sent the following bits through the ether: > I use this in one-liners, and it's _dead_ handy May I suggest that Perl6 will be a different language? I've seen the "I use it, don't change it" argument a couple of times now and it's not a strong enough argument. The whole point is

Re: Things to remove

2000-08-08 Thread Piers Cawley
Leon Brocard <[EMAIL PROTECTED]> writes: > Martyn J. Pearce sent the following bits through the ether: > > > I use this in one-liners, and it's _dead_ handy > > May I suggest that Perl6 will be a different language? I've seen the > "I use it, don't change it" argument a couple of times now and

Re: RFC 55 (v1) Compilation: Remove requirement for fina

2000-08-08 Thread Andy Wardley
On Aug 7, 10:12am, Nathan Torkington wrote: > Is there any reason you couldn't use "die" instead? This isn't an objection to the proposal, but one example of where I'm relying on the value returned by require() for a reason other than error reporting. I'm building Perl sub-routines (from templat

Re: Different higher-order func notation? (was Re: RFC 23 (v1) Higher order functions)

2000-08-08 Thread Jeremy Howard
> > > As for the regexp issue, just to clarify there's only one ambiguous case > > > we need to work out that I can see: > > > > > >/.*^foo/; # ok > > > >But: /.*^foo/m; #ambiguous > > Hold it. What does this mean? Is the whole regex gonna be turned into an > anonymous sub, or what?

Re: wildcard includes

2000-08-08 Thread Peter Bevan
- Original Message - From: "Piers Cawley" <[EMAIL PROTECTED]> To: "Peter Bevan" <[EMAIL PROTECTED]> Sent: Tuesday, August 08, 2000 10:32 AM Subject: Re: wildcard includes > "Peter Bevan" <[EMAIL PROTECTED]> writes: > > > "Peter Bevan" <[EMAIL PROTECTED]> writes: > > > However, I do like

Re: AGAINST RFC 48 (v1) Replace localtime() and gmtime() with da

2000-08-08 Thread Matt Sergeant
> On Mon, Aug 07, 2000 at 01:44:28AM -0500, Jonathan Scott Duff wrote: > > On Sun, Aug 06, 2000 at 11:07:02AM -0700, Russ Allbery wrote: > > > Basically, you don't want to go anywhere near this mess; it eats people. > > > > I agree. > > > > > I see two reasona

Re: RFC 55 (v1) Compilation: Remove requirement for fina

2000-08-08 Thread Bart Lateur
On Tue, 8 Aug 2000 07:20:41 +1000, iain truskett wrote: >A call to people: > >Who here has actually used something other than a constant '1' in a >package? > >If so, why? (Possibly cite the code.) I have. Just for fun. 42; # the ultimate answer... # see "Hitchhiker's

Re: RFC 59 (v1) Proposal to utilize C<*> as the prefix t

2000-08-08 Thread Bart Lateur
On Mon, 07 Aug 2000 15:19:00 -0700, Peter Scott wrote: >>Check the docs again. [snip] >> Four special subroutines act as package constructors and >> destructors. These are the `BEGIN', `CHECK', `INIT', and `END' >> routines. The `sub' is optional for these routines. > >Drat. I propos

Re: RFC 59 (v1) Proposal to utilize C<*> as the prefix t

2000-08-08 Thread Bart Lateur
On Tue, 08 Aug 2000 13:03:16 +0200, Bart Lateur wrote: >If you mean that you MUST use "sub", I object. If you mean that the >"sub" may not be used, I agree. Addendum. I would propose that BEGIN { ... } would be what it is now, and that sub BEGIN {

Re: Things to remove

2000-08-08 Thread Bryan C . Warnock
On Tue, 08 Aug 2000, Leon Brocard wrote: > Martyn J. Pearce sent the following bits through the ether: > > > I use this in one-liners, and it's _dead_ handy > > May I suggest that Perl6 will be a different language? I've seen the > "I use it, don't change it" argument a couple of times now and i

Re: RFC 20 (v1) Overloadable && and ||

2000-08-08 Thread Martyn Pearce
On Tue, Aug 08, 2000 at 01:42:40AM +, Nate Mueller wrote: > Along the same line it would be useful to be able to overload the "truth > operator" (bad word, I'm sorry). It's great to be able to do: > > if ($var1 && $var2)... > > But if you also want to do: > > if ($var1)..

Re: wildcard includes

2000-08-08 Thread Graham Barr
On Tue, Aug 08, 2000 at 10:02:35AM +0100, Piers Cawley wrote: > "Peter Bevan" <[EMAIL PROTECTED]> writes: > > > Just a thought, but I think it woul be a good idea to include the > > 'java-esqe' practice of including packages via foo.barr.* Hey, I'm famous :) > However, I do like the idea of syn

Re: RFC 50 (v1) BiDirectional Support in PERL

2000-08-08 Thread Bryan C . Warnock
On Tue, 08 Aug 2000, Roman M . Parparov wrote: > It's not only the browser in the end. > It'd expand the capabilities to any output device presumed LTR. > > > It sounds like a hack. Should Perl support such hacks in the core? > > > > Is this sofisticated enough, or do we need something more low-

Re: RFC 50 (v1) BiDirectional Support in PERL

2000-08-08 Thread Roman M . Parparov
On Tue, Aug 08, 2000 at 07:11:33AM -0400, Bryan C. Warnock wrote: > On Tue, 08 Aug 2000, Roman M . Parparov wrote: > > To explain for those who haven't handled a RTL language, numbers look > the same as in LTR for most RTL languages, and I believe numerical > prefixes also appear the same. > Yes

RFC: Perl Switch for @INC searching

2000-08-08 Thread Ed Mills
Short of writing a perlscript to do it, searching @INC for modules can be a pain. How's about a switch that searches @INC for modules matching a regex instead of executing anything (behaves like perl -v), so for example: perl -M 'spook' might return /usr/local/lib/perl5: -rw-r--r-- 1

Re: Things to remove

2000-08-08 Thread Ted Ashton
Thus it was written in the epistle of Leon Brocard, > Martyn J. Pearce sent the following bits through the ether: > > > I use this in one-liners, and it's _dead_ handy > > May I suggest that Perl6 will be a different language? Actually, I think the point is that Perl6 won't be a different lang

Re: RFC 55 (v1) Compilation: Remove requirement for fina

2000-08-08 Thread John Porter
Damian Conway wrote: > So require and do issue a warning if they require or do an empty file. > Better that than meaningless 1;'s at the end of every module. If we're going to be changing these things, can't we at least ensure that use Foo 'bar'; returns the result of the Foo->im

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Segher Boessenkool
> I guess that's not yet clear to me. After all, as I had pointed out to me, > > while() > > means > > while (defined($_ = )) > > not > > while ($_ = ) > > even if the chomp() is handed an empty line, it will return a defined value. > Only at the point at which returns undef will the whi

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Ted Ashton
Thus it was written in the epistle of Segher Boessenkool, > > The magic defined($_ = ) only happens if is the only thing > inside while(). > > In this case, it's not (there's a chomp() inside as well), so the magic > doesn't apply. Ok. One more time . . . I'm proposing that we change that.

Re: RFC 55 (v1) Compilation: Remove requirement for fina

2000-08-08 Thread William Setzer
iain truskett <[EMAIL PROTECTED]> writes: : : Who here has actually used something other than a constant '1' in a : package? I have. : If so, why? (Possibly cite the code.) Because it's more aesthetic (and useful) for me to see: open '/afs/bp.ncsu.edu/path/to/no_such_file': No such file or

Re: RFC 59 (v1) Proposal to utilize C<*> as the prefix t

2000-08-08 Thread Jonathan Scott Duff
On Tue, Aug 08, 2000 at 09:28:17AM +0100, Piers Cawley wrote: > Peter Scott <[EMAIL PROTECTED]> writes: > > > At 12:07 AM 8/8/00 +0200, Bart Lateur wrote: > > >On Mon, 07 Aug 2000 10:56:40 -0700, Peter Scott wrote: > > > > > > >I meant that BEGIN, END, and INIT aren't declared as subs at present

Re: RFC 59 (v1) Proposal to utilize C<*> as the prefix t

2000-08-08 Thread Jonathan Scott Duff
On Tue, Aug 08, 2000 at 09:27:24AM +0100, Piers Cawley wrote: > > Proposal to utilize C<*> as the prefix to magic subroutines > > I freely accept that this is not anything approaching a reasoned > critique but: > > Yecch! That comment is as good as any :-) -Scott -- Jonathan Scott Duff [EMAI

Re: RFC 59 (v1) Proposal to utilize C<*> as the prefix t

2000-08-08 Thread John Porter
Jonathan Scott Duff wrote: > > But what happens if you want multiple BEGIN blocks? > > The same thing that happens now. As I understand it, perl compiles > and executes the BEGIN block then detroys it so that you may have as > many BEGIN blocks as you want and each time perl thinks it's the firs

Error handling

2000-08-08 Thread Peter Bevan
I started writing this mail by asking: >Does anyone else agree that perl should have support for (but not forcefully) error handling... >maybe a little like Java's?? >I know that sort of thing can be acheived with eval(), but surely Which is as far as I got, because something new has oc

Re: RFC 48 (v2) Objects should have builtin stringifying

2000-08-08 Thread Michael Mathews
> In a scalar context, it could produce a date object always: > >$date = date; > > However, when you went to do anything with it in a string context, it > would call the appropriate method: > >print "$date"; # calls $date->STRING, which in this case would > # prin

RE: Error handling

2000-08-08 Thread Brust, Corwin
From: Peter Bevan [mailto:[EMAIL PROTECTED]] >Error handling should be supported by it's own keyword i.e.: > >trap { > #CODE >} >release (error) { > # ERROR >} I think this is touched on by RFC# 3 wherein I ask for user definable error messages. With those one could presumably set an erro

Re: Things to remove

2000-08-08 Thread Ed Mills
As long as were culling, might want to consider removing chomp() and possibly chop(). The language provides other ways to accomplish those thru a simple regex, and if the "println" suggestion I made was "too specific" then certainly chomp() is as well. Just a thought to chomp on.. E ___

Re: Things to remove

2000-08-08 Thread Simply Hao
> might want to consider removing chomp() and possibly chop(). They're faster than regexes, right? -Hao

Re: Things to remove

2000-08-08 Thread Jonathan Scott Duff
On Tue, Aug 08, 2000 at 03:46:45PM +, Ed Mills wrote: > As long as were culling, might want to consider removing chomp() and > possibly chop(). The language provides other ways to accomplish those thru a > simple regex, and if the "println" suggestion I made was "too specific" then > certa

RE: Things to remove

2000-08-08 Thread Brust, Corwin
From: Simply Hao [mailto:[EMAIL PROTECTED]] >> might want to consider removing chomp() and possibly chop(). > >They're faster than regexes, right? Dunno about faster but so sweet. I like while (<>) { print chomp } better then while (<>{ s/$/$//; p

Re: RFC 59 (v1) Proposal to utilize C<*> as the prefix t

2000-08-08 Thread Peter Scott
At 09:28 AM 8/8/00 +0100, Piers Cawley wrote: >Peter Scott <[EMAIL PROTECTED]> writes: > > > At 12:07 AM 8/8/00 +0200, Bart Lateur wrote: > > >On Mon, 07 Aug 2000 10:56:40 -0700, Peter Scott wrote: > > > > > > >I meant that BEGIN, END, and INIT aren't declared as subs at present but > > > >named b

sub optional for BEGIN: bad idea

2000-08-08 Thread Nathan Torkington
These aren't normal subroutines because of the way they stack. If I had my druthers, I'd make "sub" *forbidden* on such things. If you wanted to make that parsable, pretend that BEGIN and END are the names of functions with prototype (&) which register callbacks. Nat

Re: Things to remove

2000-08-08 Thread Jonathan Scott Duff
On Tue, Aug 08, 2000 at 11:12:40AM -0500, Brust, Corwin wrote: > From: Simply Hao [mailto:[EMAIL PROTECTED]] > > >> might want to consider removing chomp() and possibly chop(). > > > >They're faster than regexes, right? > > > Dunno about faster but so sweet. > > I like > > while (

RE: Error handling

2000-08-08 Thread Peter Scott
At 10:33 AM 8/8/00 -0500, Brust, Corwin wrote: >From: Peter Bevan [mailto:[EMAIL PROTECTED]] > > > >Error handling should be supported by it's own keyword i.e.: > > > >trap { > > #CODE > >} > >release (error) { > > # ERROR > >} > This is being hashed out on per6-language-flow right now... --

Re: RFC 48 (v2) Objects should have builtin stringifying

2000-08-08 Thread Nathan Wiger
> I am intrigued by the idea of a "scalar" context, and > a "string" context though. A string context is a special type of scalar. This distinction already exists in Perl: $one = $two; # scalar (not string) print "$one";# string (and scalar) -Nate

Re: AGAINST RFC 48 (v1) Replace localtime() and gmtime() with da

2000-08-08 Thread Nathan Wiger
> While I think Time::Object is a really great module, and following these > discussions I'm thinking of adding a date() function to it Aaah! Please don't. :-) Name it something else, por favor (or at least wait until this is finalized and make the interface the same). > date arithmetic...not so

Re: RFC: println()

2000-08-08 Thread Bart Lateur
On Tue, 08 Aug 2000 01:29:47 GMT, Ed Mills wrote: >I actually saw this in the newsgroups and thought it was a neat idea. What >about > > println $textvar; > >instead of > > print "$textvar\n"; I can currently do that with $\, and $, for strings between items. For example: ($\, $,)

Re: RFC 34 (v1) Angle brackets should not be used for fi

2000-08-08 Thread Graham Barr
On Sat, Aug 05, 2000 at 12:30:02AM -0600, Nathan Torkington wrote: > Someone wrote: > > > How about "Deprecate use of file globbing with angle brackets. Emit a > > > warning when this behaviour is used." > > I want to RFC this, but I feel like starting a new language with > deprecated behaviours

Re: RFC 64 (v1) New pragma 'scope' to change Perl's defa

2000-08-08 Thread Nathan Wiger
> How usable is this ? > > I may be missing something, but if every variable mentioned in an anonymous > block is assumed to be declared with my, then how do you access or modify > the value of any variable outside the block ? > > Graham. I knew someone was going to ask this; after I sent it I r

Re: Things to remove

2000-08-08 Thread Riad Wahby
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 [EMAIL PROTECTED] wrote: >As long as were culling, might want to consider removing chomp() and >possibly chop(). The language provides other ways to accomplish those thru a >simple regex, and if the "println" suggestion I made was "too specific" the

Re: RFC 64 (v1) New pragma 'scope' to change Perl's defa

2000-08-08 Thread Michael Mathews
Graham Barr said: > > Would result in "25" being printed out. Here's why: > > > >1. The C<$x = 10> is automatically scoped with its own C. > > > >2. The C<$x = 5> inside the B block is automatically > > scoped with its own C. > > > >3. The C<$x = 25> code, however, inside the C s

Re: RFC: println()

2000-08-08 Thread Riad Wahby
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 [EMAIL PROTECTED] wrote: >This is probably what I disliked most about Pascal - it presumes it >knows best what units of output you want to write at any one time - a >piece of a line or an entire line. I feel this dates back to the >mainframe world (a

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Larry Wall
Ted Ashton writes: : Thus it was written in the epistle of Segher Boessenkool, : > : > The magic defined($_ = ) only happens if is the only thing : > inside while(). : > : > In this case, it's not (there's a chomp() inside as well), so the magic : > doesn't apply. : : Ok. One more time . . .

Re: sub optional for BEGIN: bad idea

2000-08-08 Thread Peter Scott
At 10:17 AM 8/8/00 -0600, Nathan Torkington wrote: >These aren't normal subroutines because of the way they stack. If I >had my druthers, I'd make "sub" *forbidden* on such things. > >If you wanted to make that parsable, pretend that BEGIN and END are >the names of functions with prototype (&) wh

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Larry Wall
Larry Wall writes: : (Note that under Unicode, we might well have one line terminated with a : line separator, and the next line terminated with a page separator, and Make that paragraph separator. Larry

Re: RFC 48 (v1) Replace localtime() and gmtime() with da

2000-08-08 Thread Dan Sugalski
At 03:52 PM 8/7/00 -0400, Andy Dougherty wrote: >Yes, obviously it has been used by many. That means that the equivalent >functionality needs to be provided somehow in the complete standard perl6 >distribution. It doesn't mean localtime() has to be a keyword with its >very own opcode that is par

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Nathan Wiger
> Second, as it seems common for someone learning perl to expect > > $without_newline = chomp($previous_form); This proposal seeks to make things more consistent, which is good, but at the expense of being less usable, which is bad. For example, these: chomp; chomp(@file); chomp($val

Re: RFC 23 Higher order functions

2000-08-08 Thread Andy Dougherty
Quoting RFC 23: > That is, the expression: > > $check = __ < 2 + __ * atan($pi/__) or die __; > > is equivalent to: > > $check = sub (;) { > $_[0] < 2 + $_[1] * atan($pi/$_[3]) or die $_[4] > }; It strikes me that this is very fragile and limited (unless

Proto-RFC: isa() function

2000-08-08 Thread jmastros
Hello all. I'm not certian if there's a sublist that this is more approprate for, if so, could someone tell me what it is? I can't see that this clearly applies to any of them. Please cc me; I'm not yet subscribed to these lists (just tried again; if this doesn't work, the listmasters will b

Re: RFC 23 Higher order functions -- macros instead?

2000-08-08 Thread Andy Dougherty
In RFC 23, Damian Conway <[EMAIL PROTECTED]> proposes a syntax for "higher-order functions". One example given is related to a proposed switch statement (RFC 22). A trimmed version is: > sub beverage { > switch (shift) { > case sub{ $_[0] < 10 } { retu

Re: Error handling

2000-08-08 Thread Uri Guttman
please move this thread to flow as we have the error RFC posted there. thanx, uri -- Uri Guttman - [EMAIL PROTECTED] -- http://www.sysarch.com SYStems ARCHitecture, Software Engineering, Perl, Internet, UNIX Consulting The Perl Books Page --- http://www.sysarch.c

Re: RFC 23 Higher order functions

2000-08-08 Thread Jonathan Scott Duff
On Tue, Aug 08, 2000 at 01:27:48PM -0400, Andy Dougherty wrote: > It strikes me that this is very fragile and limited (unless I > misunderstand, which is quite possible). For one thing, it appears to > only be useful if your subroutine uses each argument exactly once. If > you need to use any of

default $/ (was Re: RFC: println())

2000-08-08 Thread Uri Guttman
> "BL" == Bart Lateur <[EMAIL PROTECTED]> writes: BL> On Tue, 08 Aug 2000 01:29:47 GMT, Ed Mills wrote: >> I actually saw this in the newsgroups and thought it was a neat idea. What >> about >> >> println $textvar; i am against println. it is not so useful that i would be using i

Re: default $/ (was Re: RFC: println())

2000-08-08 Thread Peter Scott
At 01:46 PM 8/8/00 -0400, Uri Guttman wrote: >interesting point: we are all in agreement for filehandle specific $/ >and $\. but what about global default values for those handles which hve >not had theirs set? you can still set the global $/ and affect all >handles which don't have private $/. >

Re: default $/ (was Re: RFC: println())

2000-08-08 Thread Ted Ashton
Thus it was written in the epistle of Uri Guttman, > > interesting point: we are all in agreement for filehandle specific $/ > and $\. but what about global default values for those handles which hve > not had theirs set? you can still set the global $/ and affect all > handles which don't have p

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Dan Sugalski
At 10:12 AM 8/8/00 -0700, Larry Wall wrote: >Ted Ashton writes: >: Thus it was written in the epistle of Segher Boessenkool, >: > >: > The magic defined($_ = ) only happens if is the only thing >: > inside while(). >: > >: > In this case, it's not (there's a chomp() inside as well), so the magic

Re: Things to remove

2000-08-08 Thread Ted Ashton
Thus it was written in the epistle of Jonathan Scott Duff, > > Someone proposed (I think I deleted that email) to make > > while () { ... } > > work like > > while () { chomp; ... } I'm not sure if I'm the someone you meant, but if so, the proposal was to make while (c

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Uri Guttman
> "LW" == Larry Wall <[EMAIL PROTECTED]> writes: LW> Before we get too carried away discussing the syntax of chomp, LW> let's look a bit at the semantics. What's chomp supposed to work LW> on if we make $/ go away? I think any discussion of chomp without LW> considering how the inpu

Re: Things to remove

2000-08-08 Thread Bennett Todd
2000-08-08-04:42:00 Leon Brocard: > Martyn J. Pearce sent the following bits through the ether: > > I use this in one-liners, and it's _dead_ handy > > May I suggest that Perl6 will be a different language? If perl6 substantially fails to fill the important roles that perl5 fills, we should stop

Re: RFC 48 (v2) Objects should have builtin stringifying

2000-08-08 Thread Dan Sugalski
At 02:18 PM 8/8/00 +, Perl6 RFC Librarian wrote: >This and other RFCs are available on the web at > http://dev.perl.org/rfc/ > >=head1 TITLE > >Objects should have builtin stringifying STRING method > >=head1 VERSION > >Maintainer: Nathan Wiger <[EMAIL PROTECTED]> >Date: 06 Aug 2000

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Ted Ashton
Thus it was written in the epistle of Nathan Wiger, > > Second, as it seems common for someone learning perl to expect > > > > $without_newline = chomp($previous_form); > > This proposal seeks to make things more consistent, which is good, but > at the expense of being less usable, which is ba

Re: RFC 48 (v2) Objects should have builtin stringifying

2000-08-08 Thread Nathan Torkington
Dan Sugalski writes: > Is this an update to the original RFC 48 with a new title? Or is it a new > RFC mis-numbered? Actually, it's an update to 49 with a slightly different title, so the answer to both of your questions is "yes". The 48/49 confusion has been cleared up in the archive. Nat

Re: Things to remove

2000-08-08 Thread Hildo Biersma
Bennett Todd wrote: > > There are many intents and points to this project. As _I_ see them, > they include, in no particular order: > > - cleaning up the language definition, where practical without > losing the distinctive appeal of perl to happy perl programmers; > > - cleaning up the imple

Re: Things to remove

2000-08-08 Thread Jonathan Scott Duff
On Tue, Aug 08, 2000 at 01:53:21PM -0400, Ted Ashton wrote: > I'm not sure if I'm the someone you meant, but if so, the proposal was to make > > while (chomp()) { ... } > > work like > > while () { chomp; ... } Oh. I think I'd prefer to see chomp() go away and be replaced by s

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Ted Ashton
Thus it was written in the epistle of Larry Wall, > Before we get too carried away discussing the syntax of chomp, let's > look a bit at the semantics. What's chomp supposed to work on if we > make $/ go away? Right. But that's not yet decided :-). > I think any discussion of

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Jonathan Scott Duff
On Tue, Aug 08, 2000 at 01:56:12PM -0400, Uri Guttman wrote: > a couple of ideas. one, i proposed we keep a global $/ and $\ for > default use by handles which haven't set their own. Rather than having global $/ and $\, each filehandle has their's defaulted to something reasonable. > two, instea

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Ted Ashton
Thus it was written in the epistle of Jonathan Scott Duff, > On Tue, Aug 08, 2000 at 01:56:12PM -0400, Uri Guttman wrote: > > a couple of ideas. one, i proposed we keep a global $/ and $\ for > > default use by handles which haven't set their own. > > Rather than having global $/ and $\, each fil

Re: RFC 62 (v1) Wildcards for multiple module imports

2000-08-08 Thread Chaim Frenkel
I don't like it. There is currently nothing preventing author B from adding something to the Foo::Bar hierarchy and infecting the other modules. This would require two authors that currently do not have to coordinate with each other to be careful. Another problem is that an external change woul

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Michael Mathews
Dan Sugalski said: > Which brings up the questions: > > * What about scalars that didn't come from filehandles? > * Should the chomp function use the filehandle's current separator, or the > one in effect when it was read? > * Do we even want to allow after-the-fact chomps, or do it automagically

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Jonathan Scott Duff
On Tue, Aug 08, 2000 at 02:16:57PM -0400, Ted Ashton wrote: > I, for one, would like to know where the assumption came from that there would > be no default filehandle. I believe Larry said he was probably going to axe it. > Is it necessary that instead of typing > > print 'Hello World.';

Re: Things to remove

2000-08-08 Thread Russ Allbery
Bennett Todd <[EMAIL PROTECTED]> writes: > The poster you are replying to said "I use this in one-liners, and it's > _dead_ handy."; that conjures up the idioms like > perl -nle 'print if 1.. ?^$?' [filename] > which barfs out only the header; replace "if" with "unless" and it > chops the

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Uri Guttman
> "TA" == Ted Ashton <[EMAIL PROTECTED]> writes: TA> Thus it was written in the epistle of Jonathan Scott Duff, >> On Tue, Aug 08, 2000 at 01:56:12PM -0400, Uri Guttman wrote: > a >> couple of ideas. one, i proposed we keep a global $/ and $\ for > >> default use by handles which have

RE: RFC 58 (v1) C changes.

2000-08-08 Thread Brust, Corwin
From: Ted Ashton [mailto:[EMAIL PROTECTED]] >> I don't particularly mind the last two - in fact they add some benefits >> (like not modifying the original), which are nice to have. However, that >> first one, frankly, drives me nuts. > >Please reread the proposal. chomp() called in void context

Re: default $/ (was Re: RFC: println())

2000-08-08 Thread Jonathan Scott Duff
On Tue, Aug 08, 2000 at 01:46:41PM -0400, Uri Guttman wrote: > interesting point: we are all in agreement for filehandle specific $/ > and $\. but what about global default values for those handles which hve > not had theirs set? you can still set the global $/ and affect all > handles which don't

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Dan Sugalski
At 02:29 PM 8/8/00 -0400, Michael Mathews wrote: >Dan Sugalski said: > > Which brings up the questions: > > > > * What about scalars that didn't come from filehandles? > > * Should the chomp function use the filehandle's current separator, or the > > one in effect when it was read? > > * Do we eve

Re: default $/ (was Re: RFC: println())

2000-08-08 Thread Jonathan Scott Duff
On Tue, Aug 08, 2000 at 01:50:35PM -0400, Ted Ashton wrote: > Hear, hear! Chomp (which I still consider a useful critter :-), needs a > $/ sort of thing to know what to chomp and the lines it chomps may or may > not have come from a given file. Chomping *is* useful, but it's a per-filehandle t

Re: default $/ (was Re: RFC: println())

2000-08-08 Thread Uri Guttman
> "JSD" == Jonathan Scott Duff <[EMAIL PROTECTED]> writes: JSD> On Tue, Aug 08, 2000 at 01:46:41PM -0400, Uri Guttman wrote: >> interesting point: we are all in agreement for filehandle specific >> $/ and $\. but what about global default values for those handles >> which hve not had

Re: default $/ (was Re: RFC: println())

2000-08-08 Thread Jonathan Scott Duff
On Tue, Aug 08, 2000 at 02:44:59PM -0400, Uri Guttman wrote: > the key word besides global is default. this would be the value used by > any new filehandle created. you can override that at anytime in that > filehandle. otherwise the default value for $/ for new handles will be > hardcoded in %CON

Re: AGAINST RFC 48 (v1) Replace localtime() and gmtime() with da

2000-08-08 Thread Damien Neil
On Tue, Aug 08, 2000 at 09:46:04AM -0700, Nathan Wiger wrote: > The RFC doesn't mention localtime() for just this reason. The idea would > be localtime would be GONE in Perl 6, instead moved to Time::Local. > date() would replace it. Why is this a good idea? Perl programs have been using localti

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Ted Ashton
Thus it was written in the epistle of Brust, Corwin, > > From: Ted Ashton [mailto:[EMAIL PROTECTED]] > >> I don't particularly mind the last two - in fact they add some benefits > >> (like not modifying the original), which are nice to have. However, that > >> first one, frankly, drives me nuts.

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Michael Mathews
Dan Sugalski said: > > > * Do we even want to allow after-the-fact chomps, or do it automagically > >at read time? > "Yes" is rather ambiguous. To clarify: "Yes", we (I) want to allow after-the-fact chomps. As you alluded to yourself there are times when you may want to chomp strings that were no

Re: wildcard includes

2000-08-08 Thread Steve Simmons
I'm working on an RFC on module versioning. It'd be done by now, except my boss and family keep expecting me to work and be fatherly. :-) Let me get that banged out, and then lets look at adding wildcards to it.

Re: sub optional for BEGIN: bad idea

2000-08-08 Thread John Porter
Nathan Torkington wrote: > These aren't normal subroutines because of the way they stack. If I > had my druthers, I'd make "sub" *forbidden* on such things. I like that idea. But then, they also shouldn't go into the symbol table. At least, not as CODE. > If you wanted to make that parsable,

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Uri Guttman
> "MM" == Michael Mathews <[EMAIL PROTECTED]> writes: >> >What about a > chomp($foo, '\r\n'); > # or > chomp(, '\r\n'); >> >syntax. >> >> Looks an awful lot like: s/\r\n//; to me... MM> Yep. It should-- that's all chomp does afterall. The difference is MM> that the proposed chom

Re: sub optional for BEGIN: bad idea

2000-08-08 Thread Nathan Torkington
John Porter writes: > > If you wanted to make that parsable, pretend that BEGIN and END are > > the names of functions with prototype (&) which register callbacks. > > I agree ... except that, in perl5 at least, you'd need a terminating > semicolon if that analogy were 100% accurate. I realized

Re: RFC 64 (v1) New pragma 'scope' to change Perl's defa

2000-08-08 Thread Ariel Scolnicov
Nathan Wiger <[EMAIL PROTECTED]> writes: > > How usable is this ? > > > > I may be missing something, but if every variable mentioned in an anonymous > > block is assumed to be declared with my, then how do you access or modify > > the value of any variable outside the block ? > > > > Graham. >

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Ted Ashton
Thus it was written in the epistle of Uri Guttman, > > if a ref to a scalar, it chomps in place. return the ref? the chomped > char count? . . . the point of the RFC was to propose making chomp()'s behaviour change depending on context. Here's the summary so far as I can tell: One-argument cho

Re: RFC 55 (v1) Compilation: Remove requirement for fina

2000-08-08 Thread Damian Conway
> If there's a warning if a require'd or use'd file is empty, that's more > than good enough for me. Already added to V2 of the RFC. Damian

Re: Things to remove

2000-08-08 Thread Damian Conway
> Most of the requests for deletion seem to begin with, "This isn't > used..." > > To which, "*I* use it." is a very valid argument. Agreed. The real problem with ?...? is that it complicates the hell out of the parser. So long as the special magic is retained for m?...?, I would su

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Uri Guttman
> "TA" == Ted Ashton <[EMAIL PROTECTED]> writes: TA> One-argument chomp(): TA> array: TA> chomp()s each element of array using $/? TA> two-argument chomp(): TA> does as above, but using the second argument (which is a scalar, not a TA>regex) how do you te

Re: RFC 58 (v1) C changes.

2000-08-08 Thread Ted Ashton
Thus it was written in the epistle of Uri Guttman, > > how do you tell the above two apart? by array do you mean only an array > variable? then you can't chomp a list of scalar values or multiple > arrays, etc. > > this needs to be clarified. Quite true. The two-argument one is new to me and I

  1   2   >