The topic for #perl6 is: pugscode.org/ planetsix.perl.org/ | nopaste: sial.org/pbot/perl6 | pugs: [~] <m oo se> (or rakudo:, kp6:, elf: etc.) (or perl6: for all) | irclog: irc.pugscode.org/
Set by TimToady on 25 November 2008.
GitHub23 perl6-examples: 3David Romano 07master0 SHA1-9327c00 00:41
fixed Spoonerism
is.gd/evnC
pugs_svn r24752 | particle++ | [S19] get rid of illustration grammar, it's in the revision history if i need it later. 02:26
lichtkind azawawi: did you look at the translation? 02:48
s1n does splice still only operate on indices? 02:59
that is, is there an easier way than the perl5 method of doing splice to remove an element in the middle of an array?
(and assigning the result back to itself, that always seemed like a pain in the butt) 03:00
GitHub16 perl6-examples: 3Eric Hodges 07master0 SHA1-25368a7 03:23
Adding solution for WSG Begginer 2007 #3
is.gd/evJb
perl6-examples: 3Eric Hodges 07master0 SHA1-d35112e
Merge branch 'master' of [email@hidden.address]
is.gd/evJc
s1n rakudo: my @t = <1 2 3>; push @t, 3 if !@t.exists(3); 04:04
p6eval rakudo 34906: RESULT«4»
s1n rakudo: my @t = <1 2 3>; push @t, 3 if !@t.exists(3); say @t.perl
p6eval rakudo 34906: OUTPUT«["1", "2", "3", 3]␤»
s1n uh oh, looks like a bug
is this something that's being worked on already?
eric256 s1n: from the comments in the code @array.exists($index) is how it is called 05:50
not a $value.. not sure about the spec though
buubot: spack exists 05:51
buubot eric256: S02-bits.pod:2 S03-operators.pod:4 S09-data.pod:2 S16-io.pod:1 S29-functions.pod:5
eric256 and S29 backs up that definition of exists 05:53
eric256 hehe just realize i'm an hour later on that conversation ;) 05:55
rakudo: my @t = <1 2 3>; @.pairs.first({.value eq 1}).perl.say 05:57
p6eval rakudo 34911: OUTPUT«Lexical 'self' not found␤current instr.: '_block14' pc 91 (EVAL_13:46)␤»
eric256 rakudo: my @t = <1 2 3>; @t.pairs.first({.value eq 1}).perl.say
p6eval rakudo 34911: OUTPUT«0 => "1"␤»
eric256 rakudo: my @t = <1 2 3>; @t.pairs.first({.value eq 3}).perl.say
p6eval rakudo 34911: OUTPUT«2 => "3"␤»
eric256 rakudo: my @t = <1 2 3>; @t.push(3) unless @t.pairs.first({.value eq 3}); @t.perl.say; 05:58
p6eval rakudo 34911: OUTPUT«["1", "2", "3"]␤»
eric256 rakudo: my @t = <1 2 3>; @t.push(4) unless @t.pairs.first({.value eq 4}); @t.perl.say;
p6eval rakudo 34911: OUTPUT«["1", "2", "3", 4]␤»
eric256 rakudo: my @t = <1 2 3>; @t.push<4> unless @t.pairs.first({.value eq 4}); @t.perl.say;
p6eval rakudo 34911: OUTPUT«get_pmc_keyed() not implemented in class 'Integer'␤current instr.: 'parrot;Associative;postcircumfix:{ }' pc 1774 (src/classes/Associative.pir:40)␤»
eric256 oddly the spec for first and grep claim to support a Matcher object...but a Matcher is speced as a Item | Junction 06:08
not a sub at all
in fact the definition for matcher specifies that it should act like its on the RHS of a ~~
eric256 wonders what a block does on the RHS of ~~ and goes to find out 06:09
buu Hrm. 06:30
Is there a large collection of perl6 documents somewhere
avar t/ 06:32
literal buu: svn.pugscode.org/pugs/t/ 07:00
buu Isn't that mostly code? 07:01
literal oh, you want the specification? svn.pugscode.org/pugs/t/ 07:02
oops
damn paste
perlcabal.org/syn/
buu literal: Can I check that out from something? 07:27
literal yeah, they're in docs/Perl6/Spec in the pugs repo
eric256 making .first( ) dispatch to .'ACCEPTS' seems to make it work perfectly ;) 07:31
now i can do ('a..'z').first(any('a','b','c'));
and it works
eric256 starts a make spectest to see what happens to everything else ;) 07:32
buu literal: Oh, I have those =[ 07:39
buubot: spack continuation
buubot buu: S04-control.pod:4 S17-concurrency.pod:1
literal spack?
synopsis pod ack? 07:40
buu Essentially. 07:40
tyrelle hi 09:23
anyone here worked on genetic algorithms to optimise NP hard problems? 09:24
literal with Perl 6? I doubt it 09:45
tyrelle yes 09:51
or perl5
im doing this in c++ now 09:52
but the results are depressing frankly
Gothmog_ may be because of genetic algorithms ;-) 09:55
which problems are you trying to solve? 09:56
tyrelle NP 09:58
i'm looking lisp and perl to optimize 09:59
but i haven't a darn clue in perl, just tad bit
SubStack look on cpan 10:01
Gothmog_ I suppose you're speaking of NP-complete problems, and that is a class of problems, and I suppose you're not trying to solve them all at once.
SubStack also D: @ c++ for anything
Gothmog_ Nah. Anyhow, C++ can be pretty fast, which is very important if you want to solve hard problems. 10:02
SubStack fast algorithms are more important that fast implementation details 10:03
compilers are getting better all the time too 10:04
computers are much better at optimising code than people are
and they complain much less if you write your programs properly 10:05
Gothmog_ If you're speaking of assembly vs. C, you're usually right.
SubStack but possibly much more if you're using perl critic
Gothmog_ But if you speak of higher level languages, you will usually gain a huge factor of speed improvement without doing fancy things in C/C++. 10:06
s/without/even without/
SubStack or you could just throw more cores at the problem and whip up something in erlang or haskell 10:07
or perl6 with any luck 10:08
Gothmog_ That would be really interesting. But with really hard, huge problems, I suppose you would either run out of time or memory.
SubStack hah
computer-wise or programmer-wise? 10:09
Gothmog_ Programmer-wise first. :) But that's not what I meant.
SubStack dynamic languages definately have the advantage there
SubStack it's mostly a constant factor speedup anyways 10:10
Gothmog_ anyways?
You don't want to dispose a factor of 2 if you're program is running several days nonetheless.
SubStack not worth it until you've isolated the bottlenecks and are pretty sure you can make decent improvements in something like c
not if it takes you four days to write it 10:11
Gothmog_ No, it takes years to write it, with several programmers, and is run regularly by many people all over the world. 10:12
SubStack those sorts of problems are almost always I/O bound anyways
Gothmog_ They're not.
Please don't try to explain me the basics of optimization, as I have some experience with that. 10:13
SubStack the computer is there to do the work, the less work the programmer needs to do the better
Gothmog_ There are other people that want to work, and they can't when they have to wait. And additionally, with hard problems it's usually another trade-off, as you can always decide to let it run longer to achieve better results. 10:14
SubStack sounds pretty tedious 10:15
Gothmog_ Don't get me wrong, I would agree with you with most programming problems out there in the wild.
But not with (NP-)hard ones.
Yeah, it's somewhat tedious sometimes, but also very challenging. 10:16
tyrelle Gothmog_: yes 10:17
Gothmog_ Uh. That was the answer to which question? :-) 10:18
I lost track. ;-)
tyrelle NP hard problems
trying to optimize that
Gothmog_ *nods*
And which ones? 10:19
tyrelle just a min
brb
Gothmog_ SubStack: But as I don't have experience with languages like erlang or haskell, I would be really interested in an implementation of a heuristic for some hard problem. 10:20
Do you think you can do that? 10:21
SubStack it's all been done
I'd look to see what other people have come up with first
Gothmog_ Right.
I just found a probably interesting master thesis about implementing algorithms for hard problems in haskell: www.bth.se/fou/cuppsats.nsf/all/36a...hammad.pdf 10:27
reading & 10:28
pmurias tyrelle: it's highly unlikely that your algorithms/heuristics will run faster in perl than in C++ 11:00
buu Sure, if you use the *exact* same algorithm. 11:08
pugs_svn r24753 | pmurias++ | [smop] overloaded .,ne,eq for SMOP::Object 11:10
r24753 | pmurias++ | we don't destroy the p5 interpreter so we get memory leaks but not a segfault
r24753 | pmurias++ | [mildew] add example/cgi.pl
pmurias buu: there might better (XS using) one on CPAN ;) 11:11
buu pmurias: I just recall an interesting example I saw in some perl tutorial book I read quite a while ago that made the quite accurate point that its easy for perl to be a lot faster than C when your perl is full of stuff like hash look ups and regex operations and the C isn't. 11:13
Gothmog_ But if it's a real problem, you would use a hashtable in C. 11:16
SubStack *really*?
SubStack who does that, in c no less 11:16
Gothmog_ I've done that several times in C or C++. 11:17
pmurias there is a hash_map in STL
and writing your own hash isn't that hard ;)
Gothmog_ But often, there are simpler (and faster) ways than using a hashtable.
Not simpler as using hashes in Perl, of course. 11:18
Yeah.
SubStack everything in /c(?:\+\+)?/ is too much work 11:19
buu Gothmog_: Sure, you could. That also reminds me of all the people who expect to some how translate perl in to C and magically speed thing sup. 11:20
Automatically translate that is.
Gothmog_ Often, you're right, but sometimes it's worth the effort. Plus, if you already have a library with useful data structures and algorithms, it's not that much more work. 11:21
buu: JIT compilers are working quite well. ;-) 11:22
pmurias buu: the perl version being magically slower is annoying tho
Gothmog_ At least where they exist. :)
And translating to C might be useful to reduce runtime overhead and use the optimization facilities of existing C compilers. 11:23
Not that I think that it would be a good idea to try to do it.
But it would probably be faster nevertheless. 11:24
buu Gothmog_: Not terribly, perl has *already* been compiled by the optimization facilities of C compilers.
You still have to execute the same machine operations. 11:25
Of course, last time I had this conversation JIT compilers didn't really exist.
But those are totally cheating.
Gothmog_ Nah, but the Perl code you're running wasn't optimized.
JIT compilers don't exist? In general, or for perl? 11:26
What do you mean, that is.
pugs_svn r24754 | pmurias++ | [smop] fixed .postcircumfix:<( )> on wrapped SV* 11:33
pmurias ruoso: hi 11:54
buu Gothmog_: I said *last time I had this conversation*
Gothmog_ Ah. 11:55
pugs_svn r24755 | pmurias++ | [mildew] fixed test count in t/p5_fetch_store.t 11:57
pugs_svn r24756 | pmurias++ | [smop] [smop/perl5 integration] 12:23
r24756 | pmurias++ | fixed the source of the segfault
r24756 | pmurias++ | $coro->cancel is called after they are not needed anymore
ruoso pmurias, hi.. I'm just taking a quick look here... need to leave in a bit 12:24
pmurias, I'm working on implementing "$has $.a"... but it is just the same as "has $!a; method a { $!a }" 12:25
that was why I was wishing it was a macro
ruoso pmurias, have you thought about implementing "use CGI:from<perl5>"? 12:27
pmurias yes planning do it right now
ruoso cool... 12:28
pmurias i'm thinking what would we need to have stuff as infix:<~>
ruoso Multi
all this operators are multi 12:29
pmurias and the prelude right?
s/the/a/
ruoso yeah... it will be easier
I'm working on "has $.a" in the way to compile Multi.pm 12:30
pmurias got to go to grandparents for lunch&
ruoso because once we have multi, we can implement the multi "trait_auxiliary:is"
and that means we can then compile Return.pm
and the bootstrap slowly begins 12:31
ruoso later &
ruoso masak++ # very nice use case for the "use deadlock" 14:09
masak ruoso: it bites us in November right now.
feels a bit silly.
ruoso the problem is that, after all, compile-time-run-time-barrier is very blurred 14:10
masak sure. that's the point of, say, eval. 14:11
ruoso it works very well for modules that doesn't perform anything at INIT time
but makes it very much fuzzy for modules that have code to be run at INIT
masak JIT-relearns what "INIT" time means
right.
ruoso maybe it becomes a requirement that modules with odd initialization code should be "require"d instead of "use"d 14:14
masak hm.
I don't feel I have a broad enough overview of the problem to have an opinion. 14:15
ruoso maybe that is the "dynamic linking" I was talking about in the other mail
masak but I do consider it a bit strange that I can precompile B but not A
ruoso the problem is that "use" is "static-link"
masak ok.
ruoso and in order to A import B, B needs to be INITialized 14:16
masak sounds a bit un-Perlish
rakudo_svn r34917 | masak++ | [rakudo] added S29-str/unpack.t to spectest.data 14:20
pmurias ruoso: doesn't INIT happen after all the "use" statments, as it's done at run time and use statements happend at compile time 14:38
masak good point. 14:39
mtnviewmark pugs: (1..20) Z ('a' ff 'd') 15:54
p6eval pugs: OUTPUT«*** No such subroutine: "&infix:ff"␤ at /tmp/AtVXXChEwR line 1, column 12-22␤»
masak mtnviewmark: ff and fff not implemented yet in Pugs.
mtnviewmark hey - I just sent you an e-mail
masak actually, I think they might have been added after Pugs stopped being in active development.
mtnviewmark: it's you! 15:55
mtnviewmark indeed
masak :)
mtnviewmark which might explain why I'm poking at obscure operators!
masak welcome to #perl6.
mtnviewmark thanks!
er - pugs isn't under active development?!?!?
masak mtnviewmark: well, poking at obscure operators isn't exactly uncommon in here.
mtnviewmark: you've been gone a long time, mister. 15:56
mtnviewmark sorry - the docs seem to indicate pugs is alive ....
masak mtnviewmark: I'd start my lines with 'rakudo: ' nowadays if I were you.
mtnviewmark: depends on what you mean by 'alive' I guess. it isn't dead.
it still runs on GHC 6.10. 15:57
masak but it runs in more or less the same way as two years ago. 15:57
mtnviewmark :-)
rakudo: (1..20) Z ('a' ff 'd')
p6eval rakudo 34921: OUTPUT«Statement not terminated properly at line 1, near "ff 'd')"␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:83)␤»
masak ff anf fff not implemented yet in Rakudo. 15:58
mtnviewmark heh!
well then!
so much for investigating the subtlties of ff vs. fff
masak mtnviewmark: they're a bit under-specced, I know. 15:59
mtnviewmark tell me about it!
masak it's the community's fault.
:)
mtnviewmark yeah, some guy hasn't kept his operator chart up-to-date .... 16:00
mtnviewmark ;-) 16:00
masak yeah, tell me about it.
but it's not just that.
we're understaffed: not enough spec writers/reviewers, not enough testers, not enough implementers... 16:01
mtnviewmark while you're here -- do you know the difference between $foo.{} and $foo.<> 16:03
?
masak yes. 16:04
{} doesn't autoquote.
<> does.
mtnviewmark my understanding is the $foo.{} is the same as %foo....
or have I got this totally wrong? 16:05
masak think of <> as a variant of qw() that also does indexing.
mtnviewmark: I think you've got that totally wrong, yes.
Perl 6 doesn't do any funny stuff with sigils anymore.
mtnviewmark hmmm.... right but with a . they are called "method like postcircumfixes" isn't that different than pare {} and <>
masak yes, sure. 16:06
let's go through it systematically, shall we?
mtnviewmark I'm all ears!
masak bare {} does hashes and blocks.
bare <> does an autoquoted list of stuff. so <a b c> in Perl 6 corresponds to qw<a b c> in Perl 5. 16:07
mtnviewmark right: { 1 => 100, 2 => 42 }
masak right.
mtnviewmark okay
but with the .?
literal mtnviewmark: %foo.{} is the same as %foo{} :)
masak %h.{$foo} indexes a key in %h
so does %h.<$foo>.
but the keys are different.
mtnviewmark AH so it is the method of quoting the keys for the hash
masak the key indexed by %h.{$foo} is whatever the contents of $foo is. 16:08
the key indexed by %h.<$foo> is '$foo'
mtnviewmark: aye.
mtnviewmark and «»? or (for the unicode impared) <<>>?
masak mtnviewmark: that's autoquoting with interpolation. 16:09
mtnviewmark got it 16:10
masak so in this case, %h.{$foo} and %h.<<$foo>> are equivalent.
mtnviewmark right but %h.{x$foo} is a syntax error by %h.<<x$foo>> works
*but 16:11
masak uhm.
I guess.
std: my %h; my $foo; say %h.<<x$foo>>
Matt-W yes that seems correct 16:12
p6eval std 24756: OUTPUT«00:07 87m␤»
masak yes, it's correct.
:)
mtnviewmark what does std: do?
masak mtnviewmark: it takes your piece of code... and pronounces it correct or incorrect :)
very convenient.
std: 2 ff 5
p6eval std 24756: OUTPUT«00:05 85m␤» 16:13
masak also correct.
mtnviewmark ah! Oracle at Delphi?
masak ...even if it's not yet implemented anywhere.
Matt-W is it feeding it through STD.pm or something?
masak mtnviewmark: in a manner of speaking.
Matt-W: aye.
Matt-W cool
masak Matt-W: extremely.
mtnviewmark glances over his chart to see what else he needs help understanding.... 16:14
masak mtnviewmark: good thing that you stopped by here. I would have suggested that by email, but you got here on your own. 16:15
Matt-W everyone here has been very helpful to me
masak (we pay him to say that)
Matt-W masak: I believe you owe me an implementation of infix:>>. 16:16
:P
masak Matt-W: I do? I'll have to check my records.
:P
Matt-W Payment to be made in Rakudo features 16:17
mtnviewmark glances at Syn03 and doesn't see infix:>>
masak Matt-W: but I'm having so much fun implementing C<unpack> right now!
Matt-W What I need is some sort of understanding of where all the code in Rakudo is
I keep trying to find things and thinking it just appears magically during compilation
masak Matt-W: have you found languages/perl6/docs/ ?
mtnviewmark oh wait, the period was not a sentence terminerator there you meant the meta operator >> applied to the operator . 16:18
I think IRC for language development needs two fonts
Matt-W mtnviewmark: yes I did indeed mean that
Matt-W gargh! no gvim! 16:18
Matt-W panics
masak or just say C<<< >>. >>>
mtnviewmark on the topic of meta-operators -- how general is the ! meta-operator? Can it only apply to the pre-defined comparison infix ops? 16:20
masak mtnviewmark: there's a note on that in S03, methinks.
mtnviewmark uhm, wasn't clear - to me 16:21
masak I'll see if I can find it.
mtnviewmark "Any infix relational operator may be transformed into its negative by prefixing with !" 16:22
masak mtnviewmark++ # coming here and posing all these interesting questions
mtnviewmark: there you go.
mtnviewmark but, well, I'd say "infix relational operator" isn't well defined
masak mtnviewmark: how so?
mtnviewmark well - that is the only occurrence of that phrase in that document!
and "relational operator" appears 5 times, but all in reference to the ! meta-operator 16:23
masak heh.
I think a 'relational operator' is one that returns Bool. 16:24
mtnviewmark So I think it is meant to apply to only the chaining binary precedence
moritz_ probably "infix operators that returns Boolean... what masak said ;)
masak as opposed to things like '+' and 'max'
moritz_: OH HAI
masak mtnviewmark: sounds reasonable. 16:25
mtnviewmark what about ?^ can I say !?^ ?
mtnviewmark that is infix and returns Bool, but isn't relational in the English sense 16:25
masak good question.
moritz_ mtnviewmark: you'd use !xor for that, probably
mtnviewmark hopes folks doesn't mind him being a programing language pedant!
masak mtnviewmark: no, 's cool.
we do that all the time here. 16:26
Matt-W It's compulsory
mtnviewmark well - see, !xor doesn't really flow from "infix relational operators"....
masak perl6: say (True !xor False)
p6eval pugs: OUTPUT«*** ␤ Unexpected "!"␤ expecting "=", "(", ":", operator or ")"␤ at /tmp/iUOHamZG6t line 1, column 11␤»
..rakudo 34925: OUTPUT«Statement not terminated properly at line 1, near "!xor False"␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:83)␤»
..elf 24756: OUTPUT«Parse error in: /tmp/jTG1nBD8RO␤panic at line 1 column 14 (pos 14): Only boolean infix operators may be negated␤WHERE: say (True !xor False)␤WHERE: /\<-- HERE␤ STD_red/prelude.rb:99:in `panic'␤ (eval):8:in `__infix_prefix_meta_operator_3862535'␤
..STD_red/prelude.rb...
masak the support for !xor isn't overwhelming.
moritz_ perl6: say 1 xor 0
p6eval elf 24756, pugs, rakudo 34925: OUTPUT«1␤» 16:27
mtnviewmark std: my $a; my $b; $a !xor $b;
p6eval std 24756: OUTPUT«############# PARSE FAILED #############␤Only boolean infix operators may be negated at /tmp/V2RBAaQAIl line 1:␤------> my $a; my $b; $a !xor $b;␤00:05 86m␤»
masak mwhahaha.
mtnviewmark aha!
moritz_ uhm, xor *is* a boolean infix operator
mtnviewmark std: my $a; my $b; $a !?^ $b;
p6eval std 24756: OUTPUT«############# PARSE FAILED #############␤Only boolean infix operators may be negated at /tmp/HYbpHzgVbq line 1:␤------> my $a; my $b; $a !?^ $b;␤00:05 86m␤»
mtnviewmark so - I think the intention is only the relationals can be negated 16:28
moritz_ TimToady: is missing STD.pm support for !xor intentional?
masak someone should @tell TimToady.
moritz_ he usually backlogs
masak ah, right.
TimToady: ditto !?^ 16:29
mtnviewmark TimToady: also !<=> and !xor
masak mtnviewmark: um, <=> doesn't return Bool.
moritz_ std: 1 X!=:=X 2 16:30
p6eval std 24756: OUTPUT«00:05 85m␤»
masak moritz_: :D
moritz_ rakudo: my ($a, $b, $c); say ($a, $b, $c) X!=:=X ($a, $b, $c)
p6eval rakudo 34925: OUTPUT«011101110␤»
masak nice!
moritz_ rakudo: my ($a, $b, $c); say [&&] ($a, $b) X!=:=X $c 16:31
p6eval rakudo 34925: OUTPUT«Statement not terminated properly at line 1, near "[&&] ($a, "␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:83)␤»
moritz_ rakudo: my ($a, $b, $c); say [and] ($a, $b) X!=:=X $c
p6eval rakudo 34925: OUTPUT«Statement not terminated properly at line 1, near "($a, $b) X"␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:83)␤»
moritz_ rakudo: my ($a, $b, $c); say all ($a, $b) X!=:=X $c
masak moritz_: could you do me a favour and see if you can run 'make test' to successful completion in November's p6w?
mtnviewmark masak - true - but if you thought of the ! hyper operator as inverting the relational test, then !<=> (and !cmp and !leg) should all make sense
p6eval rakudo 34925: OUTPUT«Junction<0xb5fbb61c>␤»
moritz_ rakudo: my ($a, $b, $c); say ?all ($a, $b) X!=:=X $c 16:32
p6eval rakudo 34925: OUTPUT«1␤»
masak mtnviewmark: I don't. I think of it as inverting a Bool.
mtnviewmark (realizes that that is totally absurd!)
moritz_ rakudo: my ($a, $b, $c); say ?all ($a, $b) X!=:=X $b
p6eval rakudo 34925: OUTPUT«0␤»
moritz_ masak: I can, but only with ~2week old versions of rakudo + November
moritz_ the test above is "are all containers on the right distinct from all containers on the left" 16:33
masak moritz_: hm, I'm not able to say if that'd lead to an interesting result or not.
moritz_: but one more data point cannot hurt.
mtnviewmark moritz_ is showing off! (or at least, showing rakudo off!)
masak Rakudo rocks. 16:34
rakudo: my $a = 5; my $b; $b := $a; say $a =:= $b
p6eval rakudo 34925: OUTPUT«1␤»
masak rakudo: my $a = 5; my $b := $a; say $a =:= $b 16:35
p6eval rakudo 34925: OUTPUT«1␤»
masak nice.
mtnviewmark so, on the topic of obscure relationals.... is but the opposite of does? as in $x does
masak rakudo: my @a = 1,2,3; @a[0] := @a; say @a.perl
moritz_ mtnviewmark: sometimes it just itches :-)
p6eval rakudo 34925: OUTPUT«rtype not set␤current instr.: 'parrot;PCT;HLLCompiler;panic' pc 146 (src/PCT/HLLCompiler.pir:102)␤»
masak mtnviewmark: no, I think 'does' is compile-time and 'but' is runtime 16:36
or something like that.
moritz_ masak: lots of errors (about not being able to call Failure.apply; Novemeber is from 2008-12-17, rakudo from 2008-12-26 or so)
eric256 hey, i patched rakudo to allow .first( ) to take anything that goes on the right hand side of ~~ which seems to match specs
masak moritz_: thank you.
moritz_: that's what I'm getting as well.
mtnviewmark $foo does Mixin xor $foo but Mixin
eric256 and it passes all spec tests still...now to see if it passes any new tests
mtnviewmark this should always be true .... ?
masak eric256++
mtnviewmark: they're not tests. 16:37
eric256 masak: it was like a two line fix so i'm skeptical.
masak eric256: no, anyone who adds a feature deserves a karma point.
moritz_ eric256: you can run 'perl tools/autounfudge.pl -a' ....
eric256 and want to apply it to grep as well since the specs say first should behave like grep but return only the first item
mtnviewmark er, okay - I'll have to find them in a different Syn then, as Syn03 is pretty thin on the point
and they are grouped with non-chaining conditionals
moritz_ eric256: if new tests pass, there might be a patch in autunfudge.patch after the run
masak mtnviewmark: try S12.
eric256 moritz_: whats the ... there? test file name? 16:38
oh nm
moritz_ eric256: in the long run that won't work, because ~~ also has some macro semantics, so a bare method can't always get the same behaviour 16:39
mtnviewmark thanks
masak np
mtnviewmark that also means I have to move them in the chart then.. .:-)
masak I'll be heading home soon, to get a bit of peace of mind with my C<unpack> implementation and my Chinese novel. 16:40
mtnviewmark okay - I'm being called away to make pancakes for the family
eric256 mortiz the specs say it should behave as if its on the RHS of a ~~ so i had first dispatch to " block_res = test.'ACCEPTS'(block_arg) "
masak mtnviewmark++ # updating chart
eric256 might not be right, but its what i could figure out on my own last night
mtnviewmark masak - I hope I can find you here later
thanks all for answering my questions
I'll be back..... ;-)
masak mtnviewmark: I'm usually here.
and if I'm not, many others are. 16:41
eric256 rakudo: pair('a',1) ~~ 'a' 16:44
p6eval rakudo 34925: OUTPUT«Could not find non-existent sub pair␤current instr.: '_block14' pc 62 (EVAL_13:40)␤»
eric256 ohhh i thought there was an explicit function for building pairs... 16:45
rakudo: say ('a' => 1) ~~ ('a' => 1) 16:46
p6eval rakudo 34925: OUTPUT«Method ':a' not found for invocant of class 'Perl6Pair'␤current instr.: 'parrot;Perl6Pair;ACCEPTS' pc 8140 (src/classes/Pair.pir:38)␤»
eric256 wow auto unfudge takes a long time 17:06
moritz_ eric256: it does a lot of (mostly stupid) work 17:14
it reomoves each single fudge line, runs the test again, and check if the tests still pass
if yes, it writes a patch that removes this line
gone again & 17:20
pmichaud infix:<cmp> isn't a infix relational op. 17:32
neither is infix:<xor>.
oh, maybe infix:<cmp> is... I'm still confusing it with C<leg> 17:33
but infix:<xor> isn't negatable with a meta-prefix ! 17:34
Matt-W Brain explodey 18:02
[matthew@asymptote parrot]$ ./perl6 -e "say ('bac' ~~ /a/).WHAT"
Match
[matthew@asymptote parrot]$ ./perl6 -e "('bac' ~~ /a/).WHAT"
Null PMC access in get_integer()
azawawi hi 18:07
azawawi moritz_: ping 18:16
ruoso @tell pmurias but in order to call EXPORTALL on the package, it needs to be INITialized 18:48
lambdabot Consider it noted.
azawawi masak: ping 19:30
pugs_svn r24757 | ruoso++ | [smop] small fix in Attribute. 20:24
r24757 | ruoso++ | [smop] Add the lowlevel attribute to the lexical scope
r24757 | ruoso++ | [mildew] implements "has $!a", but PurePrototypeHOW still doesnt support it
s1n moritz_: pmichaud said you could use some help sifting through your tickets 20:35
moritz_: but it doesn't look like you have many that are unresolved, that is, they're all mostly marked resolved (i checked last night anyways) 20:36
pugs_svn r24758 | ruoso++ | [smop] PurePrototypeHOW implements add_attribute 22:38