Sam Tregar wrote:
>
> On Thu, 31 Aug 2000, David L. Nicol wrote:
>
> > We're talking about making a faster Perl. C's syntax requires enough
> > clarity to compile to something quick. it is a very short hop from
> > my dog $spot;
> > to
>
Nathan Wiger wrote:
>
> "David L. Nicol" wrote:
> >
> > They gain us compliance with the whims of the people who like barewords
> > for variable names. You may or may not find that to be a good thing.
>
> It's not just that I don't think drop
>
> That is if multi-dimensional arrays are implemented as lists-of-lists,
> which they might not be.
Even if they aren't implemented as lol, they may appear as lol to the programmer
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"My baby done left me,
she done went to the drive-in movies with somebody else."
be clarified without run-time inputs.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
David Corbin wrote:
> A C JIT is an interesting idea.
>
> I think that a project works best when it has a set of goals (I haven't
> seen one yet really for Perl 6). Unless this is one of the goals, I can
> easily see how this could become a serious distraction to what
>{@{\(a..h)}} because
of the context-based overloading of dotdot -- so to make $$r{a..h}
work we would need to both allow an array in container resolution brackets
to mean sequential access but also make that an array context. But
using dot-dot in there is awfully contrived.
--
?
> >
> >I think this is a superb idea, and look forward to someone's RFC'ing it.
>
> I like it too. Anyone working on the RFC?
> --
> Peter Scott
> Pacific Systems Design Technologies
the assignment from lazy syntax described in
http://dev.perl.org/rfc/123.html
my $int = {};
for (keys %{$_[0]}){
$$_[1]{$_} and $$int{$_} = 1;
};
return $int;
};
See?
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
perl -e'@w=<>;for(;
) by mercury.Sun.COM
(8.9.3+Sun/8.9.3) with ESMTP id OAA27600; Fri, 1 Sep 2000
14:52
Nathan Wiger wrote:
>
> "David L. Nicol" wrote:
> >
> > No, that would be
> >
> > dog $spot;
>
> No, it wouldn't:
>
> $r = new
John Porter wrote:
>
> David L. Nicol wrote:
> >
> >
> > How about ALLOWING bareword everything-else? Start having
> > filehandles work the way everyone expects them to at first,
> > passing as arguments and so forth, without any special treatment?
lazy would work too, you can pull off the first grepped
value and if you don't go back for another the thing will get dismantled
when the current scope closes.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
perl -e'@w=<>;for(;;){sleep print[rand@w]}' /usr/dict/words
ged scalars which
magically convert so fluidly.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
perl -e'@w=<>;for(;;){sleep print[rand@w]}' /usr/dict/words
ne starting "#do " does not match any known
C preprocessor commands and is therefore a perl comment, and
s/x/5/; # this is still going to replace
# all the eckses in $_ with fives.
To test if x is five or not, something like this would be in order:
Nathan Wiger wrote:
>
> "David L. Nicol" wrote:
> >
> > s/x/5/; # this is still going to replace
> > # all the eckses in $_ with fives.
>
> Why? This is an arbitrary decision if you've declared variables to be
> barewords.
imal representation,
no reason to throw that away.
> Dirk
thanks for your support
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
perl -e'@w=<>;for(;;){sleep print[rand@w]}' /usr/dict/words
mailing-lists/modules/2000-08/msg00078.html
module does it.
To use the perl function even after it has been hidden,
it can be referred to by its absolute name CORE::chmod.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
perl -e'@w=<>;for(;;){sleep print[rand@w]}' /usr/dict/words
John Porter wrote:
>
> David L. Nicol wrote:
> >
> > A bareword inside doublequotes is not interpreted, in Perl or C.
>
> No; a "bareword" in quotes (any kind) is not a bareword.
>
> --
> John Porter
huh?
--
Johan Vromans wrote:
> my $file_format = qf(
> @<: @
> $name, $ssn
> );
>
> Now, $file_format would be a Format object (compare this with qr//,
> that produces a Regex object).
or the proposed qs// which would produce a packed structure definition
I wrote a map w/o last but erased it for brevity :)
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
perl -e'map{sleep print$w[rand@w]}@w=<>' /usr/dict/words
al perl to me.
>
> --
> John Porter
I'd like to see next/last/redo in such situations pertain to the
block from which the sub was called, if that makes sense.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
perl -e'map{sleep print$w[rand@w]}@w=<>' /usr/dict/words
x27;m for putting it after a comma. Which matches the syntax of
John Porter's proposal about internally converting the block to a subroutine.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
perl -e'map{sleep print$w[rand@w]}@w=<>' /usr/dict/words
if overused.
I admit to being a bit sentimental about chop, but I can't think of
any exciting reasons to keep it. The parity reasoning, however
strikes me as a bad idea/precedent.
dha
--
David H. Adler - <[EMAIL PROTECTED]> - http://www.panix.com/~dha/
Just Install Perl. - Chris Nandor
tes them as needed for better compliance with
projected remote schema based on experience.
That trick is beyond the scope of what I believe are suggestions for reasonable
incremental improvements to a programming language.
That is where I draw the line.
--
: print "one"; exit; two: print "two"; print three: grep {
($_ == 25 and goto three) or !($_ %
3) } (1..30)'
syntax error at -e line 1, near "three:"
Execution of -e aborted due to compilation errors.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
perl -e'map{sleep print$w[rand@w]}@w=<>' ~/nsmail/Inbox
ng the "gatekeeper" idea without C we get these:
> "yes" and abort after this one
my $gatekeeper = 1;
($FirstSmall) = grep
{ $gatekeeper and $_ <= 7 and ($gatekeeper = 0), 1 } @numbers;
> "no" and abort after this one
better than
%newhash = map {($_,transform $somehash{$_})} @keysubset;
but you can certainly come up with a reasonable example. Listing inventories
by department, for instance. By yielding we would save the creation of the
per-iteration temporary and push directly onto the result.
--
yield (push @array1, $_);
yield (push @array2, $_);
yield (push @array3, $_);
push @array4, $_;
};
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
perl -e'map{sleep print$w[rand@w]}@w=<>' ~/nsmail/Inbox
do exceptions. Loop control
structures catch these objects and throw them again
if they are labeled and the label does not match a label the loop control
structure recognizes as its own.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
perl -e'map{sleep print$w[rand@w]}@w=<>' ~/nsmail/Inbox
Mark-Jason Dominus wrote:
>
> The perl 5 -> perl 6 translator should replace calls to 'eval' with
> calls to 'perl5_eval', which will recursively call the 5->6 translator
> to translate the eval'ed string into perl 6, and will then eval the
> result.
And that gives us a convenient name space for
de loops, if that was a lvalue it
could be set to the end of the data, or set back to the beginning for
that matter, to effect a last or a redo.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
perl -e'map{sleep print$w[rand@w]}@w=<>' ~/nsmail/Inbox
'John Porter' wrote:
>
> David L. Nicol wrote:
> > "Randal L. Schwartz" wrote:
> > >
> > > I think we need a distinction between "looping" blocks and
> > > "non-looping" blocks. And further, it still makes sense
Hugo wrote:
>
> In <[EMAIL PROTECTED]>, "David L. Nicol" writes:
> :I think I did -- I guess v2 didn't make it in; I sent it again; what
> :were your and mjd's comments again?
>
> Here are the messages:
> http://www.mail-archive.com/perl6
a whole new language. Language or dialect? Who cares?
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"The most powerful force in the universe is gossip"
ion to take it's arguments in infix instead of prefix manner.
sub cmpi($cmpi$){ # or something like this
uc(shift) cmp uc(shift)
}
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"The most powerful force in
ttribute. Your code becomes
print "Found It at position ${_:n}!\n" if /$seek/ foreach @items
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"A taste so good that we stand behind every bottle and can."
Webmaster wrote:
>
> (I have attached a prototype of what I had in mind)
>
> From: "David L. Nicol" <[EMAIL PROTECTED]>
> > Yes, that is exactly what is being suggested, but the "indexof" function
> > is implicit in the attribute. Your code bec
John Porter wrote:
>
> David L. Nicol wrote:
> >
> >
> > print "Found It at position ${_:n}!\n" if /$seek/ foreach @items
>
> If we are going to be throwing around attributes like that, why
> don't we switch to using the ubiquitously recog
>
> This is a new feature, so name conflict is the only issue.
>
> Thisseems compatiblewith otherextensionsto string
> interpolation... whatever extensions get implemented should work here
> too.
it's not a new feature. It's amazing the subtle control you
can get with
Robert Mathews wrote:
>
> "David L. Nicol" wrote:
> > it's not a new feature. It's amazing the subtle control you
> > can get with s/(\$...)/$1/ge depending on your
>
> You mean /gee, right? Hadn't thought of that. /ee makes
I'd be all for the XML documentation idea, either as a replacement
for or as a substitute for POD. However, I'd like to note that if you
want XML documentation in your Perl code, POD really makes it easy:
=for XML (or DocBook, or whatever)
Simply require yourself to use only POD sections lik
pe_out_here = with;
if ($ints) {
with $scope_out_here {use integer}
};
C is about subroutine calls.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"After jotting these points down, we felt better."
parate from STRING and
NUMBER so that if you know, you can suggest which behavior you want out
of a particular scalar variable, or stick with the misguidable default.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"After jotting these points down, we felt better."
use real;
sub pi_teration{
# one iteration of some pi-finidng algo
...
};
use integer;
# did I or did I not just hork my pi_iteration routine?
> So I like the idea of C, but am not sure it is compeltely
> suitable for
g =~ s/\[(\w+)\]/defined($vars{$1})?$vars{$1}:"[$1]"/ge;
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"After jotting these points down, we felt better."
ead. If it
> isn't there, it should be. I think this is definitely a cool idea.
>
> Dave
it can be done with sub references. With caller->eval it could be done
with a stub function that does
caller->eval{ &$subname }
--
e this magic might invalidate any gains from doing
it this way.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"After jotting these points down, we felt better."
ra point"
could be expressed in gamerules::americanfootball as
now $points{touchdown} = 1;
now $points{fieldgoal} = 1;
...
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
I don't watch TV, I have no telephone, and I vote
h? :)
I meant that at the end of the extra-point phase, the score valuations
will return to their normal values, of touchdown == 6 and fieldgoal == 3
> In other words: I don't think it really works.
>
> I'm all for renaming local(), mind you.
So what is your suggestion?
-
raptor wrote:
> What will be the Perl6 code name ?
> even the perl books has some animal to represent the main idea behind... or
> just for the fun.
0gre
ot; It isn't listed in Blackstone's
RFC 19, and it focuses on the restore-later aspects -- put that variable
on hold, like it is a phone call, while you do something else with your
ear.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
I don't watch TV, I have no telephone, and I vote
of one of my RFC's?
:)
He's right, it sure beats pitching code names.
If you're on -meta, David, you might have seen Larry's suggestion.
I don't think he was serious, but:
meanwhile our $foo;
Sounds good to me.
RFC 19 will not be updated.
jdb
Simon Cozens wrote:
>
> I hear there's a mailing list for Linux 2.4.
The mosix people regularly look forward to having their feature set
experimentally included in linux 2.7
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
At
p to the programmer.
According to the Kraaske-Trump theorem, RFC period will never really end.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
Send $25.00 for handy leaflet on how to make money selling leaflets
cho $a:[-20]
> Subscript out of bounds.
> > echo $a:[2-20]
> Subscript out of bounds.
> > echo $a:[1-1]:u$a:[2-].
> This is a string.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"I must report t
Is there a perl6 sort committee yet? AFter reading Cawley's
method here, I wonder if using it we could make radix-sorts the
default sort method.
Original Message
Return-Path: <[EMAIL PROTECTED]>
Delivered-To: [EMAIL PROTECTED]
Received: (qmail 10490 invoked from network); 2
Piers Cawley wrote:
>
> >"David L. Nicol" <[EMAIL PROTECTED]> writes:
> > After reading Cawley's
> > method, I wondered if using it we could make radix-sorts the
> > default sort method.
>
> Er... the point behind changing numbers to binar
list. That's it. Period. Full stop.
Oh.
$ perl -le 'foreach (sort (0..199)){print}' | head
Once again I am a misguided fool.
Thank you for your patience.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
Marc Lehmann wrote:
>
> On Sat, Dec 30, 2000 at 05:31:29AM +0000, "David L. Nicol" <[EMAIL PROTECTED]>
>wrote:
> > I do not know exactly what the perl5 default sort heuristic is, aside that
> > it tries to DWIM both numeric and string data.
>
> Ther
>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**
And $^O =~ /win/i broke recently when Apple introduced Darwin.
(R
> J. David Blackstone wrote:
>> That's one nice thing about Perl; you can foreach over
>> an array of all sorts of different things. In fact, being able to
>> just have an array of all sorts of different things is something Perl
>> still has over Java, C, and t
hat if
time(315532800) #perl-defined to mean secs since 1970 GMT
reset the internal offset to whatever you wanted?
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"gorkulator borked. Please investigate."
recursion.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"gorkulator borked. Please investigate."
"David L. Nicol" wrote:
> We could even define a new line noise variable which could hold the
> results of the last name-of-function subroutine that was not invoked
> as an rvalue (I nominate $__ ); make such an invokation a warning-level
> offense; and make $__ v
let $__ be an alias
> to the return value stack, the place where return() puts its
> args anyway.
That defeats the purpose of optimizing away the assignment from the return stack.
> In fact, shouldn't it be @__ ?
($a, $b, $c) = foo($_);# ref($__ ) is now ARRAY
This new vari
reference;
which makes (wnatarray?@$__:$$__) the alias for the lvalue.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
www.tmcm.com, dammit
=
@$__[1+$i,$i];
};
$t and @$__ = DirectBubbleSort;
}
@SomeList = DirectBubbleSort; # instead of DirectBubbleSort(\@SomeList)
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
www.tmcm.com, dammit
James Mastros wrote:
> > At least it's independent of the sub's name. I wish this could be
> > extended to doing recursive calls without having to say the subs own
> > name, again.
> I agree, making the magic variable be the name of the sub is a bad idea.
>
> Your idea for a name for the current
t readit {...}
seems like it could be very far away from
sub readit {...
and cause some serious AAAD confusion.
Damian?
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
www.tmcm.com, dammit
kjargjbg245098t4lkjng };
Security mechanisms more complex than expected checksums could
be added too -- gpg signatures, for instance
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
www.tmcm.com, dammit
turn these checks on?
use unsafe_string_dereferences
would anyone use it?
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
www.tmcm.com, dammit
> Sorry, I wasn't clear. Let me rephrase. The 'try' helps me determine that
> the following block is going to be subject to exception handlers which will
> immediately follow as siblings of the block. Somewhat as I would look at
> an if...elsif...else construct, it helps me put the block in c
John Porter wrote:
> Note that END{} and BEGIN{} require no formal introduction.
> You can put them anywhere you want, and they run at the proper time.
>
> Even continue{} is an implicit goto. And it requires no introduction
> either.
So if a post{} block could appear anywhere inside a block,
Nicholas Clark wrote:
>
> On Wed, Feb 07, 2001 at 04:30:24PM -0600, David L. Nicol wrote:
>
> > sub has_post_blocks{
> > my $i = 3;
> > post { print "i ended up as $i"};
> > my $arg1 = shif
Nicholas Clark wrote:
> on the other hand, I'll argue the other side that
>
> {
> my $flag
> open FOO, " ...
> }
> post {
> close FOO if $flag;
> }
>
> is clearer because the tidy up doesn't visually get in the way of the flow
> of what you're doing, and you can see what $flag is meant
$_[0]->cheese() or die "FALSE CHEESE"
}
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"I don't care how they do it in New York"
r post processing becomes implied by conversion wrappers.
Am I making sense? I worry I am rushing.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"I don't care how they do it in New York"
Johan Vromans wrote:
> Would the POST be executed if the open fails? Why? Why not?
>
>sub readit {
> POST {
> close F;
> }
> open F, "< $f" or die;
> scalar()
>}
Yes, because the flow of control passed it before the
s laziness, of course.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"I don't care how they do it in New York"
Tony Olekshy wrote:
> If we take this approach then when you just want to casually say
>
> my $f = open $file; always { close $f };
>
> you can. I like that. In addition, when you want to carefully ...
How about "later" instead of "always"
Because: "later" is a time in the future, but
off perl6-*. Take it to clpm or your local NY.pm meeting.
In the latter case, please only do so if schwern is in town and we can
shove you and him into a different room...
dha, 1/2 :-)
--
David H. Adler - <[EMAIL PROTECTED]> - http://www.panix.com/~dha/
You get the idea that if Apple won a
"currying" used in a fascinating context: an experimental
language in which
http://www.eleves.ens.fr:8080/home/madore/programs/unlambda/#tut
everything is a unary function.
Multiple-argument functions are defined in such a way that
the function takes the first argument and returns a functio
Nicol (WEBTV)" wrote:
>
> Sounds like a useful warning, all right.
>
> -Original Message-
> From: David L. Nicol [mailto:[EMAIL PROTECTED]]
> Sent: Friday, March 16, 2001 2:56 PM
> To: John Nicol (WEBTV)
> Subject: A funny thing about e
>
> I wrote a geomet
-- Forwarded message --
Date: Mon, 26 Mar 2001 08:16:24 -0600 (CST)
From: David M. Lloyd <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Cc: Perl 5 Porters <[EMAIL PROTECTED]>
Subject: Re: Distributive -> and indirect slices
On Mon, 26 Mar 2001 [EMAIL PROTECTED] wrote:
>
James Mastros wrote:
> Ahh, bingo. That's what a number of people (inculding me) are suggesting --
> a :functional / :pure / :stateless / :somthingelseIdontrecall attribute
> attachable to a sub.
:memoizable
:clean
:nosideeffects
Dan Sugalski wrote:
>
> At 02:52 PM 3/29/2001 -0800, Russ Allbery wrote:
> >James Mastros <[EMAIL PROTECTED]> writes:
> >
> > > Ahh, bingo. That's what a number of people (inculding me) are
> > > suggesting -- a :functional / :pure / :stateless /
> > > :somthingelseIdontrecall attribute attachab
On Thu, 12 Apr 2001, Dave Storrs wrote:
> On Mon, 9 Apr 2001, Peter Scott wrote:
>
> > At 09:36 AM 4/9/01 +0200, Ariel Scolnicov wrote:
> > >
> > >One liners are supposed to be SHORT. `--cmd' is LONG. If we MUST go
> > >the multiflagged way, why not reflect `-e' to get the `-6' flag? At
> > >
On Sun, 15 Apr 2001, David Grove wrote:
> The Perl 5 path is almost dead: adventurers and Win32 users are the
> vast majority using it at all.
Since when?
> Add Solaris 8 1/01 to the list of OS's that have completely rejected
> 5.6, as I discovered last night, and I'd
stantly dismissing it. Or insist that language
extensions must maintain curlie balance. It's really a
very minor demand, esp. since there is method 1
(inline-style operation on a quoted literal string ) to
fall back on.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
Home of the V-90 modern
st an absolute kind of thing rather than
a stacked kind of thing, with the later parser responsible for
switching back.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
"Described as awesome by users"
Larry Wall wrote:
>
> David L. Nicol writes:
> :
> : [this parser switch thing]
> : sounds a lot like an "exec" system call: there are some things
> : which remain in effect (open file handles, current directory,
> : environment) but there are many others whi
Brent Dax wrote:
Yes, that is exactly what I had in mind, thanks for
the validation. Only the comment syntax would have to
come back to a designated module, with another hashbang.
#!comment
yadda yadda yadda
blah blah blah
foo bar baz
#!VB6
f
On 24 Apr 2001, Russ Allbery wrote:
> Branden <[EMAIL PROTECTED]> writes:
>
> > 1) Use $obj.method instead of $obj->method :
>
> > The big question is: why fix what is not broken? Why introduce Javaisms
> > and VBisms to our pretty C/C++-oid Perl? Why brake compatibility with
> > Perl 5 code (a
On 24 Apr 2001, Russ Allbery wrote:
> David M Lloyd <[EMAIL PROTECTED]> writes:
>
> > What's wrong with using both? You could use -> if you're working with a
> > reference to an object, and you could use . if you're working with the
> > object
On Tue, 24 Apr 2001, Simon Cozens wrote:
> On Tue, Apr 24, 2001 at 08:38:58AM -0500, David M. Lloyd wrote:
> > Well, right now in Perl, an object *is* a reference.
>
> No. An object is a referent. Two blessed references can refer to the
> same data; however, that's
Dan Sugalski wrote:
> Most of the parser switching is going to be of the nesting variety. Every
> time the parser processes a double-quoted string constant or a regular
> expression you're going to be jumping parsers. That's all temporary, and we
> really do want them to nest. (You really don't w
Larry Wall wrote:
> (And juxtaposition is out because we're not going to destroy indirect
> object syntax
How often is indirect object syntax used without some whitespace? Having
the perl5->perl6 converter locate it and insert a space shouldn't be too
very tricky.
$these=$this$that$the_
e "indirect object syntax"
which this allegedly steps on?
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
Henrik's keyboard has nice letters like 'æ', 'ø' and 'å'
inate
> there? Also, consider this...
they forgot a semicolon. A spaceless juxtaposed concat would look like
print "Foo"foo("bar");
and we insist that indirect objects have a space in them. And introduce
"" "" for when you absolutely positi
John Porter wrote:
> We could y/$@%/@%$/ ...
... and create an alternate parser able to handle the full
internal internals API.
I have finally figured out the main motivation behind the
whole perl6 effort: the obfuscated perl contests were
getting repetitive.
Good night.
ve.com/perl6-all%40perl.org/msg01043.html
Oh, last august, we discussed all this
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
and they all say "yodelahihu"
801 - 900 of 1041 matches
Mail list logo