Re: rethinking printf

2002-03-06 Thread Bart Lateur
On Wed, 6 Mar 2002 17:57:07 -0500, Uri Guttman wrote: how often will you need to interpolate a hash? A whole hash: quite rarely. A hash item: a LOT. Don't forget that $foo{BAR} will now become %foo{BAR} -- Bart.

Re: 123_456

2002-01-26 Thread Bart Lateur
On Fri, 25 Jan 2002 17:34:12 +, Simon Cozens wrote: Should we be allowed to use _ to group numbers, now that _ is concat? If not _, then what? (if anything?) I don't really understand your question. Currently, . is used for concat and that doesn't inhibit using it in a number, does it? Or

Re: Apoc4: The loop keyword

2002-01-25 Thread Bart Lateur
On Mon, 21 Jan 2002 15:43:07 -0500, Damian Conway wrote: What we're cleaning up is the ickiness of having things declared outside the braces be lexical to the braces. *That's* hard to explain to beginners. But it's handy. And that was, until now, what mattered with Perl. -- Bart.

Re: Apoc 4?

2002-01-19 Thread Bart Lateur
On Fri, 18 Jan 2002 12:33:48 -0500, Will Coleda wrote: http://www.perl.com/pub/a/2002/01/15/apo4.html David Whipp wrote: Michael G Schwern wrote: Reading this in Apoc 4 ... I looked on http://dev.perl.org/perl6/apocalypse/: no sign of Apoc4. Where do I find this latest installment?

Re: [PATCH] The Code Police [1/

2001-12-30 Thread Bart Lateur
On Sun, 30 Dec 2001 16:11:35 -0800 (PST), Boris Tschirschwitz wrote: Yeah, int *num; is customary in C, but for some reason C++ people like to write int* num; I am sure I saw some rationale for that in gcc's C++ part, but I can't find it anymore. Apparently C programmers do not fall for

Re: Apropos of nothing...

2001-12-13 Thread Bart Lateur
On Thu, 13 Dec 2001 12:17:44 -0500, Mark J. Reed wrote: @i = (0); @ary[@i] = foo(); How could one get that behavior without the intermediate array? Parens, likely. (@ary[0]) = foo(); -- Bart.

Re: Moving string - number conversions to string libs

2001-12-06 Thread Bart Lateur
On Thu, 06 Dec 2001 00:16:34 GMT, Tom Hughes wrote: So far I have added as is_digit() call to the character type layer to replace the existing isdigit() calls. There seems to be an overlap with the /\d/ character class in regexes. Can't you use the same test? Can't you use the definition of

Re: Parrot FAQ

2001-12-05 Thread Bart Lateur
On Wed, 05 Dec 2001 13:32:32 -0500, Dan Sugalski wrote: Right, but FORTH's not an interpreted language, generally speaking. The old FORTH's in the 80's worked pretty much like the p-copde interpreter. Nowadays, FORTH compilers are really optimizing compilers. There are excellent commercial

Re: Parrot FAQ

2001-12-05 Thread Bart Lateur
On Tue, 04 Dec 2001 15:57:56 -0500, Dan Sugalski wrote: Q: Don't you know that stack machines are the way to go in software? A: No, in fact, I don't. Q: But look at all the successful stack-based VMs! A: Like what? There's just the JVM. Q: What about all the others? A: *What* others? That's

Re: Benchmarking the proposed RE engine

2001-11-26 Thread Bart Lateur
On Sun, 25 Nov 2001 19:34:15 -0800, Brent Dax wrote: Perl 5's REs will always appear faster because Perl 5 has an intelligent, optimizing regex compiler. For example, take the following simple regex: /a+bc+/ pregcomp will optimize that by searching for a 'b' and working outwards both

Re: PMC Classes Preprocessor

2001-11-25 Thread Bart Lateur
On Sun, 25 Nov 2001 13:14:22 +, Simon Cozens wrote: On Sun, Nov 25, 2001 at 02:32:34AM -0500, Angel Faus wrote: use Text::Balanced 'extract_bracketed'; Urgh. We need to work around this. Can somebody fill me in exactly how this is supposed to behave? I think that this may come close:

Re: sizeof(INTVAL), sizeof(void*), sizeof(opcode_t)

2001-11-23 Thread Bart Lateur
On Wed, 21 Nov 2001 13:46:09 -0500, Dan Sugalski wrote: Nah, using an I register as a host-machine-address for jumps doesn't argue for sizeof(INTVAL) = sizeof(void *). Instead, it argues that the design that uses an int as an absolute address is wrong. I'm going to rewrite the docs and ops to

Re: Perl 6 - Cheerleaders?

2001-10-26 Thread Bart Lateur
On Thu, 25 Oct 2001 16:53:46 -0500, Garrett Goebel wrote: Piers Cawley has written a nice article entitled: Perl 6 : Not Just For Damians. http://www.perl.com/pub/a/2001/10/23/damians.html I just hope that you don't really have to insert that many blank lines in your code just to make it

Re: Revamping the build system

2001-10-23 Thread Bart Lateur
On Tue, 23 Oct 2001 08:39:29 -0400, John Siracusa wrote: As one of the few rabid Mac users on this list, let me just say that I personally have no problem with classic Mac OS support being totally dropped from Parrot if it'll get stuff out the door sooner :) Classic Mac OS is (somewhat sadly) a

Re: Math functions? (Particularly transcendental ones)

2001-09-11 Thread Bart Lateur
On Mon, 10 Sep 2001 18:48:01 -0400, Dan Sugalski wrote: At 12:35 AM 9/11/2001 +0200, Bart Lateur wrote: On Mon, 10 Sep 2001 17:13:44 -0400, Dan Sugalski wrote: Who the heck is going to override arctangent? (No, don't tell me, I don't want to know) Perhaps you do. Think BigFloat. Or Complex

Re: Math functions? (Particularly transcendental ones)

2001-09-09 Thread Bart Lateur
On Sat, 08 Sep 2001 13:02:04 -0400, Dan Sugalski wrote: Uri mentioned exp(x) = e^x, but I think if you are going to include log2, log10, log, etc, you should also include ln. Added. Er... aren't ln and log synonyms? -- Bart.

Re: Should MY:: be a real symbol table?

2001-09-06 Thread Bart Lateur
On Mon, 03 Sep 2001 19:29:09 -0400, Ken Fox wrote: *How* are they fundamentally different? Perl's local variables are dynamically scoped. This means that they are *globally visible* -- you never know where the actual variable you're using came from. If you set a local variable, all the

Re: Should MY:: be a real symbol table?

2001-09-06 Thread Bart Lateur
On Mon, 03 Sep 2001 19:30:33 -0400, Dan Sugalski wrote: The less real question, Should pads be hashes or arrays, can be answered by whichever is ultimately cheaper. My bet is we'll probably keep the array structure with embedded names, and do a linear search for those rare times you're

Re: ! and !

2001-09-02 Thread Bart Lateur
On 01 Sep 2001 14:40:40 -0700, Russ Allbery wrote: Sterin, Ilya [EMAIL PROTECTED] writes: From: Russ Allbery [mailto:[EMAIL PROTECTED]] How is ! different from =? ... It's the same number of characters. How can it be more convenient? Why is it = and not =? Why = and not =? Simply trying to

Re: Come and get me, Schwern

2001-08-30 Thread Bart Lateur
On Wed, 29 Aug 2001 16:26:59 -0500, David L. Nicol wrote: Bill J. Programmer publishes a class foo that is guaranteed to correctly blarg the frobniz, someone subclasses it and breaks the blarg function, that simply will not do! With a final it is no longer possible for the new class to identify

Re: Something to hash out

2001-08-27 Thread Bart Lateur
On Sat, 25 Aug 2001 18:58:50 +0100, Simon Cozens wrote: I was using .pas and .pac. Gotta think about 8.3ness, unfortunately. The 8 might not be that relevant nowadays, but the 3 still matters. On Win32, file extensions get cut off after 3 characters. So a .html file is actually the same as a

Re: Draft assembly PDD

2001-08-07 Thread Bart Lateur
On Mon, 06 Aug 2001 21:55:07 -0400, Dan Sugalski wrote: But I do not agree that calculated jumps should be done in such a hard way. Nothing hard about it, really. I was referring to Hong Zhang's proposal, not yours. -- Bart.

Re: new syntax idea: eval ...o;

2001-08-07 Thread Bart Lateur
On Tue, 7 Aug 2001 09:27:43 -0400, John Porter wrote: David L. Nicol wrote: eval ${code}o; Another brilliant idea from David Nicol! Not really. What I would like is an option to just *compile* a piece of perl code, without executing it. This kinda works: $coderef = eval sub {

Re: Draft assembly PDD

2001-08-06 Thread Bart Lateur
On Mon, 6 Aug 2001 15:41:59 -0700 , Hong Zhang wrote: Branches should work from both constants and registers. Even so, the branch #num should have better performance, and it is part of any machine language. Since we already have jump instruction, do we really need the branch %r, which can be

Re: if then else otherwise ...

2001-07-30 Thread Bart Lateur
On Sun, 29 Jul 2001 19:36:43 -0400, Bryan C. Warnock wrote: $x = ($default,$a,$b)[$b=$a]; # Much like I did before Note that $x = cond? a : b does lazy evaluation, i.e. the value for a or for b is only fetched when it's actually needed. In your construct, they're all fetched anyway,

Re: if then else otherwise ...

2001-07-29 Thread Bart Lateur
On Sun, 29 Jul 2001 14:22:23 +0300, raptor wrote: But at least the second shortcut is worth it, i think : cond ? then : else : otherwise This has a vague smell of Fortran. -- Bart.

Re: as long as we are discussing 'nice to have's...

2001-07-24 Thread Bart Lateur
On Sat, 21 Jul 2001 14:47:43 -0700 (PDT), Dave Storrs wrote: I discovered today that I had forgotten to put 'use strict' at the top of one of my modules...it was in the script that _used_ the module, but not in the module itself. Putting it in instantly caught several annoying bugs that I'd

Re: The internal string API

2001-06-28 Thread Bart Lateur
On Tue, 19 Jun 2001 14:51:43 -0500, Jarkko Hietaniemi wrote: But a locale is a collection of user preferences. How I want my dates to be formatted, how I want my strings to be sorted. That's not right. If I do a text conversion from Windows to Mac, I would want to source to use the CP-1522

Re: Multiple classifications of an object

2001-06-28 Thread Bart Lateur
On Wed, 27 Jun 2001 13:48:38 -0400, Dan Sugalski wrote: And the current @ISA stuff is MI, albeit on a per-class basis rather than on a per-object one. Anyway, as Damian mentioned, setting the .ISA property is a perfectly reasonable sort of thing to do if the language supports this. Just one

Re: The internal string API

2001-06-20 Thread Bart Lateur
On Tue, 19 Jun 2001 11:53:28 -0700, Hong Zhang wrote: * Do a substr operation by character and glyph The byte based is more useful. I have utf-8, and I want to substr it to another utf-8. It is painful to convert it or linear search for charaacter position. I tend to agree. I currently use

Re: More character matching bits

2001-06-15 Thread Bart Lateur
On Fri, 15 Jun 2001 06:52:32 -0400, Bryan C. Warnock wrote: On a side note (and this *will* sound stupid, but there is a reason I'm asking). Why is there no logical opposite to '.'; that is, a character which never matches another character? (Besides, of course, that it's utterly useless

Re: More character matching bits

2001-06-14 Thread Bart Lateur
On Wed, 13 Jun 2001 13:39:16 -0400, Dan Sugalski wrote: Something that should be part of the core? I'll leave that for you to decide. Most definitely NOT. Most definitely sort of. There is no reason to put fucntionality for free matching of Japanese characters into the basic perl

Re: should vtables be vtables?

2001-06-13 Thread Bart Lateur
On Wed, 13 Jun 2001 12:00:21 +0100 (BST), Dave Mitchell wrote: I was thinking back to the earlier discusions on opcode dispatch, and the fact that some people thought that a big switch was as good as, or possibly faster than a dispatch table. Which led me to think... I would think that a switch

Re: More character matching bits

2001-06-13 Thread Bart Lateur
On Wed, 13 Jun 2001 01:22:32 +0100, Simon Cozens wrote: Something that should be part of the core? I'll leave that for you to decide. Most definitely NOT. There is no reason to put fucntionality for free matching of Japanese characters into the basic perl executable. There were already voices

Re: Should the op dispatch loop decode?

2001-06-13 Thread Bart Lateur
On Tue, 12 Jun 2001 18:12:35 -0400, Dan Sugalski wrote: 'Kay, here's a question to ponder. Should the op dispatch loop handle argument decoding, or should that be left to the opcode functions? Are you talking about lazy vs. normal evaluation? Lisp knows basically two modes, normal evaluation,

Re: Social Reform

2001-06-12 Thread Bart Lateur
On Tue, 12 Jun 2001 08:54:13 +0100, Simon Cozens wrote: On Mon, Jun 11, 2001 at 05:19:26PM -0700, Daniel S. Wilkerson wrote: I would say Simon was the one ignoring an issue and attacking a person, not Vijay. You are wrong. Go back through the archives. Vijay has posted four messages: two of

Re: hash and array variables vs. references

2001-06-08 Thread Bart Lateur
On Fri, 8 Jun 2001 14:05:44 -0400, Mark J. Reed wrote: My question/suggestion: why not get rid of @arrays and %hashes as separate variable types? Have all variables be scalar - with, of course, the ability to hold a reference to an anonymous array or hash. Keep the funny characters around,

Re: PDD 2nd go: Conventions and Guidelines for Perl Source Code

2001-06-05 Thread Bart Lateur
On Tue, 29 May 2001 18:25:45 +0100 (BST), Dave Mitchell wrote: diffs: -KR style for indenting control constructs +KR style for indenting control constructs: ie the closing C} should +line up with the opening Cif etc. On Wed, 30 May 2001 10:37:06 -0400, Dan Sugalski wrote: I realize that no

Re: Should we care much about this Unicode-ish criticism?

2001-06-05 Thread Bart Lateur
On 05 Jun 2001 11:07:11 -0700, Russ Allbery wrote: Particularly since part of his contention is that 16 bits isn't enough, and I think all the widely used national character sets are no more than 16 bits, aren't they? It's not really important. UTF-8 is NOT limited to 16 bits (3 bytes). With 4

Re: slices

2001-05-25 Thread Bart Lateur
On Thu, 24 May 2001 22:19:12 -0400, James Mastros wrote: But what about: @foo[(1,2,3)]? Are those parens a list-maker, or are they a scalar expression using the comma operator. Both. But in this case, I'd say: it depends on the context the slice is called in. @bar = @foo[(1,2,3)];

Re: Separate as keyword? (Re: 'is' and action at a distance)

2001-05-18 Thread Bart Lateur
On Fri, 18 May 2001 23:26:53 +0200, Trond Michelsen wrote: While I understand how 0 but true is a cute hack that is destined to be replaced by a truth property, I fail to realize how it's useful to have a value that's true no matter what value you assign to it later. I thought the truth

Re: Damian Conway's Exegesis 2

2001-05-16 Thread Bart Lateur
On Wed, 16 May 2001 13:49:42 +0200, Carl Johan Berglund wrote: sub show {print 6} print Perl ${show()}\n; (That prints 6Perl, not Perl 6.) If you want to call the subroutine in the middle of the string, you should make it _return_ something, not print it. This person obviously expects a pipe

Re: Apoc2 - STDIN concerns

2001-05-14 Thread Bart Lateur
On Thu, 10 May 2001 17:15:09 +0100, Simon Cozens wrote: What you could do, is treat an iterator as something similar to reading a line from a file. Tied filehandles allow something like it in Perl5. You know, if what you say is true, I'd expect to find a module on CPAN which turns the exotic

Re: Apoc2 - STDIN concerns

2001-05-14 Thread Bart Lateur
On Mon, 14 May 2001 12:39:11 +0100, Simon Cozens wrote: I think the more immediate problem with Sather is that it's totally obscure. I'd never heard of it. I'd never read any articles about it. It has no publicity. If people haven't heard of it, it'll remain unpopular.

Re: what I meant about hungarian notation

2001-05-14 Thread Bart Lateur
On Mon, 14 May 2001 20:38:31 +0100, Graham Barr wrote: You forgot $bar[$foo]; # $bar is an array reference $bar{$foo}; # $bar is a hash reference As to what the combined $bar[$foo] would mean: that depends on what $bar contains. (Aw! That hurt!) -- Bart.

Re: Perl, the new generation

2001-05-11 Thread Bart Lateur
On Fri, 11 May 2001 08:20:53 -0400, John Porter wrote: Let's not confuse Perl 6, the Language, with Perl 6, the Implementation, which includes compatibility apparatus that knows about Perl 5. Maybe we need more difference in the names than exactly one bit. Then maybe it's a good thing that

Re: Apoc2 - STDIN concerns

2001-05-10 Thread Bart Lateur
On Fri, 4 May 2001 18:20:52 -0700 (PDT), Larry Wall wrote: : love. I'd expect $FOO.readln (or something less Pascalish) to do an : explicit readline to a variable other than $_ It would be $FOO.next, but yes, that's the basic idea. It's possible that iterator variables should be more

Re: what I meant about hungarian notation

2001-05-09 Thread Bart Lateur
On Tue, 08 May 2001 20:21:10 -0500, David L. Nicol wrote: What if, instead of cramming everything into scalar to the point where it loses its value as a data type that magically converts between numeric and string, as needed, we undo the Great Perl5 Dilution and undecorate references.

Re: what I meant about hungarian notation

2001-05-09 Thread Bart Lateur
I really need to spell-check better. Undecorated if for function calls and methods. And buolt-ins, of course. Undecorated is for function calls and methods. And built-ins, of course. -- Bart.

Re: what I meant about hungarian notation

2001-05-09 Thread Bart Lateur
On Wed, 9 May 2001 11:06:45 -0400, Bryan C. Warnock wrote: At that point, Hungarian notation fell apart for me. Its strict use adds (IMO) as much confusion as MicroSoft's redefinition of C, with thousands of typedefs representing basic types (LPSTR and HWND come to mind as the most common).

Re: what I meant about hungarian notation

2001-05-09 Thread Bart Lateur
On Wed, 9 May 2001 09:47:56 -0400, John Porter wrote: Undecorated if for function calls and methods. And buolt-ins, of course. No, that's the situation already. David is proposing a change. So what you're really saying is that references aren't really scalars, but their own type. Thus they

Re: Apoc2 - STDIN concerns ::::: new mascot?

2001-05-09 Thread Bart Lateur
On Wed, 9 May 2001 10:24:26 -0400, David Grove wrote: I remember someone (whether at O'Reilly or not I don't remember) saying that, even if it looks like a horse but has a hump, it's not allowed. Or was that an alpaca with a llama... The RFC pleads for a community spirit from ORA. Barring that,

Re: Apoc2 - STDIN concerns

2001-05-06 Thread Bart Lateur
On Sat, 5 May 2001 15:22:40 -0700, Nathan Wiger wrote: I suggest that we simply create another q-op to do the qw-ish things you're proposing. Perhaps qi() for interpolate or something else. qqw -- Bart.

Re: Apo2: \Q ambiguity

2001-05-04 Thread Bart Lateur
On Fri, 04 May 2001 15:05:12 -0400, Dan Sugalski wrote: Have you considered allowing Unicode characters as alternatives to some of the less pleasant looking bits? $foo1 (where and are the double angle characters) as an alternative to $foo\Q[1] if the user's got the characters handy? Until

Re: apo 2

2001-05-04 Thread Bart Lateur
On Thu, 03 May 2001 22:14:47 -0500, David L. Nicol wrote: I am going to miss doublequoting being the default quoting for here strings. I find that to be a very nice optimization and would like to know more about the reasoning behind taking it away. I was already panicking when I saw this

Re: apo 2

2001-05-04 Thread Bart Lateur
On Fri, 4 May 2001 10:49:48 -0500 , Garrett Goebel wrote: And btw . . . Wouldn't $thing has property make more sense than $thing is property $foo has true doesn't flow as well as $foo is true. Dunno quite what the other expected uses are. Maybe it is just

Re: Please make last work in grep

2001-05-02 Thread Bart Lateur
On Wed, 2 May 2001 11:41:32 -0500, Jarkko Hietaniemi wrote: but I suspect in this case want('LIST') would return that magical 0 but true or something similar. Hopefully the something similar, I hope in Perl 6 we will able to bury the 0 but true workaround to the backyard on a moonless night

Re: Please make last work in grep

2001-05-02 Thread Bart Lateur
On Wed, 2 May 2001 17:05:31 +0100, Graham Barr wrote: wantarray-ness is already passed along the call stack today. Thats the whole point of it. So what is the difference in passing a number instead of a boolean ? Because you might have a wantarray situation that expects no values? () =

Re: Curious: - vs .

2001-04-27 Thread Bart Lateur
On 26 Apr 2001 23:19:49 -0400, Buddha Buck wrote: $bar = [$obj method() ]; # method call $bar = method $obj() would be more consistent with perl's current $object = new Class() syntax. -- Bart.

Re: Curious: - vs .

2001-04-26 Thread Bart Lateur
On Wed, 25 Apr 2001 15:52:47 -0600 (MDT), Dan Brian wrote: the idea of a dereference operator dumbfounds lots of folks. What's an object got to do with a reference, much less a pointer? A p5 object is very confusing to others for this reason, and so is the syntax. So you want a method

Re: a modest proposal Re: s/./~/g

2001-04-26 Thread Bart Lateur
On Thu, 26 Apr 2001 10:15:14 +0200, Bart Lateur wrote: For example, in -3.4 and in 2-3.4 the - sign is a *different* kind of operator. No conflict. Well alright, in the first line, the - might be part of the number. Replace 3.4 with a variable and it does hold: -$x

Re: a modest proposal Re: s/./~/g

2001-04-26 Thread Bart Lateur
On Wed, 25 Apr 2001 18:19:40 GMT, Fred Heutte wrote: Yes, I know ~ is the bitwise negation operator. Have you EVER used it? Yes. A lot. But there is no conflict. ~ is currently just an unary operator, while your use would be as a binary operator (are those the correct terms?). For example, in

Re: Strings vs Numbers (Re: Tying Overloading)

2001-04-26 Thread Bart Lateur
On Wed, 25 Apr 2001 06:09:56 -0700 (PDT), Larry Wall wrote: Bart Lateur writes: : Er... hip hip hurray?!?! : : This is precisely the reason why I came up with the raw idea of : highlander variables in the first place: because it's annoying not being : able to access a hash passed to a sub

Re: Strings vs Numbers (Re: Tying Overloading)

2001-04-25 Thread Bart Lateur
On Tue, 24 Apr 2001 21:06:56 -0700 (PDT), Larry Wall wrote: : Ok, so what does: : : my %hash = ( 1 = 3); : my $hash = { 1 = 4}; : : print $hash{1}; : : print? 4. You must say %hash{1} if you want the other. Ok. So how about hash slices? Is $hash{$a, $b}, the faked multidimensional hash,

Re: Tying Overloading

2001-04-25 Thread Bart Lateur
On Wed, 25 Apr 2001 11:01:07 -0300, Branden wrote: If the idea is supporting arbitrary add-on operators, which I believe will be done seldom, for only some specific classes, wouldn't it be better to have a ``catch all'' entry for operators different than the built-in ones? Of course, add-on

Re: Sane + string concat proposal

2001-04-25 Thread Bart Lateur
On Wed, 25 Apr 2001 08:25:40 -0400, Stephen P. Potter wrote: | I'm really beginning to like | | $string3 = $string1 _ $string2; | | The underscore indeed connects the two strings. This still breaks because _ is a valid word character. So are cmp, and, lt, and the proposed cat and cc.

Re: Strings vs Numbers (Re: Tying Overloading)

2001-04-24 Thread Bart Lateur
On 24 Apr 2001 00:29:23 -0700, Russ Allbery wrote: How do you concatenate together a list of variables that's longer than one line without using super-long lines? Going to the shell syntax of: PATH=/some/long:/bunch/of:/stuff PATH=${PATH}:/more/stuff would really be a shame. A

Re: Tying Overloading

2001-04-24 Thread Bart Lateur
On Tue, 24 Apr 2001 10:49:18 +0100, Simon Cozens wrote: While that's true, concatenation is quite a common operation that I'd be really uncomfortable with it necessitating 4 keystrokes ( cat) instead of one. Er, ~ is an extremely annoying character to type at many keyboards. It may depend on

Re: Tying Overloading

2001-04-24 Thread Bart Lateur
On Tue, 24 Apr 2001 14:37:02 +0100, Simon Cozens wrote: Let's put it a different way - if we can find a short operator which is readily accessible on most people's keyboards, then that would score over a longer operator which is readily accessible on most people's keyboards. Maybe ~ isn't that

Re: Sane + string concat proposal

2001-04-24 Thread Bart Lateur
On Wed, 25 Apr 2001 00:37:53 +0100, Simon Cozens wrote: $string3 = $string1 . $string2; $string3 = $string1 + $string2; That's now *five* characters required to perform a very common operation. Rather than one. I'm really beginning to like $string3 = $string1 _ $string2;

Re: So, we need a code name...

2001-04-24 Thread Bart Lateur
On Tue, 24 Apr 2001 19:17:08 -0500, Jarkko Hietaniemi wrote: Wasn't Perl also taken, so why care...? I vaguely remember reading about another language called PERL... It was Pearl, AFAIK. That's why the a got missing. So I've been told... (Practical Extracting And Reporting Language... yup,

Re: Strings vs Numbers (Re: Tying Overloading)

2001-04-23 Thread Bart Lateur
On Mon, 23 Apr 2001 16:14:50 -0400, John Siracusa wrote: Using + for concat: no! My vote is to use . and require space before and after. $this.$is.$ugly.$anyway ;) My vote is to ditch the concat operator altogether. Hey, we have interpolation! $this$is$just$as$ugly$but$it$works Which

Re: Tying Overloading

2001-04-23 Thread Bart Lateur
On Mon, 23 Apr 2001 13:19:24 +0100, Graham Barr wrote: Or we change the concatenation operator. I am thinking that maybe it should be a 2 character operator with at least one of then being + as + is common in many other languages for doing concatenation. Or, in analogy to cmp, gt etc:

Re: PDD 4 internal data types, version 1.1

2001-03-30 Thread Bart Lateur
On Thu, 29 Mar 2001 19:24:21 +0200 (CEST), Tels wrote: And then, if we have BigFloat, we need a way to specify rounding and precision. Otherwise 1/3 eats up all memory or provides limits ;o) Er... may I suggest ratio's as a data format? It won't work for sqrt(2) or PI, but it can easily store

Re: Schwartzian transforms

2001-03-29 Thread Bart Lateur
On Wed, 28 Mar 2001 11:11:20 -0500, Dan Sugalski wrote: "Can perl automatically optimize away function and tie calls inside a sort function, and under what circumstances?" It doesn't really matter if the functions inside the sort function are idempotent--what matters is whether it's OK

Re: Schwartzian Transform

2001-03-21 Thread Bart Lateur
On Wed, 21 Mar 2001 15:40:20 -0500, John Porter wrote: Uri Guttman wrote: JP y/L/A/; tell that to perllol :) I do, through clenched teeth, every time I see it. IMHO, it is: HoA HoH LoA LoH -- Bart.

Re: Warnings, strict, and CPAN (Re: Closures and default lexical-scope for subs)

2001-02-22 Thread Bart Lateur
On Wed, 21 Feb 2001 17:32:50 -0500 (EST), Sam Tregar wrote: On Wed, 21 Feb 2001, Bart Lateur wrote: Actually, it's pretty common. Only, most languages are not as forgiving as perl, and what is merely a warning in Perl, is a fatal error in those languages. Examples? I know you're

Re: Warnings, strict, and CPAN (Re: Closures and default lexical-scope for subs)

2001-02-21 Thread Bart Lateur
On Wed, 21 Feb 2001 16:01:39 -0500, [EMAIL PROTECTED] wrote: Has anyone actually used a language which has run-time warnings on by default? Or even know of one? Actually, it's pretty common. Only, most languages are not as forgiving as perl, and what is merely a warning in Perl, is a fatal

Re: Warnings, strict, and CPAN (Re: Closures and default lexical-scope for subs)

2001-02-20 Thread Bart Lateur
On Tue, 20 Feb 2001 16:31:35 -0500, Bryan C. Warnock wrote: Scalar value @foo[$bar] better written as $foo[$bar], for one. I agree on this one (hash slices too), if this expression is in list context. There is no error in @r = map { blah } @foo{$bar}; -- Bart.

Re: ANNOUNCE: smokers@perl.org Discussion of perl's daily build and smoke test

2001-02-19 Thread Bart Lateur
On Mon, 19 Feb 2001 15:47:12 +0100, Johan Vromans wrote: As an active non-smoker, I'd appreciate a different name. You guys (=plural) are nuts. So much bickering over such a tiny irrelevant detail. But anyway, if you want a clear and explicit name, why not "smoketesters". Nothing to do with

Re: The binding of my (Re: Closures and default lexical-scope

2001-02-18 Thread Bart Lateur
On 17 Feb 2001 20:53:51 -0800, Russ Allbery wrote: Could people please take the advocacy traffic elsewhere where it isn't noise? Advocacy is noise everywhere. That doesn't mean that davocates for either side don't have anything interesting to say. For starters, it's usually dissatisfaction

Re: Warnings, strict, and CPAN

2001-02-18 Thread Bart Lateur
On Fri, 16 Feb 2001 21:03:54 -0800, Edward Peschko wrote: It is one hell of a burden to find a missing 'use strict' or 'use warnings'. 'Well, type them then' you say. Right, and always type ';' at each line, or 1; at the end of each file. Its as unavoidable as a *syntax error*, which is the

Re: End-of-scope actions: do/eval duality.

2001-02-16 Thread Bart Lateur
On Thu, 15 Feb 2001 10:04:51 -0300, Branden wrote: Why `do FILE' behaves like eval, if there's eval to do it? Isn't this a little too much not-orthogonal? Why don't we require `eval { do FILE }' to have the behaviour of not dying and setting $@ ? The reason for its existence is simple: history.

Re: End-of-scope actions: do/eval duality.

2001-02-15 Thread Bart Lateur
On Tue, 13 Feb 2001 11:35:16 -0800, Glenn Linderman wrote: In the perl 5 pocket reference 3rd edition page 63, it claims that $@ is set to the result of an eval or do. How does this impact exception handling tests on $@ to determine if an exception was thrown, if $@ can be set by a do ? OR is

Re: assign to magic name-of-function variable instead of return

2001-02-07 Thread Bart Lateur
On Tue, 6 Feb 2001 04:36:36 +1100 (EST), Damian Conway wrote: RFC 271 handles this. Your example would be: sub readit { open F, " $f" ... scalar(F) } post readit { close F; } The connection between these two things is not

Re: vtables: Assignment vs. Aliasing

2001-02-07 Thread Bart Lateur
[CC'ed to language, because I think it's there that it belongs] On Mon, 5 Feb 2001 15:35:18 -0200, Branden wrote: There are two possible things that could happen when you say: $a = $b; @a = @b; # or %a = %b; These two things are assignment and aliasing. No way. Although I think

Re: assign to magic name-of-function variable instead of return

2001-02-05 Thread Bart Lateur
On Sun, 4 Feb 2001 15:43:29 -0500, James Mastros wrote: The $__ option seems a lot better to me, because there's no syntatical reason against self-reference. ($^R for return might be a better name -- unless we've already used that for somthing else. Nope.) What do you mean, "nope"? It *is* in

Re: Really auto autoloaded modules

2001-02-05 Thread Bart Lateur
On Mon, 05 Feb 2001 11:35:59 -0500, Dan Sugalski wrote: use autoload { Bar = 'http://www.cpan.org/modules/Bar' }, { Baz = 'ftp://my.local.domain/perl-modules/Baz', VERSION = 2 }; Very good idea indeed!!! Append the wishlist to add this module to perl6's standard library!!!

Re: Why shouldn't sleep(0.5) DWIM?

2001-01-31 Thread Bart Lateur
On Wed, 31 Jan 2001 08:53:13 -0600, Jarkko Hietaniemi wrote: So nice of you to volunteer for being our help desk person man for explaining to people why their time() just got broken :-) I'd use the same function name for both the integer version of time(), and the hires version. All you need is

Re: safe signals + sub-second alarms [was: sleep(0.5) should DWIM]

2001-01-31 Thread Bart Lateur
On Wed, 31 Jan 2001 11:36:32 -0500, Ken Fox wrote: You want perl to block a thread and then busy wait until it's time for the thread to wake up? What if we take the ordinary sleep() for the largest part of the sleeping time (no busy wait), and the 4 argument select for the remainder, i.e.

Re: RFC195: Do not remove 'chop' PLEASE!

2001-01-29 Thread Bart Lateur
On Mon, 29 Jan 2001 11:47:47 -0500, Uri Guttman wrote: well, according to this perl5.6.0 -le '%h = qw( a b c d ); $_ .= 1 for %h ; print values %h ; chop %h ; print values %h' b1d1 bd it doesn't appear to be a chop specific thing. unraveling a hash always seems to use aliases for the values.

Re: JWZ on s/Java/Perl/

2001-01-28 Thread Bart Lateur
On Sat, 27 Jan 2001 18:16:52 -0500, Michael G Schwern wrote: o The architecture-interrogation primitives are inadequate; there is no robust way to ask ``am I running on Windows'' or ``am I running on Unix.'' **We have $^O, but it requires parsing every time** Uhm, I'm

Re: RFC195: Do not remove 'chop' PLEASE!

2001-01-28 Thread Bart Lateur
On Sat, 27 Jan 2001 15:42:43 -0700, root wrote: I read RFC195 suggesting to drop 'chop' and go with 'chomp'. What does 'chop' have anything to do with 'chomp'? I'm totally oppose to that. Consider: my $s; map { /\S/ $s .= "$_ " } split(/\s+/,@_); chop($s); return $s; Excuse me, but you're

Re: perl IS an event loop (was Re: Speaking of signals...)

2001-01-08 Thread Bart Lateur
On Sat, 6 Jan 2001 00:45:11 +, Simon Cozens wrote: No, it's exactly what Perl 5 does. This is the Perl interpreter: while ((PL_op = CALL_FPTR(PL_op-op_ppaddr)(aTHX))) { PERL_ASYNC_CHECK(); } The only problem is that right now, PERL_ASYNC_CHECK doesn't actually do anything.

Re: Now, to try again...

2000-12-18 Thread Bart Lateur
On Sun, 17 Dec 2000 14:11:50 -0700 (MST), Nathan Torkington wrote: I think the problems with this that were raised in the past are: * parsing partial source * does this mean that the parser has to reparse the whole sourcefile every time you type a character? Hold it. I don't think that is

Re: SvPV*

2000-11-24 Thread Bart Lateur
On Fri, 24 Nov 2000 08:54:43 +0100, Roland Giersig wrote: Maybe the title should be : "Perl should use XML as its basic data type instead of linear strings" Horrible. I kinda liked your original proposal. But you should NOT focus on XML. That leaves out too many other possible data sources:

Re: To get things started...

2000-11-22 Thread Bart Lateur
On Tue, 21 Nov 2000 17:24:49 +, Simon Cozens wrote: I really *would* recommend Aho, Sethi, Ullman, "Compilers: Principles, Techniques and Tools". AKA "The Dragon Book". You're not the only one to mention this book on this list. IMO, this book is really thick to crawl through, and in the

Re: To get things started...

2000-11-22 Thread Bart Lateur
On Wed, 22 Nov 2000 14:15:57 -0500, Dan Sugalski wrote: We bootstrap on perl5 to get a bytecode stream, and then that bytecode stream had better stay supported. Yup. It's one way to ensure backwards compatibility... :) I assume a byte is still 8 bits? So you have a max of 256 different (1

Re: Critique available

2000-11-03 Thread Bart Lateur
On Thu, 2 Nov 2000 16:10:12 +, Simon Cozens wrote: On Thu, Nov 02, 2000 at 10:11:56AM -0500, Mark-Jason Dominus wrote: My critique of the Perl 6 RFC process and following discussion is now available at http://www.perl.com/pub/2000/11/perl6rfc.html Agree 100% to every point.

Re: code name for perl 6

2000-10-20 Thread Bart Lateur
On 19 Oct 2000 22:01:23 -, [EMAIL PROTECTED] wrote: the code name "omega" would be a fitting handle...after all, this will be the last perl of all...i am obviously assuming perl 6 will not be still born. Hey, why not something in the line of "2PI" ("P2PI"?). After all, 2 * PI is what the

  1   2   3   >