Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2009-01-24

Perl 6 | Reference Documentation | Rakudo

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:00 frew_ joined #perl6
00:00 frew_ Hello friends, I was told that this is the place to ask if I'd like to make commits to the spec test
00:09 TimToady yes, it is, but Friday night is perhaps not the best time :)
00:09 frew_ That's fine
00:09 frew_ I can code without it
00:10 TimToady nevertheless, /msg me your email addr and preferred nick and I can add you
00:10 frew_ k
00:11 TimToady commitbit sent
00:12 frew_ Exciting! Thanks!
00:12 TimToady it's customary to add yourself to AUTHORS as first checkin to make sure it all works
00:13 frew_ ok, will do
00:13 frew_ thanks
00:13 km2 joined #perl6
00:16 diakopter TimToady: fyi if commitbit ever isn't responding, merely sighup it on feather as root, and it will return to life.
00:17 diakopter "Lazarus, sighup!"
00:17 diakopter just like that.
00:18 legis joined #perl6
00:25 pugs_svn r25011 | frew++ | Hello friends!
00:34 pcbuetow joined #perl6
00:36 spx2 joined #perl6
00:43 jhuni joined #perl6
00:55 typename joined #perl6
01:04 [particle] joined #perl6
01:04 [particle] std: ABC: 1; ABC: 2;
01:04 p6eval std 25011: OUTPUT«############# PARSE FAILED #############␤You tried to use an existing typename as a label at /tmp/7wUS6D1kme line 1:␤------> [32mABC: 1; ABC: [31m2;[0m␤00:05 83m␤»
01:05 [particle] std: loop { ABC: 1; }
01:05 p6eval std 25011: OUTPUT«00:05 83m␤»
01:05 [particle] are labels lexically-scoped?
01:06 [particle] i'm guessing that would be a runtime error, but std doesn't have a runtime
01:19 Whiteknight joined #perl6
01:45 [particle] left #perl6
02:00 eternaleye joined #perl6
02:01 TimToady diakopter: okay, that's good to know.  going through the whole restart procedure is a bit of a pain...
02:09 frew_ a function sig like this: foo ( $bar:) means that bar is a positional param and can be used like this: foo(:bar($baz)) right?
02:11 TimToady :$bar, not $bar:
02:11 TimToady a sig of ($bar:) would indicate that $bar is the invocant of a method
02:14 hercynium joined #perl6
02:14 Whiteknight As a matter of clarification, why the choice to use : as a suffix and not as a twigil or something here?
02:14 TimToady the invocant marking : is a comma variant
02:14 TimToady $self: $a, $b, $c
02:14 Whiteknight Oh, so it could be written "$bar   :", with whitespace?
02:15 TimToady yes
02:15 Whiteknight okay, that makes better sense.
02:15 Whiteknight thanks
02:15 frew_ Ok, that makes more sense
02:15 Whiteknight and makes more sense better
02:15 frew_ But that also means that very few builtins are supposed to have named parameters
02:16 frew_ according to the manfile
02:16 TimToady manfile?
02:16 frew_ the one generated when I build pugs
02:16 frew_ the spec
02:16 frew_ for S29
02:17 TimToady well, from a FP viewpoint having a function with options means your functions aren't correctly decomposed
02:17 frew_ I agree
02:17 TimToady so having options is a bit of a design smell at times
02:18 TimToady but not everyone is a functional programmer :)
02:19 TimToady so we're in the business of encouraging clean code, not requiring it...
02:19 frew_ well, I tend to agree with you, but line 88 in t/TASKS says that the builtins can/should have named parameters
02:21 TimToady okay, I see what was confusing you
02:21 TimToady that $string is in fact an invocant
02:21 TimToady and as such, a positional parameter
02:21 frew_ ooooh
02:21 TimToady the task is to allow :$string on the call
02:21 frew_ so that's kinda magic-y
02:21 TimToady or string($x)
02:21 TimToady :string rather
02:21 frew_ right
02:21 TimToady and have it map to positional
02:22 TimToady (presumably because the position of the name can be derived from the proto decl)
02:22 frew_ hmmm
02:22 frew_ so basically all string methods should have that same style deal if they have no args when called like $str.foo()
02:23 TimToady can omit the () in that case
02:23 frew_ yeah
02:23 frew_ but still
02:23 frew_ I am planning on added that stuff to the test and I want to make sure I can do the right thing
02:24 TimToady but because it's the invocant, there's no notation for using a name parameter as the invocant
02:24 TimToady so line 85 is a bit misleading that way
02:24 frew_ 85?
02:24 frew_ or 88
02:24 TimToady *88
02:24 TimToady sorry
02:24 frew_ so should that just be removed for TASKS?
02:24 TimToady my foot slipped
02:24 frew_ haha, k
02:25 frew_ from*
02:25 TimToady well, actually, that particular method is exported
02:25 TimToady so there is a function form where $string is just a positional parameter, not an invocant
02:25 TimToady so capitalize(:string($x)) makes sense
02:26 frew_ so it should be done on any exported functions?
02:26 TimToady an exported method sig should get rewritten to a function sig
02:27 TimToady but an exported function sig doesn't need to be rewritten
02:27 frew_ You lost me...
02:27 TimToady when we export a method, it's no longer a method, but an ordinary function
02:27 frew_ k
02:28 TimToady it's how we "pun" various builtin methods into functions without having to write two implementations, one a method and another a function
02:28 frew_ my question is: should I still add capitalize(:string($foo)) to the spectest?
02:28 TimToady so @array.push(1,2,3) and push(@array, 1,2,3) are really calling the same code
02:28 TimToady yes
02:29 frew_ alright
02:29 frew_ and it needs to be done on methods that have our in the front?
02:29 frew_ is that how they get exported?
02:29 TimToady it's the "is export"
02:30 frew_ at the end
02:30 frew_ gotcha
02:31 frew_ those are kinda gnarly function/method definitions.  Are we going to be writing that kind of stuff in production code or is a lot of that because they are part of the language?
02:32 TimToady it's mostly the latter
02:32 frew_ k
02:32 TimToady most user defined functions are just 'method foo ($x, $y) {...}'
02:33 frew_ even if they aren't a method but a function?
02:33 TimToady or 'method foo (Int $x, Int $y --> Int) {...}' if you get typey
02:33 TimToady typical function is 'sub foo ($x, $y) {...}'
02:33 frew_ cool
02:33 TimToady or 'multi foo ($x, $y) {...}'
02:34 TimToady well, a multi is likelier to have types
02:34 frew_ yeah, what does that actually mean?
02:34 TimToady it means there are other definitions of the foo subroutine, and the dispatcher should pick the best one
02:34 TimToady suppose you also have 'multi foo ($x) {...}'
02:35 TimToady then it knows which one to call for foo(1) vs foo(1,2)
02:35 TimToady but same principle for types as well as argument count
02:36 TimToady all the builtin operators are really multi subs with funny names like infix:<+>
02:36 TimToady so when you say $a + $b it can decide whether to add to integers, or floats, or complex numbers
02:36 frew_ so why do we have to specify mutli?
02:36 TimToady s/to/two
02:36 frew_ multi*
02:37 frew_ why can't it figure that out at compile time automatically?
02:37 TimToady the default is an "only" sub, as in p5
02:37 TimToady so mixing one of those with a multi is likely an error
02:38 TimToady and an only sub is easier to optimize
02:38 frew_ ah, k
02:38 TimToady an inner "my only sub" hides all outer multis of the same name
02:39 frew I am guessing inner means private?
02:39 frew or something
02:39 TimToady I just mean an inner lexical scope
02:39 c9s joined #perl6
02:40 TimToady anyway, the main point is that in perl 6 we try to encourage the programmer to convey the intent such that we can catch mistakes of the 1 vs many variety
02:40 TimToady that's also why hyper operators are explicit
02:41 frew_ that makes sense
02:41 frew_ what is a hyper operator?
02:41 frew_ like +?
02:42 TimToady @a »+« @b adds all the elements in parallel
02:42 lambdabot Maybe you meant: activity activity-full admin all-dicts arr ask . ? @ v
02:42 TimToady like vector addition on a Cray, or in a GPU
02:42 frew_ that's awesome
02:42 frew_ do we have to use unicode to do it?
02:43 frew_ I don't know how to type those ;-)
02:43 TimToady @a >>+<< @b is also acceptible, though uglier
02:43 lambdabot Maybe you meant: activity activity-full admin all-dicts arr ask . ? @ v
02:43 TimToady well, not acceptable to lambdabot :)
02:43 frew_ haha, well, that's a really cool feature
02:43 TimToady those are the "Texas" versions :)
02:43 zamolxes joined #perl6
02:43 frew_ hahahaha
02:43 frew_ hey, I'm in texas!
02:43 frew_ so it's like a mega reduce?
02:44 TimToady pugs: (1,2,3) >>+<< (3,2,1)
02:44 p6eval pugs: RESULT«(4, 4, 4)»
02:44 frew_ or... not a reduce
02:44 TimToady well, without the reduce part :)
02:44 TimToady pugs: [+] 1,2,3
02:44 p6eval pugs: RESULT«6»
02:44 frew_ just a parallel thign
02:44 frew_ thing*
02:44 TimToady that's the reduce
02:44 frew_ yeah, I read about that a couple days ago
02:44 frew_ it's the nicest syntax I've ever seen for reduce
02:45 * TimToady bows
02:45 frew_ so if I wanna reduce a hyperopp do I do like: [+] (1,2,3) >>+<< (3,2,1)
02:45 TimToady it's intended to be visually distinct, and have associations with lists
02:45 frew_ yeah, I totally got it
02:45 frew_ I think it's great
02:45 frew_ what about arbitrary functions?
02:46 frew_ pugs: [foo] (1,2,3)
02:46 p6eval pugs: OUTPUT«*** ␤    Unexpected "("␤    expecting operator␤    at /tmp/yx314dl62y line 1, column 7␤»
02:46 TimToady then you can always call reduce()
02:46 frew_ erk
02:46 frew_ yeah, that makes sense
02:46 TimToady it's only defined for infix operator
02:46 TimToady but that includes user-defined ops
02:46 frew_ which can be done like this: (1,2,3).reduce(sub { ...} )
02:46 frew_ ?
02:47 TimToady no need for the 'sub' since bare blocks are closures in p6
02:47 frew_ great
02:47 TimToady pugs: (1,2,3).reduce({ $^a + $^b })
02:47 p6eval pugs: RESULT«6»
02:47 TimToady there you go
02:47 frew_ cool
02:47 frew_ very cool
02:48 frew_ well, is there a way I can view these generated docs in html?
02:48 frew_ the 3pm spec files?
02:49 TimToady try http://perlcabal.org/syn/
02:49 kid51 joined #perl6
02:49 frew_ that'll work
02:49 frew_ pugs: 1,2,3 >>+<< 3,2,1
02:49 p6eval pugs: OUTPUT«*** Hyper OP only works on lists␤    at /tmp/sdHDJxIF6k line 1, column 1 - line 2, column 1␤»
02:50 frew_ pugs: (1,2,3) >>+<< (3,2,1)
02:50 p6eval pugs: RESULT«(4, 4, 4)»
02:50 frew_ rakudo: (1,2,3) >>+<< (3,2,1)
02:50 p6eval rakudo 35937: RESULT«[4, 4, 4]»
02:52 pugs_svn r25012 | lwall++ | [STD] more random cleanup
02:52 frew_ One more thing
02:53 frew_ So for capitalize, should it be capitalize(:string($foo)) or capitalize(:Str($foo))?
02:53 TimToady :string
02:53 TimToady Str is the type, and isn't used for named params
02:53 frew_ yeah
02:53 frew_ ok
02:54 frew_ so the way that I know this is
02:54 frew_ #1 it has "is export"
02:54 frew_ and $foo: is the invocant
02:54 frew_ so that's the named param
02:54 TimToady therefore :foo($x) should work
02:54 TimToady to the function call, but not to the method call
02:54 frew_ right.
02:55 frew_ and what if it has multiple params, like samecase, would that be samecase(:string($foo), $pattern) and samecase($pattern, :string($foo))?
02:57 TimToady in theory, either should work, though the latter is arguably bad style
02:57 frew_ agreed
02:57 frew_ but it should be valid right?
02:58 TimToady we outlawed it once upon a time, but I think it's currently valid. and positionals are just filled in after the named parameters are bound
02:58 frew k
02:58 TimToady or, looking at it the other way, any given parameter looks for a named binding before shifting the next positional
02:59 frew the first way made more sense to me, but ok
02:59 TimToady the bindings have to be done left to right in the parameter list of the sig, so that defaults can refer to earlier parameters in the list
03:00 frew should I skip these if they aren't passing with the preprocessor?
03:00 frew yeah
03:00 TimToady how mean do you feel?  :)
03:00 TimToady good testers feel mean most of the time :)
03:00 frew well, I'm usually not a good tester
03:01 frew should I be mean?
03:01 TimToady nobody will shout at you for installing failing tests...
03:01 frew hahaha
03:01 TimToady in fact, that's kinda the point :)
03:01 frew yeah, I hear you
03:01 frew ok
03:01 frew then I won't have them skip
03:02 TimToady and we tend to go on a forgiveness rather than permission basis, so if you goof it up, we'll just fix it later
03:02 TimToady though it also doesn't hurt to ask if you're unshure
03:02 frew yeah, that's the idea
03:03 * TimToady wonders where 'unshure' came from...
03:03 frew I figure that you guys are trying so hard to make the best language ever; it's a drag if some noob gets a commitbit and burns it all to the ground
03:03 frew with a bad test?
03:03 TimToady that's what revision control is for :)
03:03 frew anyway, is it supposed to stop the test entirely if the test fails?
03:03 frew yep
03:04 frew the test being the group of tests in the same file
03:04 TimToady well, if you happen to know that it will cause a parsefail
03:04 TimToady then you can install a "fudge" line like you already see lots of examples of
03:05 TimToady and then the fudge preprocessor will comment it out or eval it or whatever
03:05 frew but this isn't a parsefail is it?
03:05 TimToady no, it should parse fine
03:05 TimToady std: samecase($pattern, :string($foo))
03:05 frew well, I am starting with capitalize
03:05 p6eval std 25012: OUTPUT«00:06 105m␤»
03:05 TimToady that means it liked it
03:06 TimToady std: Int: 42;
03:06 p6eval std 25012: OUTPUT«############# PARSE FAILED #############␤Illegal redeclaration of 'Int' at /tmp/bUl8N44VBc line 1:␤------> [32mInt: [31m42;[0m␤00:05 71m␤»
03:06 frew_ wait really?
03:06 TimToady that means it didn't
03:06 frew_ std: capitalize(:string("fREW"))
03:06 p6eval std 25012: OUTPUT«00:06 86m␤»
03:06 frew_ weird
03:06 TimToady it's just the STD parser
03:06 frew_ pugs: capitalize(:string("fREW"))
03:06 p6eval pugs: OUTPUT«*** Named argument found where no matched parameter expected: (string,Ann (Pos (MkPos "/tmp/OETdTzqGJX" 1 20 1 26)) (Val (VStr "fREW")))␤    at /tmp/OETdTzqGJX line 1, column 1 - line 2, column 1␤»
03:07 TimToady it says how many seconds it took and the memory
03:07 frew_ ok, so pugs is failing but the parser can parse it
03:07 TimToady but since it doesn't run it, it says nothing else if it's correct
03:07 frew_ right
03:07 frew_ well, I am just wondering why you would stop halfway through the file if a single test fails
03:07 frew_ which is what happens for me in capitalize.t
03:08 TimToady yes, pugs can't handle it, though I'm not sure if it's a run time error
03:08 frew ok
03:08 TimToady anyway, you can use fudge for pugs too
03:08 frew right
03:09 TimToady it'll rewrite foo.t to foo.pugs, and then you run that
03:09 TimToady or foo.rakudo, or whatever
03:09 frew ok
03:09 frew k
03:09 TimToady the make test tends to do that for you
03:10 TimToady well, gotta decommute, have fun
03:10 frew make test or make spectest?
03:10 frew alright
03:10 frew thanks for the help
03:10 TimToady bbl &
04:08 [particle] joined #perl6
04:22 sail0r joined #perl6
04:24 sail0r left #perl6
04:28 justatheory joined #perl6
04:39 Minthe joined #perl6
04:46 s1n can multi's be overloaded? that is if there is a 'multi sub myfunc(Int $f) {..}', can i "overload" it in the traditional sense?
05:14 frew_ pugs: 'text'sameaccent('acdf')
05:14 p6eval pugs: OUTPUT«*** ␤    Unexpected "sameaccent"␤    expecting term postfix or operator␤    at /tmp/FBkLXdEAPn line 1, column 7␤»
05:14 frew_ pugs: 'text'.sameaccent('acdf')
05:14 p6eval pugs: OUTPUT«*** No such method in class Str: "&sameaccent"␤    at /tmp/komZGH6uqW line 1, column 1 - line 2, column 1␤»
05:14 frew_ rakudo: 'text'.sameaccent('acdf')
05:14 p6eval rakudo 35939: OUTPUT«Method 'sameaccent' not found for invocant of class 'Str'␤current instr.: 'parrot;P6metaclass;dispatch' pc 287 (src/classes/ClassHOW.pir:145)␤»
05:16 frew_ anyone in here know how sameaccent is supposed to work?
05:49 meppl joined #perl6
05:58 sail0r joined #perl6
06:00 bacek joined #perl6
06:01 bacek perl6: say ("foo\n", "bar\n").chomp.WHAT
06:01 p6eval rakudo 35944: OUTPUT«Str␤»
06:01 p6eval ..pugs: OUTPUT«Array␤»
06:01 p6eval ..elf 25012: OUTPUT«Useless use of a constant in void context at (eval 125) line 3.␤Modification of a read-only value attempted at ./elf_h line 95.␤ at ./elf_h line 4333␤»
06:02 bacek perl6: my @a = ("foo\n", "bar\n"); my @b = @a.chomp; say ~@a; say ~@b
06:02 p6eval rakudo 35944: OUTPUT«foo␤ bar␤␤foo␤ bar␤»
06:02 p6eval ..pugs: OUTPUT«foo␤ bar␤␤foo bar␤»
06:02 p6eval ..elf 25012: OUTPUT«Can't call method "chomp" on unblessed reference at (eval 125) line 4.␤ at ./elf_h line 4333␤»
06:02 bacek ok. Should .chomp works on arrays?
06:17 TimToady no, but hyperchomp should
06:18 sail0r left #perl6
06:18 TimToady s1n: the whole point of multi is to support overloading, or are you asking for something else?
06:35 bacek TimToady: thanks.
06:39 pugs_svn r25013 | bacek++ | [spec] Remove @list.chomp tests. .chomp shouldn't work on lists.
07:19 mtnviewmark joined #perl6
07:22 mtnviewmark std: $a.*(42)
07:22 p6eval std 25013: OUTPUT«00:05 86m␤»
07:22 mtnviewmark hmmm... anyone have a clue what that is supposed to mean?
07:22 mtnviewmark I think $a.(42) is the same as $a(42)
07:23 mtnviewmark but $a.*(42)
07:23 literal rakudo: my $a = 2; $a.*(42)
07:23 p6eval rakudo 35948: OUTPUT«Parrot VM: PANIC: Out of mem!␤C file src/gc/memory.c, line 141␤Parrot file (not available), line (not available)␤␤We highly suggest you notify the Parrot team if you have not been working on␤Parrot.  Use parrotbug (located in parrot's root directory) or send an␤e-mail to
07:23 p6eval ..parrot-p...
07:25 mtnviewmark well - that's nice!
07:26 frew_ pugs: my $a = 2; $a.*(42);
07:26 p6eval pugs: OUTPUT«*** ␤    Unexpected "*("␤    expecting ".", "\187", ">>", "=", "^", operator name, qualified identifier, variable name, "...", "--", "++", "i", array subscript, hash subscript or code subscript␤    at /tmp/ipRA08AUFV line 1, column 15␤»
07:26 mtnviewmark well... let's look at something that should work
07:27 mtnviewmark rakudo: my $a = <foo bar baz>; $a.[1]
07:27 p6eval rakudo 35948: OUTPUT«Parrot VM: PANIC: Out of mem!␤C file src/gc/memory.c, line 141␤Parrot file (not available), line (not available)␤␤We highly suggest you notify the Parrot team if you have not been working on␤Parrot.  Use parrotbug (located in parrot's root directory) or send an␤e-mail to
07:27 p6eval ..parrot-p...
07:27 mtnviewmark rakudo: my $a = <foo bar baz>; $a[1]
07:27 p6eval rakudo 35948: OUTPUT«Parrot VM: PANIC: Out of mem!␤C file src/gc/memory.c, line 141␤Parrot file (not available), line (not available)␤␤We highly suggest you notify the Parrot team if you have not been working on␤Parrot.  Use parrotbug (located in parrot's root directory) or send an␤e-mail to
07:27 p6eval ..parrot-p...
07:27 mtnviewmark wellllll I suppose that isn't working
07:29 mtnviewmark I suspect that while .[ ] is supposed to work (and mean the same as just [ ]) --- that .*[ ] and friends are actually meaningless
07:32 frew_ What would that mean?
07:33 mtnviewmark exactly --- where as something like $a.[3] is the same as $a[3] ... $a.*[3] and $a.?[3] and $a.^[3] don't make any sense to me... but are parsed by STD.pm
07:33 mtnviewmark also... $a.=[3] is suppose is legal, and oddly sensical: "replace the value of $a to the 4th element of $a"...?!
07:34 mtnviewmark and   $a!{'foo'} is another non-sensical thing... a private hash lookup?
07:34 mtnviewmark std: $a!{'foo'}
07:34 p6eval std 25013: OUTPUT«############# PARSE FAILED #############␤Syntax error (two terms in a row?) at /tmp/22n3wsUNkq line 1:␤------> [32m$a[31m!{'foo'}[0m␤    expecting any of:␤       POST␤   infix or meta-infix␤        infix stopper␤    postfix␤        postfix_prefix_meta_operator␤       standard
07:34 p6eval ..stopper␤ statement modifier loo...
07:35 mtnviewmark whoops
07:35 mtnviewmark std: $a.^!{'foo'}
07:35 p6eval std 25013: OUTPUT«00:05 86m␤»
07:35 mtnviewmark tada
07:35 mtnviewmark what's that? a private meta hash lookup?
07:35 frew_ nice
07:35 frew_ no clue
07:36 mtnviewmark I can fix STD.pm to not parse these beasts...but I don't want to remove them if they have some cryptic meaning
07:36 TimToady in theory they're meaningful, most of 'em
07:37 mtnviewmark $a.^!{'foo'} --- ?
07:37 TimToady if .() is just a funny method, then there may be more than one candidate
07:37 TimToady in which case .*() makes some sense
07:37 TimToady or there may be no candidate, in which case .?() makes sense
07:37 mtnviewmark oh - is that a funny method? as in it looks up a method with the name '()'
07:37 frew_ what doeas .*method() mean?
07:37 frew_ do all of them?
07:38 TimToady yes, do all of them
07:38 frew_ hm
07:38 mtnviewmark frew_ the () in that is different - those are surrounding arguments
07:38 TimToady until one says its the last one
07:39 mtnviewmark okay then... oddity of oddities!  I'll have to figure out how to get .*{} on the chart!
07:39 TimToady see S13:162
07:39 TimToady method postcircumfix:<( )> ($capture) {...}
07:39 mtnviewmark now -- what is .:meth?  is this no longer prefix operators?
07:39 TimToady we don't support those any more, I think
07:39 mtnviewmark okay STD.pm has 'em
07:40 mtnviewmark also supports .postop
07:40 TimToady fossil from when :r et al. were implemented that way
07:40 mtnviewmark so...    $a.++ is there -- should that go?
07:40 TimToady no, any postfix may take an optional dot
07:40 TimToady (except alphanumeric ones, I guess)
07:40 mtnviewmark seems odd, after all there are only three postfixes possible there:  ++, --, and i
07:41 mtnviewmark and I thought you decided that   .i  was a method, not the postfix operator
07:41 TimToady we're trying to establish generic rules for extensibility
07:41 TimToady yes. $x.i must now be written $x\i
07:41 TimToady or ($x)i
07:41 mtnviewmark okay... so dotted postfixes in, dotted prefixes out, cool (just want the chart to be right!)
07:41 TimToady so the dot form is becoming less important
07:42 mtnviewmark (in so far as it can match a moving target!  :-) )
07:42 TimToady might go away someday
07:42 mtnviewmark (btw: Got a 24" x 18" high quality print proof today of the chart.... it looks awesome if I do say so myself!)
07:42 TimToady possibly the dot forms could give direct access to a method form, if the dotless form is mediated by a multi function
07:43 mtnviewmark lesse... looks also like STD.pm doesn't parse ! as private method correctly:
07:43 mtnviewmark std:  $a!foo(3)
07:43 p6eval std 25013: OUTPUT«00:05 86m␤»
07:43 mtnviewmark but
07:43 mtnviewmark std: $a!(3)
07:43 p6eval std 25013: OUTPUT«############# PARSE FAILED #############␤Syntax error (two terms in a row?) at /tmp/yPvgLzaWwr line 1:␤------> [32m$a[31m!(3)[0m␤    expecting any of:␤   POST␤   infix or meta-infix␤        infix stopper␤    postfix␤        postfix_prefix_meta_operator␤       standard stopper␤
07:43 p6eval ..statement modifier loop␤  t...
07:44 TimToady currently only alpha methods work as private, not sure if we need to allow non-alpha, esp if it's ambiguous
07:44 mtnviewmark well... true, but it *does* work for meta priavtes!
07:44 TimToady would make it hard to define postfix:<!> as factorial, for instance
07:44 mtnviewmark std: $a.^!(3)
07:44 p6eval std 25013: OUTPUT«00:05 86m␤»
07:45 TimToady I haven't really had much to do with the .^! forms, that smop internals :)
07:45 TimToady *that's
07:45 mtnviewmark did you see my comments on meta-ops?
07:45 TimToady so perhaps not officially part of the language
07:45 mtnviewmark I'd be happy to implement those fixes in STD.pm
07:45 mtnviewmark if you agree with them
07:45 TimToady yes, still working my way through it all
07:46 TimToady got stuck on your first remarks, and found STD needed some non-trivial work :)
07:46 mtnviewmark most of it was just changes to clean up the implementation and make it more regular -- no real changes to the language
07:46 TimToady well, infix:<;> disappeared today, since semilist can parse statements anyway
07:46 mtnviewmark The only real change suggested was cleaning up the ops that can be within hyper
07:47 TimToady all that is dependent on work in the lexer, unfortunately
07:47 mtnviewmark oh - good - never made it to the chart !
07:47 TimToady the current form of metas is kinda hand-to-mouth to get the common ones to work
07:47 mtnviewmark I just e-mailed a typo fix in the meta operators.... (don't have commit rights)
07:48 TimToady but I'd like to support all combinations of metas that aren't recursive
07:48 TimToady and it doesn't do that yet
07:48 mtnviewmark no recursive? really?   >>>>+<<<<  isn't going to be allowed?
07:48 TimToady nope
07:48 mtnviewmark odd, since >>>>++ is!
07:48 TimToady can't have left recursion in a DFA!
07:48 mtnviewmark or did you not realize that prefix >> and postfix << are recursive
07:49 TimToady well, can't have recursion in a DFA at all..
07:49 TimToady well, it's an accident if it works recursively
07:49 mtnviewmark okay - they are iterative
07:50 mtnviewmark std: $a >>>>++
07:50 p6eval std 25013: OUTPUT«############# PARSE FAILED #############␤Obsolete use of >> to do right shift; in Perl 6 please use +> or ~> instead at /tmp/KwrBdZ1VWB line 1:␤------> [32m$a >>>>[31m++[0m␤00:05 86m␤»
07:50 TimToady that's illegal
07:50 TimToady postfix may never have whitespace
07:50 TimToady std: $a.>>>>++
07:50 p6eval std 25013: OUTPUT«00:05 86m␤»
07:50 TimToady hah
07:50 TimToady well, it's not doing that with the lexer :)
07:51 mtnviewmark line 1086:  [ ['.' <.unsp>?]? <postfix_prefix_meta_operator> <.unsp>? ]*
07:51 mtnviewmark std: ++<<<< $a
07:51 p6eval std 25013: OUTPUT«00:08 125m␤»
07:51 TimToady yeah, it cheats on those, basically
07:51 TimToady they aren't really in an alternative, so the lexer doesn't come into play
07:52 TimToady but infixes can't do that
07:52 TimToady not and keep LTM working
07:52 mtnviewmark well, okay - I understand the parsing requirements... just a shame that if you have doubled hyper for prefix and postfix, you can't for infix
07:52 mtnviewmark perhaps then double hyper isn't worth the potential confusion?
07:52 TimToady I could if I abandoned LTM for metas
07:52 TimToady but then things get dicier in other ways
07:53 TimToady that's my feeling
07:53 TimToady you can always define your own infix and go from there
07:53 mtnviewmark in any event, one fix was that hyper should allow negated meta
07:53 mtnviewmark otherwise >>~~<< is valid but >>!~~<< isn't
07:53 TimToady yes, well, that part of the lexer isn't fully up to the task yet
07:54 mtnviewmark really? why it works for the reduce meta
07:54 TimToady you'll note even the reduce meta cheats
07:54 TimToady instead of calling infixish
07:55 TimToady it calls out the infix and meta-infix separately
07:55 mtnviewmark sure - so each meta would have to call the others directly...
07:55 mtnviewmark also, what is with that trailing « in the reduce productions?
07:55 TimToady but infixish has side effects that prevent it from composing right as it stands
07:56 TimToady again, a hardwired solution to composition rather than a general one
07:56 mtnviewmark ah, well, if so, will need a '<<' version in there as well
07:57 TimToady it's very easy to get a combinatorial explosion of possible tokens
07:58 TimToady it's quite possible that I'm trying for something impractical in fitting all the metas into the LTM
07:59 mtnviewmark recognizing that it would limit the "joy of meta", perhaps it would be best to only allow "plain jane" operators in the metas -- or just establish a directed hierarchy of inclusion
07:59 TimToady and maybe in the long run the meta bits will have to be considered as separate tokens, and the metaops parsed normally
08:00 TimToady another approach is to require complex metaops to be space delimited
08:00 TimToady thought that doesn't help with postfix, necessarily
08:00 TimToady *thoug
08:00 TimToady h
08:00 TimToady grr
08:00 mtnviewmark tis late
08:01 TimToady especialy in mtnview :)
08:01 TimToady ll
08:01 TimToady grrr
08:01 TimToady well, gotta get up at 6 to take teens to a quiz meet, so I'd probably better retire me own self...
08:01 mtnviewmark okay - well if you have any questions about what I meant in those e-mails, just give a hollar....
08:02 mtnviewmark and I'll be looking to your next checkin of STD.pm!
08:02 TimToady seemed pretty self explan
08:02 mtnviewmark night
08:02 TimToady night, thatnks!
08:02 TimToady s:3rd/t//
08:02 TimToady afk & # zzzzz
08:03 frew_ pugs: "frew".substr(1,2)
08:03 p6eval pugs: RESULT«\"re"»
08:03 frew_ pugs: "frew".substr(0,2)
08:03 p6eval pugs: RESULT«\"fr"»
08:03 frew_ pugs: "frew".substr(0,-1)
08:03 p6eval pugs: RESULT«\"fre"»
08:05 frew_ "froooooooooooooo".substr(1,2,'o')
08:05 frew_ pugs: "froooooooooooooo".substr(1,2,'o')
08:05 p6eval pugs: RESULT«\"ro"»
08:05 frew_ pugs: "froooooooooooooo".substr(1,2,'i')
08:05 p6eval pugs: RESULT«\"ro"»
08:05 pugs_svn r25014 | lwall++ | [STD] patch from mtnviewmark++
08:14 Minthe joined #perl6
08:14 frew_ Is anyone awake?
08:15 Matt-W I am, in a sort of just-woke-up way
08:15 frew_ haha
08:15 frew_ ok
08:16 frew_ well, do you have any idea how substr knows if it's last argument is a StrLen or an StrPos?
08:16 frew_ becuase if the user has to define it there is nothing in the spec test about it
08:17 Matt-W I didn't know it could do both, so sorry, no idea
08:17 frew_ well, I am just going by some docs that could also be out of date
08:17 frew_ so who knows :-)
08:17 Matt-W TimToady knows, of course
08:18 frew_ yeah, but he just went to bed
08:21 Matt-W S29 currently states that a number is considered to be a length, like in Perl 5
08:21 Matt-W so it would seem you have to explicitly make a StrPos somehow and give it that
08:21 frew_ yeah
08:21 Matt-W hmm spelling mistakes
08:22 frew_ but I am just wondering if we should also check for the StrLen option
08:22 frew_ as it is technically a different function
08:22 frew_ or method or whatever
08:22 frew_ yeah, I noticed one of the things was defined as out instead of our
08:22 Matt-W Probably. Because S29 mentions that a number is interpreted as characters in the current Unicode level, it seems that a StrLen object maybe carries more information than a plain number would
08:23 frew_ maybe
08:23 Matt-W like explicitly saying "four graphemes"
08:23 frew_ yeah
08:23 Matt-W I don't know this, I'm just speculating what seems sensible
08:23 Matt-W although last time I seriously did that, TimToady appeared and removed the method from the language...
08:23 frew_ also, interestingly apparently in the s29 stuff I am looking at pack and unpack aren't exported?
08:24 frew_ hahahaha
08:24 frew_ nice
08:24 Matt-W hmm interesting no, pack isn't exported in current S29
08:24 Matt-W and unpack isn't documented
08:25 Matt-W but it's not a method
08:25 frew_ yeah
08:25 Matt-W so it probably doesn't need is export - that's for making methods you can call as subs as well, I thought
08:25 frew_ but it's tested for
08:25 Matt-W hmm
08:25 Matt-W have to bring that up with someone else
08:25 frew_ yeah
08:25 frew_ 'm gonna write some of this stuff down and ask tomorrow
08:56 iblechbot joined #perl6
08:58 ayrnieu joined #perl6
09:13 mberends joined #perl6
09:51 ejs joined #perl6
09:59 smtms joined #perl6
10:15 masak joined #perl6
10:16 me1970 joined #perl6
10:20 mberends masak: hi, is there any SVG.pm to play with?
10:20 masak mberends: no, but ask again in a few hours.
10:20 mberends yes! Druid online!
10:21 masak aye!
10:21 masak there's also a refactoring pending before we can chuck SVG into Druid.
10:21 masak actually, before Druid can expand in a number of ways.
10:21 masak that might happen today as well.
10:22 mberends in the same few hours Pod::Parser will more than double its emitters and tests
10:25 masak impressive.
10:25 pmurias joined #perl6
10:28 mberends have you read some of TimToady's lessons in the last 2 days' backlogs? He has been explaining fine points of p6 language to chatters at odd hours. I would like to distil parts into U4X, but ... where? Several people have voiced documentation ambitions, but ... where?
10:28 spx2 joined #perl6
10:29 mberends a wiki ;-) might be a good place
10:31 masak mberends: I will backlog and see what I get.
10:32 masak mberends: in the meantime, please collect loose ideas in any fashion you prefer, except for in the README file in u4x/ :)
10:32 mberends how do I get a login account on http://november-wiki.org/ ?
10:33 masak mberends: I promise there will be a good place to put things shortly. but until then, we need unsorted ideas, the more, the better.
10:33 masak mberends: you ask one of the admins very nicely. :)
10:34 masak mberends: actually, viklund holds the keys to the server.
10:34 masak I'll tell him that you'd like an account.
10:35 masak actually, I'll make a patch for him :)
10:37 mberends I'll give SVG.pm a tryout on my p6 daemon at http://autoexec.demon.nl:8888
10:39 pbuetow joined #perl6
10:39 * mberends planning another netcat based hack today: LWP.pm
10:39 masak mberends: what is your email address? I want to send you the password.
10:39 mberends this nick @flashmail.com
10:39 masak sent.
10:40 mberends received.
10:41 masak I should add that it's a bad idea to put important content on that site right now, for several reasons.
10:43 mberends fair enough, there will be replicas elsewhere. Pod::to::mediawiki is beginning to itch...
10:43 pugs_svn r25015 | pmurias++ | [smop] separated smop_base.h into smop-base
10:43 masak looking forward to collaborate on that.
10:43 masak I have to do some chores for an hour or two before I dig into today's Perl 6 hacking.
10:50 DemoFreak joined #perl6
11:29 spx2_ joined #perl6
11:39 bacek_ joined #perl6
11:47 pengo joined #perl6
11:58 vixey joined #Perl6
12:20 |jedai| joined #perl6
12:52 mberends joined #perl6
13:07 masak mberends: your account at november-wiki.org is now active.
13:09 mberends thanks, logged in 15 mins ago and corrected a spello on main page
13:10 duke_leto joined #perl6
13:10 masak Tene: ping
13:10 masak mberends++
13:11 mberends well, [november team]++
13:13 lambdabot joined #perl6
13:14 icwiener joined #perl6
13:23 Whiteknight joined #perl6
13:29 hudnix joined #perl6
13:44 kid51 joined #perl6
13:47 |jedai| joined #perl6
14:04 spx2 joined #perl6
14:08 icwiener_ joined #perl6
14:12 s1n TimToady: i'm asking if I can overload a multisub with the same signature
14:13 s1n TimToady: that is, if you have 'multi sub func(Int $v){}', can i defined another 'multi sub func(Int $v)' and overload the currently available one (in whichever namespace)?
14:34 TimToady not in the same namespace, that would be an ambiguous dispatch, hence illegal
14:34 lambdabot TimToady: You have 1 new message. '/msg lambdabot @messages' to read it.
14:34 TimToady however, 'my multi' can be used in an inner scope to override the outer def with that sig
14:35 s1n TimToady: 'my multi', okay thanks
14:38 TimToady afk &
15:01 |jedai| joined #perl6
15:26 zamolxes joined #perl6
15:41 Tene_ joined #perl6
15:46 |jedai| joined #perl6
16:14 ChrisDavaz joined #perl6
16:19 masak rakudo: say 'does this work?'
16:19 p6eval rakudo 35948: OUTPUT«Parrot VM: PANIC: Out of mem!␤C file src/gc/memory.c, line 141␤Parrot file (not available), line (not available)␤␤We highly suggest you notify the Parrot team if you have not been working on␤Parrot.  Use parrotbug (located in parrot's root directory) or send an␤e-mail to
16:19 p6eval ..parrot-p...
16:26 rindolf joined #perl6
16:26 ivantis2 joined #perl6
16:27 ivantis2 left #perl6
16:33 masak looks like feather's memory is all used up.
16:36 |jedai| joined #perl6
16:43 gravity joined #perl6
16:45 |jedai| joined #perl6
16:51 sail0r joined #perl6
16:57 sail0r left #perl6
17:09 rabbits77 joined #perl6
17:09 rabbits77 left #perl6
17:26 |jedai| joined #perl6
17:36 duke_leto left #perl6
17:49 frew joined #perl6
17:50 frew TimToady: are you here?
17:52 pmurias @tell masak the evalbot runs on timtowtdi.org not on feather
17:52 lambdabot Consider it noted.
17:54 frew Well, does anyone if pack and unpack are really not exported or shouldn't be?
17:55 frew also: in the substr test substr(Int, Int) is the only multi (it seems) that gets tested.  Should we added substr(Int, StrPos) and substr(Int, StrLen)?
18:08 TimToady all functions not defined in the prelude need to be exported, and pack/unpack aren't methods
18:09 TimToady re substr, yes
18:11 ovid joined #perl6
18:11 ovid Hi everyone.
18:13 ovid Thinking about creating a "minimal" Test.pm which has the absolute fewest features necessary to run the spectest suite, but since there's talk about changing the testing system, I think this might be wasted effort. Thoughts?
18:16 pugs_svn r25016 | frew++ | Added named arguments to string tests
18:18 frew pugs: my StrLen $a = 3; "fREW".substr(2,$a);
18:18 p6eval pugs: RESULT«\"EW"»
18:18 frew pugs: my StrLen $a = 3; "fREW".substr(1,$a);
18:18 p6eval pugs: RESULT«\"REW"»
18:18 ovid frew: glad to see you've started adding stuff.  Thanks :)
18:18 frew my pleasure
18:19 frew thanks for your post
18:19 frew if you hadn't posted I never would have started
18:20 ovid Now go ahead and post to your journal about how easy it is to help being on the ground floor of creating a new language.  Not too many people can say that, but the Perl community makes is easy (particularly audrey++ with -ofun)
18:21 frew by the way, I know that each multi is actually a separate function.  Does that mean that for something like substr(Int, StrLen) which is entirely untested I should just copy paste all of the existing tests and run them on the other version of strlen?
18:21 frew ovid: Yeah, I will.  I just wanted to do a commit before I posted :-)
18:22 ovid The other versions do need to be explicitly tested.  It's not bothering to test "obvious" things which are the most embarrassing failures in my test suites.
18:22 pmurias joined #perl6
18:23 frew haha, well, it's a lot of tests, so it makes sense
18:23 ovid And while I hate copy/paste, due to Perl 6's more intelligently handling of arguments does sometimes make this an safer solution.  Now if only we had code coverage tools for this ... :)
18:23 frew I also noted that the [op] notation for reduce is untested
18:24 ovid "an safer solution"?  Sigh.  I'll learn to type one day.
18:24 frew eh, it's a waste of your time :-)
18:24 frew I tell my coworkers I can't even read unless it's in perl
18:26 frew ovid: I am adding tests for substr(Int, StrLen), should I also add substr(Int, StrPos) or is that good enough as it's (I think) the same as substr(Int, Int)?
18:27 ovid Hmm, I don't know the difference between StrLen and StrPos. The key is whether or not the multi-dispatch is dispatching to different mutlis internally, I would think.
18:27 frew yeah
18:27 frew pugs: "frew".substr(1, StrLen 2)
18:27 p6eval pugs: OUTPUT«*** No such subroutine: "&StrLen"␤    at /tmp/WbFBgnUCSV line 1, column 18-26␤»
18:29 ovid Where did you see "StrLen" and "StrPos"? I don't think those are types.
18:30 frew they are
18:30 frew watch
18:30 frew pugs: my StrLen $a = 3; "fREW".substr(1,$a);
18:30 p6eval pugs: RESULT«\"REW"»
18:30 frew pugs: my StrLen $a = 3; "fREW".substr(1,3);
18:30 p6eval pugs: RESULT«\"REW"»
18:30 frew wait
18:30 frew maybe not?
18:30 ovid And in any event, I don't think that declaring a type on a constant is legal, is it?
18:30 frew no
18:30 ovid perl6: say Int 2
18:30 frew I was just trying it
18:30 p6eval elf 25016: OUTPUT«Parse error in: /tmp/sHNp8Wuofa␤panic at line 1 column 0 (pos 0): Can't understand next input--giving up␤WHERE: say Int 2␤WHERE:/\<-- HERE␤  STD_red/prelude.rb:99:in `panic'␤  STD_red/std.rb:76:in `scan_unitstopper'␤  STD_red/std.rb:224:in `comp_unit'␤  STD_red/std.rb:210:in
18:30 p6eval ..`_UN...
18:30 p6eval ..pugs: OUTPUT«*** ␤    Unexpected "2"␤    expecting "=", "(", ":", operator or ","␤    at /tmp/otkj88S5gn line 1, column 9␤»
18:30 p6eval ..rakudo 35948: OUTPUT«Parrot VM: PANIC: Out of mem!␤C file src/gc/memory.c, line 141␤Parrot file (not available), line (not available)␤␤We highly suggest you notify the Parrot team if you have not been working on␤Parrot.  Use parrotbug (located in parrot's root directory) or send an␤e-mail to
18:30 p6eval ..parrot-p...
18:31 frew if you look at the generated pod for substr it has three method defs
18:31 ovid Also, I'm NOT an expert on Perl 6. :)
18:31 frew pugs: my StrPos $a = 3; "fREW".substr(1,$a);
18:31 p6eval pugs: RESULT«\"REW"»
18:31 frew pugs: my StrPos $a = 2; "fREW".substr(1,$a);
18:31 p6eval pugs: RESULT«\"RE"»
18:32 frew pugs: my StrPos $a = 2; "fREW".substr(2,$a);
18:32 p6eval pugs: RESULT«\"EW"»
18:32 frew pugs: my StrLen $a = 2; "fREW".substr(2,$a);
18:32 p6eval pugs: RESULT«\"EW"»
18:32 frew ok, well either that's wrong or the doc is wrong
18:32 frew or StrPos and StrLen don't mean what I think they mean
18:32 ovid I'll look at the pir source to see if I can make sense of that.  The POD looks strange to me.
18:33 aindilis joined #perl6
18:34 frew alright.  Yeah, I tried to look at some pir but I just couldn't follow it
18:34 ovid According to the pir (src/builtins/any-str.pir), the next arguments are just ints.
18:35 ovid (As far as I can tell)
18:35 frew ok, so the pod is wrong?
18:35 frew because either the pod needs to change or the pir and tests need to change
18:35 frew I think
18:36 TimToady I don't know if anyone actually implements the StrPos type
18:36 TimToady perl6: my StrPos $p = 3; say ($p+1).WHAT
18:36 frew are they supposed to or is that "dead spec"
18:37 p6eval elf 25016, pugs: OUTPUT«Int␤»
18:37 p6eval ..rakudo 35948: OUTPUT«Parrot VM: PANIC: Out of mem!␤C file src/gc/memory.c, line 141␤Parrot file (not available), line (not available)␤␤We highly suggest you notify the Parrot team if you have not been working on␤Parrot.  Use parrotbug (located in parrot's root directory) or send an␤e-mail to
18:37 p6eval ..parrot-p...
18:37 TimToady that ought to print StrPos, not Int
18:38 frew pugs: my $a = 3; say ($a+1).WHAT
18:38 p6eval pugs: OUTPUT«Int␤»
18:38 frew pugs: my StrLen $a = 3; say ($a+1).WHAT
18:38 p6eval pugs: OUTPUT«Int␤»
18:38 TimToady perl6: my NoneSuch $p = 3; say ($p+1).WHAT
18:38 p6eval elf 25016, pugs: OUTPUT«Int␤»
18:38 p6eval ..rakudo 35948: OUTPUT«Parrot VM: PANIC: Out of mem!␤C file src/gc/memory.c, line 141␤Parrot file (not available), line (not available)␤␤We highly suggest you notify the Parrot team if you have not been working on␤Parrot.  Use parrotbug (located in parrot's root directory) or send an␤e-mail to
18:38 p6eval ..parrot-p...
18:39 frew ok
18:39 TimToady nobody really has the types right yet...
18:39 frew so should I do the test for StrLen and StrPos anyway then?
18:39 TimToady yes
18:39 frew k
18:39 TimToady didn't I say that already?
18:40 frew Yeah, but I was under the impression that it was already in the system
18:40 frew and I thought if it weren't it might have been removed from the spec
18:42 TimToady 09:54 < frew> also: in the substr test substr(Int, Int) is the only multi (it seems) that gets tested.  Should we added substr(Int, StrPos) and substr(Int, StrLen)?
18:42 TimToady 10:08 <@TimToady> re substr, yes
18:42 frew sorry
18:42 vixey joined #Perl6
18:42 TimToady np
18:43 schmalbe joined #perl6
18:43 frew does a negative StrLen make sense?
18:43 TimToady yes
18:43 TimToady but not a negative StrPos
18:43 frew really?  Huh.  I would have though it were the other way around
18:44 TimToady on the other hand, code that assumes StrPos and StrLen are integers is probably wrong
18:44 TimToady you can't have a position in a string earlier than 0
18:44 TimToady but a StrLen is the difference of two StrPoses
18:44 frew I would have figured that it meant count from the end
18:44 TimToady and they can come in either order
18:44 frew ah
18:44 frew k
18:44 TimToady we don't do that in p6
18:45 TimToady not for array subscripts either
18:45 frew interesting choice
18:45 TimToady we use *-1 to count from the end
18:45 TimToady so we know explicitly that it was intended, and not accidental
18:45 frew so I say @foo[1]*-1 ?
18:45 Psyche^ joined #perl6
18:46 TimToady @foo[*-1]
18:46 lambdabot Unknown command, try @list
18:46 frew ah
18:46 frew k
18:46 TimToady * means "whatever"
18:46 TimToady which a subscript will interpret to mean, plug in the size of the dimension here
18:47 TimToady I oversimplify slightly
18:47 TimToady but the basic idea is that any operator can decide what * means when passed to it
18:48 TimToady so 1..* means one to whatever...
18:48 frew so is it reasonable for me to just test this stuff by giving int basted strlens?
18:48 frew based*
18:48 TimToady good question
18:49 TimToady it really depends on whether we ever allow strings with variable-length encodings
18:49 TimToady but we're moving toward a fixed width encoding by default, so maybe it's okay
18:49 frew so we aren't abstracting the character?
18:49 frew yeah
18:49 frew ok
18:49 frew so leave that on the burner for now then
18:50 TimToady biab &
18:53 jhorwitz joined #perl6
19:11 eternaleye joined #perl6
19:21 |jedai| joined #perl6
19:40 meppl good night
19:41 eternaleye joined #perl6
19:42 ovid joined #perl6
19:46 |jedai| joined #perl6
19:52 diakopter @tell mtnviewmark let me know if you haven't received the [original or resent] commit invite...
19:52 lambdabot Consider it noted.
19:58 kisu__ joined #perl6
20:02 archpollux joined #perl6
20:02 archpollux hi all
20:03 archpollux i'm trying to compile pugs and it says it can't find Data.FunctorM
20:03 archpollux http://cvs.haskell.org/Hugs/pages/libraries/base/Data-FunctorM.html says this module is deprecated and I can't really find it in my ghc6 installation
20:04 Matt-W I don't believe pugs has been worked on for some time
20:04 Matt-W so it's entirely possible it doesn't compile with recent ghc
20:04 frew what version of ghc?
20:05 archpollux 6.8.2
20:06 frew yeah, mine compiles fine with 6.8.2
20:06 archpollux is anything usable?
20:06 frew mine works totally perfectly
20:06 frew did you ./Configure.PL and ./Make.PL?
20:06 archpollux maybe i'm missing some extra packages
20:06 Matt-W hmm Data.FunctorM isn't in the ghc libraries docs
20:06 archpollux although docs say Data.FunctorM is in base
20:06 Matt-W interesting
20:07 frew are you using linux and if so what version?
20:07 archpollux yes, debian sid
20:07 archpollux packaging error you think?
20:07 frew well...it can't be THAT much different from ubuntu (what I am using(
20:07 frew maybe?
20:07 frew I kinda doubt it though
20:08 frew I'd google your error
20:08 archpollux hmmm
20:08 archpollux i am
20:08 frew it may be something common in the haskell world
20:08 frew of which I am not really a part :-)
20:08 diakopter archpollux: it's much more advisable to use the Pugs hackages
20:08 diakopter instead of the pugs source from svn.pugscode.org
20:08 archpollux diakopter: how do i do that?
20:08 mberends hmm, I also failed to build pugs on Debian. the ghc was 6.8.2.
20:08 diakopter Pugs is technically maintained outside of svn.pugscode.org now, from what I can tell
20:09 spooneybarger joined #perl6
20:09 diakopter the new Pugs hackage packages work with the latest release of ghc
20:09 frew note: 6.8.2 is not the latest ghc
20:09 diakopter 6.10.1
20:09 frew right
20:10 diakopter the new Pugs hackage packages work with ghc 6.10.1
20:10 frew I am just saying they have the same ghc that I do and pugs compiled fine for me
20:10 |jedai| joined #perl6
20:10 diakopter yeah, but many other users have lots of difficulty with it
20:11 frew are there plans to continue maintaining it after rakudo is complete?
20:11 diakopter 'complete' is very much a moving target for all implementations
20:11 frew haha, yeah, I know
20:11 frew I was just curious
20:12 archpollux i guess i'd better try rakudo instead
20:12 frew archpollux: well, pugs is way nicer to use
20:12 archpollux yeah, but since rakudo will become the standard(?), might as well use it
20:12 frew yeah
20:13 diakopter I think the fact the Pugs hackage packages are very often/recently updated points to its ongoing maintenance (and plans for it)
20:13 diakopter archpollux: no one implementation will be "standard", de jure nor de facto, probably.
20:13 frew ok
20:13 archpollux ok :)
20:13 archpollux official maybe?
20:13 diakopter esp. not official
20:13 diakopter the Language standards define the language
20:14 diakopter as expressed in the human-readable Synopses and in the perl6-readable test suite
20:14 archpollux i know
20:14 diakopter if an implementation doesn't match those, it's not (quite) Perl 6
20:15 archpollux yeah
20:16 archpollux i get it
20:16 diakopter but, as far as 'official' goes (according to the 'Perl' intellectual property right holder), rakudo is de facto (but allegedly not de jure) the only implementation funded
20:17 diakopter archpollux: see http://svn.pugscode.org/pugs/INSTALL for the recommended way to install pugs.
20:17 diakopter esp note the line: Cut here - Instructions below are outdated!
20:18 frew Does anyone here know why the  substr($str, 0, 5) = "gloop" is in substr.t twice?
20:19 frew One has #?rakudo todo "substr as lvalue" before it and the other has #?rakudo "exception"
20:21 diakopter based on the different notes, I'd surmise there are two separate difficulties rakudo has with it?
20:21 diakopter dunno
20:21 frew hm
20:21 frew it's exactly the same code in the two
20:21 frew even the strings are the same
20:26 pmurias diakopter: ruoso received a grant for smop
20:26 pmurias diakopter: hi
20:30 pmurias diakopter: what is your most recent smop building obstacle?
20:32 |jedai| joined #perl6
20:37 eternaleye joined #perl6
20:44 frew Anyone here know if it's valid behaviour for strlen to get a StrPos that's before the initial integer?
20:46 Matt-W What's the best way to write a regex which matches a line of anything at all which does NOT start with a .
20:47 frew Couldn't you do something like: /^[^\.].*/ ?
20:47 Matt-W sure, in perl 5
20:47 frew ah, ok, I don't know perl 6 grammars
20:49 mberends Matt-W: this one matches non comment lines: / ^ <![#]> /
20:50 Matt-W aah so is that a negated character class?
20:50 mberends afaik
20:50 Matt-W cool
20:51 diakopter pmurias: oh yeah
20:53 ejs joined #perl6
20:53 diakopter pmurias: well, I gave up on mingw,cmd.exe because of the last thing I mentioned to you.. I tried it in MSYS (similar to cygwin), but too much Makefile tweaking was necessary.
20:53 diakopter so now I guess I'll just try good old cygwin
20:54 ruoso joined #perl6
20:55 diakopter ruoso: hi
20:55 diakopter pmurias: what is mildew?
21:18 pugs_svn r25017 | masak++ | [S29] documented .i method in Num
21:19 araujo joined #perl6
21:22 pmurias diakopter: mildew is the the p6 to m0ld compiler (it's written in p5 and uses STD)
21:23 diakopter pmurias: oh, neat
21:23 diakopter pmurias: I'll let you know soon how the smop toolset building goes on cygwin
21:24 diakopter pmurias: I think I was just trying to make it difficult on myself(/others?) by using mingw&cmd.exe and MSYS
21:26 pmurias cygwin is supposed to be compatible with linux right?
21:29 justatheory joined #perl6
21:29 diakopter yeah, the biggest difference between it and mingw/msys is that cygwin doesn't handle windows-style filesystem paths and does handle *n*x style filesystem paths, while vice versa for mingw on cmd.exe (incl Strawberry Perl)
21:33 diakopter MSYS is a fork of cygwin that tries to change fewer things from windows than cygwin (it still builds binaries linked to a cygwin-like .dll), while the mingw32 environment doesn't need the cygwin .dll to run from a cmd.exe shell
21:33 diakopter see http://www.mingw.org/
21:51 |jedai| joined #perl6
21:52 c9s_ joined #perl6
22:11 pmurias ruoso: i'm considering writing a lowlevel signature which would on the RI, and a lowlevel multi which wouldn't look through the lexicals scopes (but Multi could extract variants from after bootstrap) so we could boostrap much more easily
22:18 ovid joined #perl6
22:21 ovid joined #perl6
22:25 SamB joined #perl6
22:50 ruoso pmurias, the adhoc signature already can use the ri comparator...
22:51 spx2 joined #perl6
22:53 pmurias ruoso: hi
22:55 mtnviewmark joined #perl6
22:59 mtnviewmark std: $a = \($b X f($c))
22:59 lambdabot mtnviewmark: You have 1 new message. '/msg lambdabot @messages' to read it.
22:59 p6eval std 25017: OUTPUT«Unknown routines:␤     f called at 1 ␤00:05 86m␤»
22:59 pmurias ruoso: what does the Multi role look like?
23:00 pmurias ruoso: maybe we could have prefix:<=>,infix:<+> as CCodes which would be than replaced in the Prelude by proper multis
23:00 frew Anyone know if doing substr(3, StrPos) with StrPos = 2 is valid?
23:00 |jedai| joined #perl6
23:09 mtnviewmark I'm wondering if \ is really an operator any more....
23:14 Limbic_Region joined #perl6
23:14 mtnviewmark_ joined #perl6
23:28 diakopter mtnviewmark_: did you get the commitbit invitation?
23:28 lambdabot diakopter: You have 1 new message. '/msg lambdabot @messages' to read it.
23:28 mtnviewmark_ yes - thanks
23:29 mtnviewmark_ though TimToady beat me to applying my fix
23:29 mtnviewmark_ :-)
23:35 mtnviewmark_ hmmm?
23:36 mtnviewmark_ ah...
23:40 ruoso pmurias, the idea is having infix:<+> implemented as a Multi, as soon as we have Multi running
23:40 |jedai| joined #perl6
23:40 ruoso pmurias, I think we can delay supporting unary ops as multi for after the compiler bootstrap
23:41 ruoso for now we consider prefix, postfix and postcircumfix as methods
23:41 ruoso and infix as multi sub
23:41 ruoso the first candidate for infix:<+> will have the (int,int) signature
23:42 ruoso so we can sum native ints
23:55 pmurias ruoso: what i don't like that if we do thinks as infix:<+> and prefix:<=> as methods during bootstrap we can't easily hide it after bootstrap
23:56 pmurias s1_array_iterator.sm0p even uses .postfix:<++>
23:57 frew 46 13 52 7 63 19
23:59 kulp joined #perl6

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

Perl 6 | Reference Documentation | Rakudo