ions? The 'dis' being a form of negative and all.
I found this in E06:
if %person{title} ne $known_title { ... }
Well... I guess E06 is unmaintained, but currently has the best
explanation of junctions I can find, so I offer the attached patch in
the hope that the logic error does not
an array" paradigm which breaks the weld?
@a = 1..*;
@a[-1] = 9; # @a = (9) now ?
That's just my thoughts from what I understand and sorry if introducing
welding into the analogy causes bits of molten metal to go flying
around ;-)
--Eric
--
"You can't win. You can't break even. You can't quit."
--Ginsberg's Restatement of the Three Laws of Thermodynamics
---
http://scratchcomputing.com
---
_function,
&RefugeeWindowsProgrammer, &Let_There_Be_Poetry, &MAGIC,
&UNAUTHORIZED_USER_MAGIC.
And, just like $scalars can hold arrays, &somesub could be a standard
function or a user function (or a standard function which a user
reimplemented -- you never know).
- Ashley Winters
--
--
__
Eric Hodges
Of course that might not realy make
since for given/when and its smart matching magic. But then maybe we
just don't want to be able to say "when $a == $b" and thats just
invalid since it would be clearer written as an if.
--
--
__
Eric Hodges
/restore instruction is passed on to the mutatee to
> save itself before the mutation, not after.)
>
> The p5-to-p6 translator will turn
>
> local $x;
>
> into
>
> temp undefine $x;
>
> Larry
>
In order not do do some strange magic could you jsut do:
temp($x)++;
That seems clear and non magical to me.
Just my 2 cents! ;)
--
--
__
Eric Hodges
>
> I think 'subset' might be a nicer colour for this bikeshed. For an
> extra three characters you lose the confusion with "to set", and it
> highlights the fact that you're (usually) declaring a *constrained*
> subset of the original type.
>
>
> Stuart
>
Ehh. By that definition arn't all sets s
I'm pretty sure i've heard this discussed but checking S04/Switch
Statments doesn't make any mention of it. If it has been settled
could we get some doc updates?
--
--
__
Eric Hodges
T then it might overlap (collide) with a real class named T.
In the following case it is not clear wether Dog is defined in the
signature, or a realy seperate class.
sub test (class Dog $x) {
my Dog $y = $x + 5;
}
The same example with ^ becomes much clearer to me.
sub test (^Dog $x) {
my ^Dog $y = $x + 5;
}
The ^ clearly states the meaning while bareword Dog and 'class Dog'
would both cause conflicts in my head.
Just my reasoning about it all.
BTW didn't you contradict your own real world usage of type1^type2 ?
Even if we use ^ as a sigil why would it get confused on that? I
don't think type1 ^type2 could have any realy meaning so it should be
easy for the parser to know the difference.
--
--
__
Eric Hodges
What about something like:
c\
Then you get
sub sametype (c\T $x, c\T $y) {...}
Not exactly pretty though. c\T
Actualy i think ^ might be my favorite so far.
sub sametype (^T $x, ^T $y) {...}
--
Eric
ught i might bring it up since this seems
different than the magical ness of pairs before.
--
--
__
Eric Hodges
I have a suggestion/proposal/whatever.
I am just starting to get a grasp of uses for pairs and where they are
handy. Working on string.trans some showed that it would be useful to have
the function accept a list of pairs. That was working until the fix for
magical pairs went through and now the pa
e.
> Free the Memes.
>
Actually its been fixed already. Of course i think the whole thing was then
broken again, i was planning on checking it out sometime tonight after
someone else figures out the current $?SELF being undeclared bug. ;) BTW it
doesn't need any hash i just needed pairs which it had for about an hour
before things changed again. lol. so is development on pugs I guess, here
today, gone tomorrow, back again another day.
--
--
__
Eric Hodges
n provide a
good code use of it and it doesn't add any data that wasn't there before. I
don't think it should ever lean towards (b) but them I bet someone else will
have an equaly good use of that. ;) So in the end I think some way of
chooseing would be good, with one option picked as standard.
--
Eric Hodges
ue. A good alternative is hard to find, though. I tend
> to prefer 1 at this moment (coincidentally, that's +?$pair).
>
>
> Juerd
> --
> http://convolution.nl/maak_juerd_blij.html
> http://convolution.nl/make_juerd_happy.html
> http://convolution.nl/gajigu_juerd_n.html
>
--
__
Eric Hodges
give the
> variable a different name than the parameter. I like.
>
> sub seek (:x($horizontal),:y($vertical))
>
> On the other hand, it's now unclear whether you can call that as
> seek(1,2).
> Needs to be allowed somehow.
>
> Larry
>
--
__
Eric Hodges
internal classes
because every added class could possibly compromise existing code.
Well that is my 2 cents and my first post here so please forgive anything
that apears rude or stupid and guide me on how to improve future posts.
Thanks,
__
Eric Hodges
s of topicality--now that we changed the
> rule so that $_ is always aliased to the topic regardless of whether
> it's aliased to an explicit variable name.
>
> Larry
This seems to argue against OUTER::
--
math weenie, but I would thing gamma(x) would be of use.
Also perhaps a div2(n,m): given two ints, returns two ints, n/m and n%m.
--
Eric J. Roode[EMAIL PROTECTED]
Senior Software Engineer, Myxa Corporation
nal classes" prevent such a travesty? Are you
seriously suggesting that the Array class should be designed such
that it cannot be inherited?
--
Eric J. Roode[EMAIL PROTECTED]
Senior Software Engineer, Myxa Corporation
people DO create closures by
mistake, and it can be a very difficult bug to trace if you aren't
used to closures.
--
Eric J. Roode[EMAIL PROTECTED]
Senior Software Engineer, Myxa Corporation
David L. Nicol wrote:
>
>Are there really situations where
>
> $$reference = An Expression;
>
>is clearer than
>
> $reference = \(An Expression);
>
>?
Eric is confused. I don't know about in Perl 6-to-be, but in Perl 5
those two mean totally
# Return the iterator as a closure wrt the above variables.
return sub
{
my $i = $index++;
return () if $i >= $max_num; # No more elements to return
return map $_->[$i], @arr_list; # Return ith
@bar)
is very easy to code in perl 5. At the risk of sounding reactionary,
this doesn't seem like a Big Win for perl.
------
Eric J. Roode[EMAIL PROTECTED]
Senior Software Engineer, Myxa Corporation
$baz = Sfoo || |bar;
And references are right out.
;-)
--
Eric J. Roode[EMAIL PROTECTED]
Senior Software Engineer, Myxa Corporation
In a fit of insanity, at 10:14 EDT Tue May 8, I wrote:
>
>9 times out of 100, qw saves a large number of keystrokes. (The
>other 1% of the time, ...
I hope it's obvious that I meant "99 times out of 100"
--
roken".
Personally, I don't understand how using two alphabetic characters
and a pair of delimiters, in order to save typing a whole mess of
quotes and backslashes, can be construed as "ugly". :-)
And, while I'm on my soapbox here, I don't ge
lexible syntax can be infinitely
difficult to decipher.
Thanks.
--
Eric J. Roode[EMAIL PROTECTED]
Senior Software Engineer, Myxa Corporation
you could
use to just the One Standard Style?
--
Eric J. Roode[EMAIL PROTECTED]
Senior Software Engineer, Myxa Corporation
ave
seen written out so far for the shift from -> to . and . to is: it looks more like other languages. That seems like a whole
lot of fixing of non-broken syntax.
--
Eric J. Roode[EMAIL PROTECTED]
Senior Software Engineer, Myxa Corporation
ascript is.
My two cents. Thanks for listening.
--
Eric J. Roode[EMAIL PROTECTED]
Senior Software Engineer, Myxa Corporation
bly uninitialized" warning, right?
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh', 'ekca', 'lre',
Myxa Corporation'.r', 'h ', 'uj', 'p ', 'ts';
my ($a, $b, $c);
initialize_to_seven ($a, $b, $c);
print "$a, $b, $c\n";
------
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Enginee
Glenn Linderman wrote:
>Eric Roode wrote:
>
>> 1. You don't say in your RFC, but I'm guessing, that a null value
>> evaluates to false in a boolean context. Correct?
>
>I would expect it to be considered false. Logical expressions involving
>NULL are defined
ndefined value in line 7 (run time)
How about:
foo();
$x = 1 unless defined($x);
print $x;
Generate a warning, or not?
Or:
foo();
print $x;
Generate a warning, or not? Which one? Remember, foo() may initialize $x.
-
first.
Would the use of a null value in a string generate a warning, as
an undef value does now?
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh', 'ekca', 'lre',
Myxa Corporation'.r', 'h ', 'uj', 'p ', 'ts';
ypes'",
it would be a compile-time error. If so, please add this suggestion
to the RFC. If not, should I make a separate RFC?
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh', 'ekca', 'lre',
Myxa Corporation'.r', 'h ', 'uj', 'p ', 'ts';
CHUNK2
$chunk3 = <
CHUNK3
The here-doc terminators all line up with the perl code.
The generated program is nicely indented relative to the left margin.
--
Eric J. Roode, [EMAIL PROTECTED
;, say <<<, rather than chucking the whole idea
out the window.
------
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh',
for you to trip over or hang yourself.
I set my tab stops to four columns; at least one of my coworkers
sets his tab stops to eight columns. We edit the same code with no
problems.
--
Eric J. Roode, [EMAIL PROTECTED]
uot;oops! I added a bracket. gotta change the quoting character!").
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh', 'ekca', 'lre',
Myxa Corporation'.r', 'h ', 'uj', 'p ', 'ts';
at is the point of
sub func1
{
func2();
}
sub func2
{
last func1;
}
? Imho, it is a BAD THING for functions to know who called them,
and to vary their behavior accordingly.
--
Eric J. Roode,
side of the screen. I prefer four columns.
No problem -- I make my tab settings four columns. Which, for purposes
of here docs and this proposal, works just as well.
The REAL sinners are those who mix spaces and tabs. THAT's evil. :-)
---
Glenn Linderman wrote:
>Amen to the below. So can we have an RFC 111 (v4) that gets rid of allowing
>stuff after the terminator? Even the ";" afterward seems useless... the ";"
>should be at the end of the statement, not the end of the here doc. The only
>improvement to here docs I see in this
el string.
This would HAVE to be a very optional feature. I rely on undef
converting to a null string in many, many programs.
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Enginee
x27;s one-line if/for/while syntax as a matter of
convenience, but I grudgingly admit that Perl's way more than
makes up in unambiguity what it loses in convenience.
--
Eric J. Roode, [EMAIL PROTECTED] print scala
as set representations
and you have not made a good case yet. Your least-bad argument has
been that arrays "make more sense to you" than hashes. Does execution
time mean nothing to you?
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh', 'ekca', 'lre',
Myxa Corporation'.r', 'h ', 'uj', 'p ', 'ts';
Ariel Scolnicov wrote:
>Eric Roode <[EMAIL PROTECTED]> writes:
>
>[...]
>
>> The underlying problem is that arrays don't make SENSE as an
>> implementation for sets. What is the value of:
>
>But all of the following DO make sense as implementations
mall set of people,
and fairly useless to the majority of Perl programmers. That screams
"module" to me, not "new core features".
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh', 'ekca', 'lre',
Myxa Corporation'.r', 'h ', 'uj', 'p ', 'ts';
uld pass if the last expression
in the block evaluates to true, just as grep does now:
@l = grep {$_>9} @L; # same as:
@l = grep {pass if $_>9}; #--> (10)
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh', 'ekca', 'lre',
Myxa Corporation'.r', 'h ', 'uj', 'p ', 'ts';
Richard Proctor wrote:
>>[Eric Roode wrote]
>> Perhaps $/ and $\ should become per-filehandle variables, and
>> there should be some way to set autochomp-on-read per filehandle,
>> and auto-newline-on-output per filehandle.
>
>I can see a small benefit for autocho
remove $/ from the end of a string
at any other time, they can s,$/$,,
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh',
but maybe it should be a
primitive.
I dunno. I don't use set functions, so I'd never use it, personally.
But I'm sure many set mathematicians out there would.
------
Eric J. Roode, [EMAIL PROTECTED] pri
-- most of it quite simple
and short -- for implementing union, intersection, complement,
etc, with hashes and with bit vectors.
Also, as TomC recommended, do check out the existing modules
on CPAN.
--
Eric J. Roode, [EMAI
dead-fish
way to do s|$/$||, with some extra magic thrown in for when $/ is null.
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh&
if /^barf/;
last if /!!$/;
print LOG "$_ found\n";
}
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh', 'ekca', 'lre',
Myxa Corporation'.r', 'h ', 'uj', 'p ', 'ts';
via the
>
> use String::Chop;
>
>or related module.
Useful functions all, no doubt. But I would lobby heavily for a new
set of names -- ones that can be remembered! Quick -- which trims
leading spaces, champ, chump, or chimp?
---
in it
> }
Although... if you're going to generalize it this way, why not call
them LEFT$ and RIGHT$, and rename substr() to MID$? Ugh...
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sor
people, I'd think.
use precision; # maybe?
Disclaimer: I failed limit-of-error analysis in college :-)
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh', 'ekca', 'lre',
Myxa Corporation'.r', 'h ', 'uj', 'p ', 'ts';
the "for" statement, and I haven't seen one yet that had
seemed justified to me.
--
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh', 'ekca', 'lre',
Myxa Corporation'.r', 'h ', 'uj', 'p ', 'ts';
ist, 0, 3) ) {...}
? (notwithstanding the destructive nature of splice)
------
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 'reh',
over
@hash{ grep /^[^_]/, keys %hash }
would be what? Brevity?
------
Eric J. Roode, [EMAIL PROTECTED] print scalar reverse sort
Senior Software Engineer'tona ', 're
Steve Simmons wrote:
>In all the straining at gnats over whitespace, filtering, etc, I have yet
>to see a single proposal that isn't accomplished by just using variables
>and manipulating them appropriately. And it avoids all the problems with
>whitespace on the HERE word.
In many cases, I agree
Richard Proctor proposed:
>
> All of these should work:
>
> print print << EOL;
> EOL
> print
At our company, we pronounce "www" as "dub-dub-dub". The first
syllable of the letter "w", three times.
Very easy to say quickly. "dub-dub-dub-dot-perl-dot-com". Try it.
--
Eric J. R
64 matches
Mail list logo