Author: larry
Date: Wed Oct 8 12:06:24 2008
New Revision: 14590
Modified:
doc/trunk/design/syn/S13.pod
Log:
wrong year, ruoso++
Modified: doc/trunk/design/syn/S13.pod
==
--- doc/trunk/design/syn/S13.pod
Author: larry
Date: Thu Oct 9 16:40:10 2008
New Revision: 14591
Modified:
doc/trunk/design/syn/S02.pod
doc/trunk/design/syn/S03.pod
doc/trunk/design/syn/S12.pod
Log:
Make operator adverbs parse sanely based on precedence. They are now treated
as "loose unaries" (albeit
Author: larry
Date: Sat Oct 11 11:39:24 2008
New Revision: 14593
Modified:
doc/trunk/design/syn/S06.pod
Log:
clarify use of [...] and {...} in a signature
Modified: doc/trunk/design/syn/S06.pod
==
--- doc/trunk
Author: larry
Date: Sat Oct 11 11:58:34 2008
New Revision: 14594
Modified:
doc/trunk/design/syn/S06.pod
Log:
copy/paste error, moritz++
Modified: doc/trunk/design/syn/S06.pod
==
--- doc/trunk/design/syn/S06.pod
Author: larry
Date: Tue Oct 14 17:14:18 2008
New Revision: 14595
Modified:
doc/trunk/design/syn/S02.pod
doc/trunk/design/syn/S04.pod
doc/trunk/design/syn/S06.pod
doc/trunk/design/syn/S09.pod
doc/trunk/design/syn/S12.pod
Log:
delete ambiguous use of {...} for hash unpacking, just
Author: larry
Date: Wed Oct 15 07:57:21 2008
New Revision: 14596
Modified:
doc/trunk/design/syn/S12.pod
Log:
be a little more true to the lyrics...
Modified: doc/trunk/design/syn/S12.pod
==
--- doc/trunk/design/syn
Author: larry
Date: Thu Oct 16 09:34:30 2008
New Revision: 14597
Modified:
doc/trunk/design/syn/S03.pod
Log:
rename infix: to infix:
Modified: doc/trunk/design/syn/S03.pod
==
--- doc/trunk/design/syn/S03.pod
Author: larry
Date: Fri Oct 17 08:24:48 2008
New Revision: 14598
Modified:
doc/trunk/design/syn/S03.pod
Log:
explicit use of term "short-circuit" suggested by Eirik-Berg.Hanssen++
Modified: doc/trunk/design/s
Author: larry
Date: Tue Nov 4 15:14:32 2008
New Revision: 14599
Modified:
doc/trunk/design/syn/S02.pod
Log:
Define () as the Nil type
Modified: doc/trunk/design/syn/S02.pod
==
--- doc/trunk/design/syn/S02.pod
Author: larry
Date: Fri Nov 7 09:02:15 2008
New Revision: 14600
Modified:
doc/trunk/design/syn/S02.pod
Log:
add $?VM and $?DISTRO, recast versions as object info
Modified: doc/trunk/design/syn/S02.pod
==
--- doc
Author: larry
Date: Fri Nov 7 09:54:43 2008
New Revision: 14601
Modified:
doc/trunk/design/syn/S03.pod
doc/trunk/design/syn/S12.pod
Log:
get rid of pair methods; $obj ~~ :foo($bar) now simply does $obj.foo ~~ $bar
with all other adverbial pair notations having corresponding meanings, so
Author: larry
Date: Fri Nov 7 10:10:52 2008
New Revision: 14602
Modified:
doc/trunk/design/syn/S02.pod
Log:
recast $?FOO matching in terms of new pair matching syntax
Modified: doc/trunk/design/syn/S02.pod
Author: larry
Date: Fri Nov 7 16:04:15 2008
New Revision: 14603
Modified:
doc/trunk/design/syn/S03.pod
Log:
smartmatch of Hash against Pair should match against both key and value
Modified: doc/trunk/design/syn/S03.pod
Author: larry
Date: Fri Nov 7 18:00:20 2008
New Revision: 14604
Modified:
doc/trunk/design/syn/S03.pod
Log:
copy/paste error
Modified: doc/trunk/design/syn/S03.pod
==
--- doc/trunk/design/syn/S03.pod
Author: larry
Date: Mon Nov 17 17:12:39 2008
New Revision: 14606
Modified:
doc/trunk/design/syn/S05.pod
Log:
Refinement to LTM tiebreaking rules so that foo matches before \w\w\w
and fo\w matches before f\w\w.
Modified: doc/trunk/design/syn/S05.pod
Author: larry
Date: Fri Nov 21 15:16:01 2008
New Revision: 14607
Modified:
doc/trunk/design/syn/S02.pod
doc/trunk/design/syn/S06.pod
Log:
various clarifications
Modified: doc/trunk/design/syn/S02.pod
==
--- doc
Author: larry
Date: Fri Nov 21 15:40:52 2008
New Revision: 14608
Modified:
doc/trunk/design/syn/S06.pod
Log:
typo
Modified: doc/trunk/design/syn/S06.pod
==
--- doc/trunk/design/syn/S06.pod(original)
+++ doc
onvincing arguments
: to get any of those changes through.
:
: That said, if you can make a convincing argument for a feature's
: inclusion then do so. The types of arguments that are likely to win
: over Larry (I'm guessing) are things that make easy things easier,
: hard things easi
at are broken, or that could be designed
: DC> better with hindsight. Backwards compatibily was to be fed to the lions.
:
: DC> If that isn't the case, I'll be unsubscribing immediately -- if Perl 6
: DC> is to be a mere exercise in featuritis, I'm not interested.
:
: The
ble. That is, you set
it on an input stream object, not on a chunk of code.
Larry
It may help to squint.)
Actually, that was one of the reasons I picked % in the first place.
Larry
ss derived from an IO object, depending
on how we decide to do things.
Larry
rl6.
: >
: > Unless there's a:
: >
: >use HiRes::Time qw(time);
: >
: > in effect!
:
: Well theres a difference there when you look at the op tree. That is a call
: to a sub, whereas otherwise it is a op.
Theoretically, we'd like to make subs run as fast as ops.
Larry
default
output has always been a selling point of REXX, actually.
Let me reiterate my view of pragmas. They can warp the language any
way you please, as long as they don't impact other modules. I wouldn't
even mind if someone wrote a pragma that lets you program Perl in Latin.
Larry
#x27;t do that.
: They autoviv an object.
Yes, but then each of those has to be explained specially. People
*expect* assignment to "autovivify", as it were. But open() et al
are essentially a 3rd syntax for constructors, and that's about one
syntax too many, give or take a few.
Larry
format objects. Every
one of these global variables needs to be scrutinized to see if it
should be replaced with a lexically scoped variable.
If there are any left after that, then we could certainly consider
putting them into global hashes.
Larry
g some
: > organized record of the responses I've received, but who shall decide
: > (before Larry decides)?
:
: You have to determine the status, but that shouldn't be scary,
: considering these RFCs are ultimately just recommendations for
: Larry's consideration. Since t
regex syntax!
On the other hand, if they're so bad, why are several other languages
now advertising that they support "Perl 5 regular expressions"? :-)
Of course, we do want to stay ahead. But we must be careful not to
confuse change with progress.
Larry
moved study out into an external module, we'd
still have to find some way to treat searching for constant strings as
polymorphic within the regex engine.
Larry
Johan Vromans writes:
: On Mon, Jul 31, 2000 at 09:50:11PM -0600, Nathan Torkington wrote:
: > So Larry is doing most of the evaluation for us. He's the one who
: > gave us the good things in the Perl language we have now. He'll be
: > the one vetoing the ridiculous ide
d reading for
anyone who aspires to be a Perl designer.
http://windows.oreilly.com/news/hejlsberg_0800.html
Larry
#x27;s the case, it might be a danger signal that we're
overreaching, and we'll have difficulty dragging Perl 5 code into the
Perl 6 world.
I could be wrong about that. Whether or not we use Perl 5 to emulate
unimplemented opcodes, we still to keep Perl 6 near Perl 5 for all the
other reasons.
Larry
Jonathan Scott Duff writes:
: On Wed, Aug 02, 2000 at 10:57:27AM -0700, Larry Wall wrote:
: > raptor writes:
: > : http://www.oreillynet.com/pub/a/linux/rt/07282000/transcript.html
: >
: > That's a good summary of what we've been thinking. Here's another
: > art
n Perl 6, so we
can't just throw them out and say the input disciplines will do it all.
Even if chop and chomp are not longer the preferred way of doing it,
we'll still have to emulate the functionality somehow.
Larry
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
A%3Aoh>
:
:
: OTOH, try this:
:
: $hash{a'b} = 1;
: print keys %hash;
: -->
: a::b
:
: That shows that the current situation is not ideal, anyway.
:
: Besides, p52p6.pl can handle the conversion.
Alternately:
use ident qr/[A-Za-z_][A-Za-z_0-9']*/;
or some such.
Larry
ion into the regular expressions used in a particular
package.
Larry
rface revisions, not implementation revisions?
Basically, there are some more things we have to think about if we
really want to do Best Fit rather than First Fit. And I think we do.
Larry
rt of the package name,
rather than as a 3rd argument to use.
Think about the long names of fonts for an example of how far this
can be taken.
Larry
now is how much those independent
documents should be independent (where the code itself is considered
one of the documents).
Larry
Dan Sugalski writes:
: At 11:11 AM 8/9/00 -0700, Larry Wall wrote:
: >Dan Sugalski writes:
: >: Does that mean, then, that when module A does a "$C::bar = 1" it affects a
: >: different package namespace than module B doing a "$C::bar = 2"?
: >
: >Presumab
[EMAIL PROTECTED] writes:
: =head1 IMPLEMENTATION
:
: This strikes me as being a fairly easy thing to do, but then again
: internals ain't my thing, baby.
The problem I see here isn't the internals--it's how do you translate
Perl 5 to Perl 6?
Larry
[EMAIL PROTECTED] writes:
: p52p6 would handle it (by translating all Perl 5 C"y">'s to Perl 6
: C<'x',"y">'s.
:
: I *must* put this in the RFC!
I think most of the RFCs could use a MIGRATION POLICY section, or
some such.
Larry
t a modifier like "constant" in the type slot. The syntax for
variable attributes will look more like this:
my num $PI : constant = 3.1415926;
my int @FIB : constant = (1,1,2,3,5,8,13,21);
my str %ENG_ERRORS : constant = (E_UNDEF=>'undefined', E_FAILED=>'failed');
Larry
e it can be refined into a good idea,
and maybe it can't. But voting is unlikely to help there either.
Voting doesn't produce consensus. Discussion sometimes does.
Larry
ave differently.
:
: I think we'll need to get a ruling from Larry at some point on this one.
I haven't been terribly happy with tie for some time. I'd rather we had
more type-based approach, which could:
1) factor the work out to one spot so you wouldn't have to call
eters to a subroutine), and then have a way of "undeclaring"
constancy if you really want it. It would perhaps be considered bad
form to vary someone else's constants. (Outside of Indiana.)
Larry
own epoch, like the year 2000. Or use a
really standard one, like the year 0 AD (aka 1 BC).
I have this horror that people will still be using 1970 as the epoch in
the year 31,536.
Larry
sogie" and new syntax
: for range operators and such ;) And I think it's something that
: everyone can agree on, since there's a lot of benefit to be had, and no
: down-side that I can see.
:
: Let's make Perl 6 an awesome language for object-oriented development.
Can't disagree with that, as long as we don't trade away too much for it.
Larry
next version of Perl.
: These can be big things (currying) or small (hashes returned by
: functions instead of long lists). We're giving input to Larry, who
: will then design the language. We are just telling Larry what we
: would like, and why (i.e., which itch it would scratch).
And my
prototype of func.
Does Text::Balanced take into account functions declared with a
prototype of ()?
Larry
ng out the internals.
It really depends on what you mean by "implement". This stuff is
syntactic sugar. To the first approximation, syntactic sugar is
trivial to implement.
To the second approximation, the first approximation is totally bogus.
Larry
been amply reminded of this, thanks :-) (Too little time
: to spend on RFCs...)
Yes, but has anyone pointed out that
@out = sort ^b cmp ^a, @in;
won't do what people will certainly think it ought to?
Larry
at happens
to do nothing, so that you can run your examples through perl -c for
syntax checks. Or better, make it an official "stub" for rapid
prototyping, with some way of getting a warning whenever you execute
such a stub.
Larry
.. ""
If you want to be able to reset, then say
/(^neur.*)/ .. !$x++# reset with $x = 0;
Larry
Ariel Scolnicov writes:
: I was asked to debug a weird Perl5 problem yesterday. The code in
: question looked roughly like this (indented 4 spaces, but otherwise
: unchanged):
:
: #!perl -w
: use strict;
:
: print <
Ed Mills writes:
: But don't {} or {1} sort of do the same thing?
Well, { warn "Encountered stub"; (); } would be more like it. But the
biggest problem with {} or {1} is that they don't resemble an ellipsis.
Larry
ely. I think it should just Do The Right Thing.
:> (I suspect it should ignore spaces on the left to.)
:
: Hear, hear.
:
: And whilst you're in a mood to ignore whitespace, how about C<$/ = "">
: terminating on C?
I'm more inclined to ignore $/ these days. :-)
Larry
... 4, 5, 6;
with the binary operator in:
print 1, 2, 3 ... 4, 5, 6;
Larry
up with a real interface, and then if
we want to reuse the (the presumably missing) dump keyword for some
method name or other, that's fine. But we're currently designing it
from the wrong end.
Larry
in an array, you had to use eval.
So certainly there's room for an interface that can take multiple regex
objects and turn them into a single super regex. I don't think the
code to do it necessarily belongs in the core, but it would certainly
have to be somewhat incestuous with regex innards.
Larry
27;a', 'b', 'c', ...)
print (3, 1, 4, 1, 5, 9, 6, 2, 5, ...)
: BTW, I propose the this new operator be pronounced "yadda yadda yadda". :-)
If you want to save the world, come up with a better way to say "www".
(And make it stick...)
Larry
John Porter writes:
: Could you make it "evaporate" and compile time, just like the (proposed) qc()?
Hard to make it evaporate at compile time and still give a warning at
run time. :-)
Larry
l its attached state into
: something that can be loaded in later somewhere else.
Now all we have to do is make the program a variable, and the two
requirements become one.
Larry
:)
I was wondering this morning whether we ought to write the Perl 6
parser as a set of recursive regexes. Might make it easier to plug in
new productions on the fly. And designing the parser around regexes
might indicate ways in which Perl's regexes are not yet powerful
enough.
Larry
cream/) {
: push @funx, sub {
: print "I'll take a $name one, please, with @_.\n";
: };
: }
:
: dump \@funx;
:
: Closures will be challenging. :-)
Well, scratch it hard enough and you'll see that we're just discussing
persistent continuations.
Larry
rl, we'd need to be able to match a substring, and
: Joe> then call an arbitrary function in the middle of a pattern match,
: Joe> and to back out the call if the match failed.
:
: Already done in 5.6. :) "perldoc perlre".
At the moment, there's no way for the call to "fail". Unfortunately.
Larry
Suresh Kumar R writes:
: Perl should become PEARL
Er, the folks at http://www.irt.uni-hannover.de/pearl/pearl-gb.html
might have something to say about that.
Larry
rray currently has in a boolean context, but one can imagine
funny array types that pick their own meanings for:
@a->bool
@a->len
@a->num
@a->str
...
Larry
quot;ERROR::" part for brevity -- but not for clarity.
I think I agree with the folks that say errors should be caught by
type, not by number. Just as a for instance, you ought to able to
write a simple handler that catches any ERRNO-style error.
Larry
approach is that we'd break the rule that says
references are always true. Not clear if that's a problem. It's basically
already broken with bool overloading, and defined still works.
Larry
estion of how you specify the use of an object list
prototype on assignment. Hmm.
(@foo, @bar) \= (@bar, @foo);
Dunno if I like that or not.
Larry
P.S. I think we *could* let @foo and %bar return an object ref in scalar
context, as long as the object returned overloads itself to be
, Java, or C# routine can supply all the glue information formerly
supplied by XS. While this will undoubtedly give us some rather
strange looking Perl, I'd rather look at potentially strange Perl than
certainly strange XS.
Larry
David Grove writes:
: [1] Strongs is pure Koine. I'd think Larry would be more of the Ionic
: type.
You might say I get a charge out of Homer. :-)
Actually, I've done more Attic than Ionic. And I haven't done enough
of any of them to get very far from my lexicon. But I s
b) or @a->inner:*(@b) or some such. It might even
mean that we can have a URL literal type, if we can figure out how to
parse it, and if there's any good reason to treat a URL as more than
just a string:
print $::OUT http://www.wall.org/~larry/index.html;
But I really mustn't spill to
#x27;t mean
he plans to set up headquarters there. There are broader issues at
stake. So I'd appreciate it if my soldiers would refrain from killing
each other over what color to paint the foxhole.
Larry
We declare our variables
in the smallest possible scope if we want to avoid unforeseen interactions
with other code elsewhere. Similarly, syntactic munging should only
tweak that smallest part of the grammar that it can get away with to
accomplish what it needs to.
Larry
es looking like this:
my http is Foo::Bar::Http:GSAR:3.0.1 ...
As for what we currently do with "use", I'm not sure the exact syntax
yet, but since "use" currently imports ordinary modules to the package
space, the p526 translator might turn non-pragmas into some kind of an
"our" declaration.
Anyway, just some more ballistic ideas to randomize all your eyeballs.
Larry
a token. (Or whitespace for that
: matter--Whitespace isn't just whitespace in python mode)
That is correct. Standard Perl 6 will end up working a lot like Perl 5,
but that's by convention, not by restriction.
Larry
it's
possible that if @dogs (as an array) doesn't have a bark method, but
each Dog scalar does, then
@dogs.bark;
might do the right thing. I dunno about that yet. We can't just
assume the method is distributed over the array, or we won't be able to
get to methods resembling length(@dogs).
Larry
Stephen P. Potter writes:
: Maybe this is a crazy (or stupid) idea, but why couldn't we use the $, @,
: and % characters?
:
: @foo = @a @+ @b; # element by element add
Because it's difficult to tell the operators from the terms visually.
Larry
Nathan Wiger writes:
: Larry Wall wrote:
: >
: > : I _really_ think dot-syntax would make perl prettier as well as make it
: > : more acceptable to the world of javacsharpbasic droids. Which is some
: > : kind of goal, no?
: >
: > Consider it a given that we'll be us
context, and a no-op
in list context. That is, $() and @() would essentially be typecasts.
Larry
and a + in scalar context is going to do the right thing with arrays
in scalar context. It's possible that a bare = could be made to work
too, but it implies copying a list, where := only implies copying
a pointer.
Larry
Graham Barr writes:
: On Mon, Apr 23, 2001 at 11:40:50AM -0700, Larry Wall wrote:
: > I do expect that @() and $() will be used for interpolating list and
: > scalar expressions into strings, and it is probably the case the $()
: > would be a synonym for scalar(). @() would then be a sy
Bart Lateur writes:
: Or, in analogy to "cmp", "gt" etc:
:
: $a = $b plus $c;
: or
: $a = $b cat $c;
It would probably have been C if it had come to that.
Larry
Simon Cozens writes:
: On Mon, Apr 23, 2001 at 11:48:35AM -0700, Larry Wall wrote:
: > :@foo = @( a + b ); # element by element add of @a and @b
: > I expect that's be written:
: >
: > @foo := @a + @b;
:
: Two different assignment operators? I can understand the inte
John Porter writes:
: Larry Wall wrote:
: > I do expect that @() and $() will be used for interpolating list and
: > scalar expressions into strings, and it is probably the case the $()
: > would be a synonym for scalar(). @() would then be a synonym for
: > the mythical list() oper
[EMAIL PROTECTED] writes:
: On 4/23/01 3:25 PM, Larry Wall wrote:
: > : >From a trainer's point of view, having two operators which look very
: > similar, : are used for the same thing in various different languages, and do
: > *almost* : the same thing but not quite, is comple
oing to do that.
: The bottom line is: please don't change the syntax, unless it's
: unavoidable. It will cost many time of reading code until finding bugs
: because of operators that used to work and don't work anymore...
That is a consideration, but there's no such thing as absolutes here.
All change is avoidable at some price. I don't intend to pay that price.
Larry
John Porter writes:
: Larry Wall wrote:
: > Surely it's not the . itself, but the requirement that you fit everything
: > into that one syntactic mold. Perl's not going to do that.
:
: I'm not opposed to the change, but I want to make one point:
: certain characters (lik
inner rule ought to terminate,
and it is the choice of the inner rule whether to follow the convention
suggested by the outer rule. A rule that starts at a left parenthesis
will suggest stopping on a right parenthesis, but if the inner rule
is parsing troff, all bets are off on properly nesting parens.
Larry
e "\E"
: actually serves a purpose.
:
: But, you may completely forget about it. I just had to say this one day.
No, I already thought of that one yesterday, and I agree with you completely.
Though \E is probably not it.
Well, they're calling my flight, so I'd better shut down. (On layover
in Phoenix.)
Larry
Edward Peschko writes:
: I guess my question is what would be the syntax to access hashes? Would
:
: $hashref.{ }
:
: be that desirable? I really like ->{ } in that case..
It won't be either of those. It'll simply be $hashref{ }.
Larry
Edward Peschko writes:
: 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.
Larry
Bart Lateur writes:
: Ok. So how about hash slices? Is $hash{$a, $b}, the faked
: multidimensional hash, going to go?
Yes, fake multidimensional hashes will be defenestrated.
Larry
;ll probably distinguish eating a list in list
context from eating a list of scalars, so you could pass a list of
arrays easily to a variadic function with each variable name in
scalar context so as to produce a reference.
This is a little hard to explain, but I intuit that it will turn out to
be intuitive.
Larry
Eric Roode writes:
: John Porter wrote:
: >IIUC, this ability is precisely what Larry was saying Perl6 would have.
:
: I may have my history wrong here, but didn't Ada try that?
Not at all. The syntax of Ada was nailed down tighter that almost any
language that ever existed.
: Super-
s diversity was driven in part by its
lack of support for other programming paradigms. I don't see Perl
falling into that trap any time soon either...
Larry
aring the argument that Perl programmers can't get
used to a different operator for concatenation. I know better--after
all, Perl is probably what got them used to . in the first place. If
you can teach dogs to salivate at a bell, you can probably teach them
to salivate at a dog biscuit. :-)
Larry
601 - 700 of 3168 matches
Mail list logo