This is a very old ticket and we no longer have postcircumfix:<( )>
for objects.
If you redo the example to use CALL-ME it still does not call the
original class method, however, CALL-ME is defined as a submethod,
not a method, and testing the difference:
$ perl6 -e 'class S { method x { "Sx".sa
RT#125027 [new]:
https://rt.perl.org/Ticket/Display.html?id=125027 [REGEX] Roast rakudo
skip/todo test:./S05-modifier/perl5_9.t line:35 reason: 'Quantifier quantifies
nothing'
< bisectable6> bartolin, bisect log:
https://gist.github.com/996a9c0aeea60fd1061784bc71ceefbd
< bisectable6&g
; OR
> 0
> 3
> 2
> 1
> 5
> 8
> 7
> 4
> 6
> 9
> OR etc.
>
> So not only it is out of order (#127099), but it is also extremely broken.
>
> It looks like there is no such problem with 「race」.
>
> IRC log (nothing useful there though):
> http://irclog
; OR
> 0
> 3
> 2
> 1
> 5
> 8
> 7
> 4
> 6
> 9
> OR etc.
>
> So not only it is out of order (#127099), but it is also extremely broken.
>
> It looks like there is no such problem with 「race」.
>
> IRC log (nothing useful there though):
> http://irclog
On Tue, 08 Aug 2017 18:40:48 -0700, alex.jakime...@gmail.com wrote:
> Code:
> for .hyper { say 2 }
>
> Result (2015.09-2015.06):
> 2
> 2
> 2
>
> Result (9b0b9effe5,2017.07,HEAD(6745517)):
> (no output)
>
>
> There seems to be nothing wrong with using
On Tue, 08 Aug 2017 18:40:48 -0700, alex.jakime...@gmail.com wrote:
> Code:
> for .hyper { say 2 }
>
> Result (2015.09-2015.06):
> 2
> 2
> 2
>
> Result (9b0b9effe5,2017.07,HEAD(6745517)):
> (no output)
>
>
> There seems to be nothing wrong with using
On Mon, 20 Oct 2014 09:00:24 -0700, j...@johnkingsley.ca wrote:
> Hi,
>
> When I define a gist() method, it doesn't get called when I expected
> it to be called.
>
> This occurs when you call gist() not on the object directly, but
> instead
> on another object which uses the class where the gist(
On Mon, 20 Oct 2014 09:00:24 -0700, j...@johnkingsley.ca wrote:
> Hi,
>
> When I define a gist() method, it doesn't get called when I expected
> it to be called.
>
> This occurs when you call gist() not on the object directly, but
> instead
> on another object which uses the class where the gist(
, but this will leave us without a good
list of tests that should be written.
On 2017-08-08 18:40:48, alex.jakime...@gmail.com wrote:
> Code:
> for .hyper { say 2 }
>
> Result (2015.09-2015.06):
> 2
> 2
> 2
>
> Result (9b0b9effe5,2017.07,HEAD(6745517)):
> (no output)
&
ult (9b0b9effe5,2017.07,HEAD(6745517)):
(no output)
There seems to be nothing wrong with using a for loop on .hyper or .race, so it
should work. It starts working if you somehow use the value, for example:
Code:
do for .hyper { say 2 }
Result (9b0b9effe5,2017.07,HEAD(6745517)):
2
2
2
Bisecta
ut it is also extremely broken.
It looks like there is no such problem with 「race」.
IRC log (nothing useful there though):
http://irclog.perlgeek.de/perl6/2016-02-02#i_11975794
ck at -e line 1
Actually thrown at:
(“Actually thrown at:” shows nothing)
Related bug: https://rt.perl.org/Public/Bug/Display.html?id=127424
Perhaps there is a way to make sure this does not happen (not just in this
particular case)?
us dispatch to multi 'foo'.
> Ambiguous candidates had signatures::():(Int $a?):(Str $a?) [...]
> any reason one shouldn't count the lack of an argument as
> narrower there too?
> it would be a nice way to resolve the ensuing ambiguity
> between :(Int $a?) and :(Str $a?)
&
In C culture, a bare return means "This is a procedure, not a function, and I'm
not expecting to return anything", and so I think the absence of a meaningful
value is properly conveyed by Nil in Perl 6. If the intent of a return is to
allow interpolation of Slip or (), then that choice should b
# New Ticket Created by Steve Schulze
# Please include the string: [perl #126049]
# in the subject line of all future correspondence about this issue.
# https://rt.perl.org/Ticket/Display.html?id=126049 >
Post GLR, implicitly returning nothing from a subroutine now returns an
em
I added a simple test (only testing whether bare "await" dies, no check for the
error message) to S17-promise/basic.t with commit
https://github.com/perl6/roast/commit/305ca31ff7
I'm closing this ticket as 'resolved'.
That is correct. At the moment we cannot catch this elegantly at compile time,
because the candidate with the slurpy takes the no arg case as well. So the
only way to catch the no arg case, is to create a candidate for it that dies.
Which makes it runtime.
Since await, from the grammar point
It does not say "===SORRY!===", is it OK?
On Thu, May 28, 2015 at 7:09 PM, Elizabeth Mattijsen via RT <
perl6-bugs-follo...@perl.org> wrote:
> A bare await now throws an error (with d841d4e14f04c49a19c32)
>
> $ 6 'await'
> Must specify a Promise or Channel to await on
> in block at -e:1
>
> Li
quot;"await" without args does nothing but produces no error",
> a summary of which appears below.
>
> There is no need to reply to this message right now. Your ticket has been
> assigned an ID of [perl #125257].
>
> Please include the string:
>
>
A bare await now throws an error (with d841d4e14f04c49a19c32)
$ 6 'await'
Must specify a Promise or Channel to await on
in block at -e:1
Liz
> On 27 May 2015, at 15:52, Alex Jakimenko (via RT)
> wrote:
>
> # New Ticket Created by Alex Jakimenko
> # Please include the string: [perl #1252
# New Ticket Created by Alex Jakimenko
# Please include the string: [perl #125257]
# in the subject line of all future correspondence about this issue.
# https://rt.perl.org/Ticket/Display.html?id=125257 >
Somehow I expected that "await" without args would wait for everything, but
it does not
# New Ticket Created by Tobias Leich
# Please include the string: [perl #125138]
# in the subject line of all future correspondence about this issue.
# https://rt.perl.org/Ticket/Display.html?id=125138 >
say EnumMap.new.perl.EVAL
rakudo-moar 9c543b: OUTPUT«Odd number of elements found where h
On Sun Oct 05 14:20:32 2014, barto...@gmx.de wrote:
> The error message with nom is now "Quantifier quantifies nothing":
>
> > / * /
> ===SORRY!=== Error while compiling
> Quantifier quantifies nothing
> at :1
> --> / *⏏ /
> expecting any of:
>
Status update: STD gives an adequate error message now:
$ viv -c -e '/ : /'
===SORRY!===
Backtrack control ':' does not seem to have a preceding atom to control at
(eval) line 1:
--> / :⏏ /
Parse failed
Rakudo's complaint has changed but is still LTA:
$ perl6-m -e '/ : /'
===SORRY!===
Unrec
# New Ticket Created by John Kingsley
# Please include the string: [perl #123016]
# in the subject line of all future correspondence about this issue.
# https://rt.perl.org/Ticket/Display.html?id=123016 >
Hi,
When I define a gist() method, it doesn't get called when I expected it to be
call
The error message with nom is now "Quantifier quantifies nothing":
> / * /
===SORRY!=== Error while compiling
Quantifier quantifies nothing
at :1
--> / *⏏ /
expecting any of:
statement list
prefix or term
prefix or meta-prefix
> / a+ + /
===SO
# New Ticket Created by "Carl Mäsak"
# Please include the string: [perl #122109]
# in the subject line of all future correspondence about this issue.
# https://rt.perl.org/Ticket/Display.html?id=122109 >
r: class Conf { has @.boxes where { all(@$_) >= 0 } }; my $c =
Conf.new(:boxes[ 2, 2, -1
-glossary.pod
Log Message:
---
[S99] associativity's got nothing to do with it :)
Commit: 793babac4bf1316f787b2a08403bb7b1ca6b072c
https://github.com/perl6/specs/commit/793babac4bf1316f787b2a08403bb7b1ca6b072c
Author: Carl Masak
Date: 2013-07-01 (Mon, 01 Jul
# New Ticket Created by "Carl Mäsak"
# Please include the string: [perl #117931]
# in the subject line of all future correspondence about this issue.
# https://rt.perl.org:443/rt3/Ticket/Display.html?id=117931 >
<[Coke]> hurm. this line: $text ~~ /^( +)/; -- dies with Method
'rxtype' no
# New Ticket Created by "Carl Mäsak"
# Please include the string: [perl #117377]
# in the subject line of all future correspondence about this issue.
# https://rt.perl.org:443/rt3/Ticket/Display.html?id=117377 >
callsame from method in a role will call the original method
from the class, won
my $foo = '*'; say "q*" ~~ / q <$foo> /
> niecza v15-5-g1252cdb: OUTPUT«Unhandled exception: Quantifier
> quantifies nothing [...]
> I prefer Niecza's error to Rakudo's.
> r: say '' ~~ / * /
> rakudo a4c78f: OUTPUT«===SORRY!===Method '
~~ / q <$foo> /
rakudo a4c78f: OUTPUT«===SORRY!===Method 'rxtype' not found
for invocant of class 'Integer'»
innerestin'.
n: my $foo = '*'; say "q*" ~~ / q <$foo> /
niecza v15-5-g1252cdb: OUTPUT«Unhandled exception: Quantifier
quantifie
# New Ticket Created by "Carl Mäsak"
# Please include the string: [perl #83420]
# in the subject line of all future correspondence about this issue.
# http://rt.perl.org/rt3/Ticket/Display.html?id=83420 >
rakudo: (say "OH HAI" if $_ > 4 for 1, 2, 3) or say "empty!"
rakudo 924242: OUTPUT«emp
masak (>):
> rakudo: my $a = "fool!"; $a ~~ / (foo) /; say $0
> rakudo 9b6189: OUTPUT«foo»
> rakudo: my $a = "fool!"; $a !~~ / (foo) /; say $0
> rakudo 9b6189: OUTPUT«Any()»
> * masak submits rakudobug
rakudo: my $a = "fool!"; $a ~~ / (foo) /; say $0
rakudo 5f5bae: OUTPUT«foo»
rakudo: my
# New Ticket Created by "Carl Mäsak"
# Please include the string: [perl #77786]
# in the subject line of all future correspondence about this issue.
# http://rt.perl.org/rt3/Ticket/Display.html?id=77786 >
rakudo: / : /
rakudo ce565f: OUTPUT«===SORRY!===Method 'backtrack' not
found for invo
# New Ticket Created by "Carl Mäsak"
# Please include the string: [perl #76892]
# in the subject line of all future correspondence about this issue.
# http://rt.perl.org/rt3/Ticket/Display.html?id=76892 >
rakudo: my $a = "fool!"; $a ~~ / (foo) /; say $0
rakudo 9b6189: OUTPUT«foo»
rakudo:
On Tue Jan 20 12:58:20 2009, eric256 wrote:
> use v6;
>
> rule test {test};
>
> "test" ~~ //;
> say '$/.keys => ', $/.keys.perl;
> say '%($/).keys => ', %($/).keys.perl;
>
> # outputs
> # $/.keys => []
> # %($/).keys => ["test"]
>
>
> Same could be said for .values and .kv
>
> It would be ver
k of an argument as
narrower there too?
it would be a nice way to resolve the ensuing ambiguity
between :(Int $a?) and :(Str $a?)
masak: a definite nothing is narrower than a possible Int
or Str, i agree
* masak submits rakudobug
might need a bit of spec too, maybe.
# New Ticket Created by "Carl Mäsak"
# Please include the string: [perl #74056]
# in the subject line of all future correspondence about this issue.
# http://rt.perl.org/rt3/Ticket/Display.html?id=74056 >
rakudo: my @a=; say ?...@a.grep("all")
rakudo 02cf9c: OUTPUT«1»
mberends: did you su
# New Ticket Created by "Carl Mäsak"
# Please include the string: [perl #69310]
# in the subject line of all future correspondence about this issue.
# http://rt.perl.org/rt3/Ticket/Display.html?id=69310 >
rakudo: say 1/0; say "Alive"; say (1/0).Num
rakudo 0eaf62: OUTPUT«AliveDivide by zero
akudo e989e6: OUTPUT«FixedIntegerArray: index out of bounds! [...]
rakudo: my $code = -> $a? { "Foo" }; my %h = :bar; $code(|%h);
rakudo e989e6: OUTPUT«FixedIntegerArray: index out of bounds! [...]
*there*
it's when there's an optional param
optional param + named flat wi
Moritz Lenz wrote:
> Since afaict this is not specced, I'll hand that over to p6l.
>
> Eric Hodges (via RT) wrote:
>> use v6;
>>
>> rule test {test};
>>
>> "test" ~~ //;
>> say '$/.keys => ', $/.keys.perl;
>> say '%($/).keys => ', %($/).keys.perl;
>>
>> # outputs
>> # $/.keys => []
>> # %($/).keys
Since afaict this is not specced, I'll hand that over to p6l.
Eric Hodges (via RT) wrote:
> use v6;
>
> rule test {test};
>
> "test" ~~ //;
> say '$/.keys => ', $/.keys.perl;
> say '%($/).keys => ', %($/).keys.perl;
>
> # outputs
> # $/.keys => []
> # %($/).keys => ["test"]
>
>
> Same could be
# New Ticket Created by "Eric Hodges"
# Please include the string: [perl #62528]
# in the subject line of all future correspondence about this issue.
# http://rt.perl.org/rt3/Ticket/Display.html?id=62528 >
use v6;
rule test {test};
"test" ~~ //;
say '$/.keys => ', $/.keys.perl;
say '%($/).k
Larry (>), Carl (>:):
> : Here's a 1-line patch that fixes nothing, pmichaud++.
>
> Note that nothing is now unspecced. :)
Are you suggesting that nothing may be replaced in the future?
// Carl
On Fri, Jul 18, 2008 at 05:53:17PM +0200, Carl Mäsak wrote:
: Here's a 1-line patch that fixes nothing, pmichaud++.
Note that nothing is now unspecced. :)
Larry
# New Ticket Created by "Carl Mäsak"
# Please include the string: [perl #57076]
# in the subject line of all future correspondence about this issue.
# http://rt.perl.org/rt3/Ticket/Display.html?id=57076 >
Even though the keyword nothing is implemented in rakudo, the fo
Here's a 1-line patch that fixes nothing, pmichaud++.
make_nothing_0ary.patch
Description: Binary data
On Thu, Sep 29, 2005 at 11:21:20PM -0600, Luke Palmer wrote:
[ discussion on undefs elided ]
Since we can annotate our undefs now, perhaps undefs that would be
generated because there are no previous or next elements get "tagged"
as such. Something like:
# assuming $b and $a are "before"
def" in most code is
considered bad style--then we can steal them for the language's
purposes, such as passing to a for block as lookbehind and lookahead
parameters when you're near the beginning or end of a list.
It seems like I'm making a pretty big deal out of just passing undef
w
Juerd wrote:
Austin Hastings skribis 2005-03-21 15:55 (-0500):
I'd like to see nothing as just an alias for {}.
if $expr
{
do nothing;
}
Possibly the most clear piece of P6 code ever.
Dangerous, though :)
do nothing if $input =~ /\W/;
system "rm -- $input";
Bu
Austin Hastings skribis 2005-03-21 15:55 (-0500):
> I'd like to see nothing as just an alias for {}.
> if $expr
> {
>do nothing;
> }
> Possibly the most clear piece of P6 code ever.
Dangerous, though :)
do nothing if $input =~ /\W/;
system "rm -- $input
Juerd wrote:
Rod Adams skribis 2005-03-21 14:25 (-0600):
if $expr {
nothing;
}
is harder to get confused over, IMO
Except writing something when you mean nothing is kind of weird. It
makes sense in rules because it doesn't usually make sense to match
nothingness, but for blocks
Rod Adams skribis 2005-03-21 14:25 (-0600):
> if $expr {
> nothing;
> }
> is harder to get confused over, IMO
Except writing something when you mean nothing is kind of weird. It
makes sense in rules because it doesn't usually make sense to match
nothingness, but for bl
Larry Wall wrote:
On Sun, Mar 20, 2005 at 09:08:08PM -0600, Rod Adams wrote:
: I propose creating a no-op function "nothing" that can be used
: here or anywhere else you specifically wish to do nothing at all.
:
: given $this {
:when Even { nothing };
:when Prime { ... };
:
the value in a void context, and we could suppress that warning for
0 and 1 like we do Perl 5 without violating our "no barewords" dictum.
: I propose creating a no-op function "nothing" that can be used
: here or anywhere else you specifically wish to do nothing at all.
:
:
Does Perl need a no-op function?
With the addition of "no bare literals", it makes constructs like
1 while some_func();
an error. I propose creating a no-op function "nothing" that can be used
here or anywhere else you specifically wish to do nothing at all.
given
Joe Gottman writes:
> How do you declare a function that doesn't return anything? For instance, a
> C++ swap function might be declared
>template
> void swap(X &x, X &y);
>
> It would be nice to declare the corresponding Perl6 function as
> sub swap ($
How do you declare a function that doesn't return anything? For instance, a
C++ swap function might be declared
template
void swap(X &x, X &y);
It would be nice to declare the corresponding Perl6 function as
sub swap ($x is rw, $y is rw) returns nothing {...}
or something s
--- Larry Wall <[EMAIL PROTECTED]> wrote:
> On Mon, Sep 08, 2003 at 11:18:12AM +0200, Paul Johnson wrote:
> : By the way, I trust this will be addressed (if it hasn't been
> : already):
> :
> : perl5 -le 'print "gah!" if exists $a{b}{c}; print "phooey!"
> : if exists $a{b}'
> :
> : perlfunc say
On Mon, Sep 08, 2003 at 11:18:12AM +0200, Paul Johnson wrote:
: By the way, I trust this will be addressed (if it hasn't been already):
:
: perl5 -le 'print "gah!" if exists $a{b}{c}; print "phooey!" if exists $a{b}'
:
: perlfunc says:
:
: This surprising autovivification in what does not at f
Jonadab the Unsightly One said:
> $s = %h{foo} = nonex;
>
> After deleting the foo key (and its value, if any) from %h this then
> probably procedes to autovivify it when evaluating it as an rvalue;
Now why on earth would you want to do that? Perl 5 doesn't.
By the way, I trust this will be
Luke Palmer <[EMAIL PROTECTED]> writes:
> A synonym of:
>
> delete %h{foo};
>
> would be
>
> %h{foo} = nonex;
This has the potential, if not documented exactly right, to create
bogus expectations. Consider...
$s = %h{foo} = nonex;
After deleting the foo key (and its value, if any)
efined in C<&part>
> > > originally, i.e. C<< <> >>.
> > >
> > > What if one wanted to curry in whatever the default is, i.e., assuming
> > > "nothing" (different from "assuming nothing"), so that if List::Part::part
<> >>.
> >
> > What if one wanted to curry in whatever the default is, i.e., assuming
> > "nothing" (different from "assuming nothing"), so that if List::Part::part
> > changed its default for C to C<< <> >>, the client
> >
Trey asked:
To take the E6 example of currying &part:
&List::Part::part.assuming(labels => <>)
One had to curry in C to be the same as it was defined in C<&part>
originally, i.e. C<< <> >>.
What if one wanted to curry in whatever the default
:
> In a message dated Thu, 31 Jul 2003, Austin Hastings writes:
> > assuming(labels => undef)
>
> Okay... I think you're wrong, because this would have to be a special
> case
> (defaults take effect only when *nothing* is passed in, not when the
> argument is un
In a message dated Thu, 31 Jul 2003, Austin Hastings writes:
> assuming(labels => undef)
Okay... I think you're wrong, because this would have to be a special case
(defaults take effect only when *nothing* is passed in, not when the
argument is undefined) but, assuming you're ri
;> >>.
>
> What if one wanted to curry in whatever the default is, i.e.,
> assuming
> "nothing" (different from "assuming nothing"), so that if
> List::Part::part
> changed its default for C to C<< <> >>, the
> client
> c
To take the E6 example of currying &part:
&List::Part::part.assuming(labels => <>)
One had to curry in C to be the same as it was defined in C<&part>
originally, i.e. C<< <> >>.
What if one wanted to curry in whatever the default is, i.e., assumin
The string_grow function (currently used only by string_replace) does not
allocate a new buffer if there are no bytes to be copied from old buffer to
new buffer. Patch below fixes this.
--
Peter Gibbs
EmKel Systems
Index: string.c
=
Me wrote:
> > "given nothing...":
> >
> > given () { ... }
>
> do { ... }
>
> seems simpler.
But doesn't have the same effect. A C inside a C responds to
the current value of the "subject" specified by any surrounding
topica
> "given nothing...":
>
> given () { ... }
do { ... }
seems simpler.
> Suppose you want to preserve $_ and alias
>
>given $value -> $g {
'->' seems more visually noisy than it need be in this case.
Perhaps:
given $value as $g
At 09:50 PM 1/4/2002 -0500, Bryan C. Warnock wrote:
>Index: interpreter.c
Applied, thanks.
Dan
--"it's like this"---
Dan Sugalski even samurai
[EMAIL PROTECTED]
Index: interpreter.c
===
RCS file: /home/perlcvs/parrot/interpreter.c,v
retrieving revision 1.51
diff -u -r1.51 interpreter.c
--- interpreter.c 4 Jan 2002 03:37:43 - 1.51
+++ interpreter.c 5 Jan 2002 02:47:40 -00
Resending due to BT doing bad things to good nameservers.
Damian Conway <[EMAIL PROTECTED]> writes:
>> >$val = (foo())[0];
>> >
>> > List?
>>
>> Scalar, obviously.
>
> How do you figure that? (Not a criticism: I'd really like to understand your
> thought process her
Damian Conway <[EMAIL PROTECTED]> writes:
>> >$val = (foo())[0];
>> >
>> > List?
>>
>> Scalar, obviously.
>
> How do you figure that? (Not a criticism: I'd really like to understand your
> thought process here so I can assess the relative DWIMity of the two
> alternat
Aaron Sherman wrote:
> >> $ref = [1,2];
> >> @ary[$ref] = foo(); # probably a syntax error
>
> Ok, as far as I can recall, Larry hinted that arrays and references to
> arrays would be interchangable in many contexts in P6. In this case, I
> can't see any reason that subscripting wou
> > $val = (foo())[0];
> >
> > List?
>
> Scalar, obviously.
How do you figure that? (Not a criticism: I'd really like to understand your
thought process here so I can assess the relative DWIMity of the two
alternatives).
> With a possible runtime error if foo doesn't ret
Aaron Sherman <[EMAIL PROTECTED]> writes:
> On Sun, Dec 16, 2001 at 03:55:10PM +1100, Damian Conway wrote:
>
> [...]
>
>>> And, just for laughs:
>>>
>>> $ref = [1,2];
>>> @ary[$ref] = foo(); # probably a syntax error
>
> Ok, as far as I can recall, Larry hinted that arrays a
On Sun, Dec 16, 2001 at 03:55:10PM +1100, Damian Conway wrote:
[...]
>> And, just for laughs:
>>
>> $ref = [1,2];
>> @ary[$ref] = foo(); # probably a syntax error
Ok, as far as I can recall, Larry hinted that arrays and references to
arrays would be interchangable in many
Piers posed the following puzzles:
> @ary[0] = foo() # scalar
Yes.
> @ary[1,2] = foo() # list context
Yes.
> @bar = 1;
> @ary[@bar] = foo() # ? probably list or maybe scalar...
List. With an explicit array as index, it's definitely a (one-element) slice.
> @bar = (1,
"Brent Dax" <[EMAIL PROTECTED]> writes:
> Piers Cawley:
> # In the following code fragment, what context is foo() in?
> #
> # @ary[0] = foo()
>
> The short answer is scalar context. The long answer is below. Note
> that the long answer is only the way I think of it. You may think
> differe
> > @ary[0] =()= foo(); # " " " " " "" "
>
> Hm, thats a change from perl5. In perl5 that would assign the number of
> elements returned from foo(). Is there a good reason for this change ?
Firstly, Larry may have to rule on which behaviour actually *is*
On Fri, Dec 14, 2001 at 06:39:02AM +1100, Damian Conway wrote:
>
>> In the following code fragment, what context is foo() in?
>>
>> @ary[0] = foo()
>
> Scalar context. @ary[0] is a single element of @ary.
>
> To call foo() in list context use any of the following:
>
> (@
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.
> In the following code fragment, what context is foo() in?
>
> @ary[0] = foo()
Scalar context. @ary[0] is a single element of @ary.
To call foo() in list context use any of the following:
(@ary[0]) = foo(); # Assign @ary[0] the first element returned
@(@ary[
ll next to mine's.)
--Brent Dax
[EMAIL PROTECTED]
Configure pumpking for Perl 6
"Nothing important happened today."
--George III of England's diary entry for 4-Jul-1776
On Thu, Dec 13, 2001 at 12:12:14PM -0500, Ted Ashton wrote:
> Thus it was written in the epistle of Piers Cawley,
> > In the following code fragment, what context is foo() in?
> >
> > @ary[0] = foo()
>
> Scalar, I would think.
I assume that the following would make the assignment a slice
an
Thus it was written in the epistle of Piers Cawley,
> In the following code fragment, what context is foo() in?
>
> @ary[0] = foo()
Scalar, I would think.
Just my guess,
Ted
--
Ted Ashton ([EMAIL PROTECTED]) | From the Tom Swifty collection:
Southern Adventist University| "Multiplicati
In the following code fragment, what context is foo() in?
@ary[0] = foo()
the following code
@ary= foo()
obviously evaluates @foo in a list context, but in the first I'm no
longer sure.
--
Piers
"It is a truth universally acknowledged that a language in
possession of a ri
91 matches
Mail list logo