Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2011-11-11

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:04 flussence http://forums.gentoo.org/viewtopic-t-901474.html
00:04 flussence whoops, ww
00:09 molaf_ joined #perl6
00:13 diakopter [Coke]: the problem with the first idea is that redo/next/last lose their meaning inside loops (usually redo/next/last are enclosed in conditional blocks after all)
00:13 diakopter I like the second idea
00:17 dalek rakudo/nom: ef4702d | Coke++ | t/spectest.data:
00:17 dalek rakudo/nom: track failure modes
00:17 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/ef4702d5a6
00:29 clairvy joined #perl6
00:37 abercrombie joined #perl6
00:48 localhost joined #perl6
01:08 IngisKahn joined #perl6
01:10 replore joined #perl6
01:23 envi_ joined #perl6
01:33 shachaf preflex: seen sorear
01:33 preflex sorear was last seen on #perl6 9 hours, 25 minutes and 11 seconds ago, saying: pir::setprop(...)
01:38 ab5tract joined #perl6
01:39 fridim_ joined #perl6
01:42 hypolin joined #perl6
01:59 whiteknight joined #perl6
02:02 dalek 6model: 80d077d | diakopter++ | lua/ (7 files):
02:02 dalek 6model: decent perf improvements
02:02 dalek 6model: review: https://github.com/diakopte​r/6model/commit/80d077dc21
02:28 alc joined #perl6
02:30 cooper joined #perl6
03:14 simcop2387 joined #perl6
03:28 satyavvd joined #perl6
03:29 wolfman2000 joined #perl6
03:42 cognominal I have to grok the sigiless silliness.
03:46 diakopter you have *yet to?
03:49 cognominal indeed.
03:54 mkramer joined #perl6
04:04 buubot_backup joined #perl6
04:20 f00li5h joined #perl6
04:20 kfo joined #perl6
04:20 cooper joined #perl6
04:27 sorear shachaf: hello!
04:27 sorear good * #perl6
04:27 shachaf sorear: Happy birthday!
04:28 sorear Thanks.
04:29 sorear niecza: say "hi"
04:29 p6eval niecza v11-22-gbebf7a0: OUTPUT«hi␤»
04:29 sorear \o/ p6eval is back
04:38 xensu joined #perl6
04:41 jaldhar joined #perl6
04:47 buubot_backup joined #perl6
05:06 diakopter brrr
05:13 orafu joined #perl6
05:17 [Coke] nom: say "nom: say 'nom'"
05:17 p6eval nom ef4702: OUTPUT«nom: say 'nom'␤»
05:19 buubot_backup joined #perl6
05:30 huf joined #perl6
05:55 moritz happy sorear++
05:56 sunnavy joined #perl6
06:04 moritz [Coke]: at your convenience, could you please add https://gist.github.com/1340539 to the top of rakudo's tools/build/Makefile.in and see if it still builds after a reconfigure? thank you
06:07 alim joined #perl6
06:07 mkramer left #perl6
06:15 moritz [Coke]: on windows that is
06:27 sorear moritz: thanks
06:30 sorear TimToady: do we have a good way to quantify the completeness of Unicode support?
06:30 sorear or just S05 in roast hmm
06:48 overrosy joined #perl6
06:49 daniel-s joined #perl6
07:05 icovnik joined #perl6
07:09 sunnavy joined #perl6
07:30 dual joined #perl6
07:39 zby_home joined #perl6
07:43 robertbrook joined #perl6
07:47 mkramer1 joined #perl6
07:56 replore_ joined #perl6
08:03 wtw joined #perl6
08:14 f00li5h joined #perl6
08:28 mj41 joined #perl6
08:29 f00li5h joined #perl6
08:55 alim joined #perl6
08:55 buubot_backup joined #perl6
08:59 cosimo joined #perl6
09:03 f00li5h joined #perl6
09:06 overrosy joined #perl6
09:19 overrosy joined #perl6
09:23 mishin joined #perl6
09:29 Trashlord joined #perl6
09:40 tadzik good morning #perl6
09:40 tadzik happy birthday sorear!
09:53 ab5tract joined #perl6
10:03 mkramer joined #perl6
10:03 mkramer left #perl6
10:28 moritz I have some trouble understanding how native ints and Int mix
10:29 moritz in particular, if I write   1233 * 456,  are these two numbers native ints?
10:29 moritz or can they be used both as native ints and Int, as rakudo does?
10:29 moritz trouble is that if they are interpreted as native ints, and are a bit larger than in my example, they can overflow
10:30 moritz erm, not they, but the result of the operation
10:48 Trashlord joined #perl6
11:04 moritz nom: pir::say pir::typeof__SP(3)
11:04 p6eval nom ef4702: OUTPUT«Int␤»
11:07 mkramer1 joined #perl6
11:24 moritz jnthn++ # factoring SymbolTable (and its usage in the actions) very nicely
11:25 moritz I have hopes that the codegen changes for the bigint things doesn't become too ugly
11:27 daxim joined #perl6
11:35 domidumont1 joined #perl6
11:52 bluescreen10 joined #perl6
11:55 pmurias joined #perl6
11:59 Trashlord joined #perl6
12:10 pmurias joined #perl6
12:16 Psyche^ joined #perl6
12:26 fridim_ joined #perl6
12:29 sftp joined #perl6
12:31 clairvy joined #perl6
12:37 bazqux joined #perl6
12:37 sunnavy joined #perl6
12:38 sunnavy joined #perl6
12:38 pmurias joined #perl6
12:40 sunnavy joined #perl6
12:41 Trashlord joined #perl6
12:47 dalek rakudo/bigint: 29eeaf8 | moritz++ | src/Perl6/ (2 files):
12:47 dalek rakudo/bigint: start to generate bigints in the actions.
12:47 dalek rakudo/bigint:
12:47 dalek rakudo/bigint: Does not compile the setting yet
12:47 dalek rakudo/bigint: review: https://github.com/rakudo/rakudo/commit/29eeaf8d42
12:47 dalek rakudo/bigint: e2c2af5 | moritz++ | src/Perl6/Actions.pm:
12:47 dalek rakudo/bigint: switch radcalc to bigints
12:47 dalek rakudo/bigint:
12:47 dalek rakudo/bigint: now dies in quote_escape:sym<hex>
12:48 dalek rakudo/bigint: review: https://github.com/rakudo/rakudo/commit/e2c2af5ff4
12:49 moritz "get_integer() not implemented in class 'Int'"
12:49 moritz that error message has a certain irony
12:50 pmurias joined #perl6
12:50 clairvy joined #perl6
12:58 pmurias joined #perl6
13:08 Kivutarrr joined #perl6
13:09 bbkr joined #perl6
13:10 dalek nqp/bigint: 05d6ab2 | moritz++ | / (3 files):
13:10 dalek nqp/bigint: add nqp::isbig_I op, and nqp:: variants for bigint <-> str conversion
13:10 dalek nqp/bigint: review: https://github.com/perl6/nqp/commit/05d6ab2ffa
13:10 dalek nqp/bigint: 9647ef9 | moritz++ | src/HLL/Actions.pm:
13:10 dalek nqp/bigint: make ints_to_string a method, so that it can be overridden in subclasses
13:10 dalek nqp/bigint: review: https://github.com/perl6/nqp/commit/9647ef9ffa
13:10 mkramer joined #perl6
13:13 mkramer left #perl6
13:14 pmurias joined #perl6
13:20 Lothar joined #perl6
13:24 wk joined #perl6
13:25 dalek rakudo/bigint: e68268b | moritz++ | src/Perl6/Actions.pm:
13:25 dalek rakudo/bigint: fix hex escapes; restore compilation of the setting
13:25 dalek rakudo/bigint: review: https://github.com/rakudo/rakudo/commit/e68268b7f4
13:32 mj41 joined #perl6
13:37 pmurias joined #perl6
13:43 jaldhar joined #perl6
13:44 pmurias joined #perl6
13:54 dalek rakudo/bigint: b147776 | moritz++ | src/Perl6/SymbolTable.pm:
13:54 dalek rakudo/bigint: move bigint serialization to the proper place
13:54 dalek rakudo/bigint: review: https://github.com/rakudo/rakudo/commit/b147776373
13:55 smash joined #perl6
13:55 smash hello everyone
14:01 moritz hi smash
14:01 moritz nom: say 9999999999999999999999999 + 1
14:01 p6eval nom ef4702: OUTPUT«Use of uninitialized value in string context␤Use of uninitialized value in string context␤===SORRY!===␤error:imcc:eval_ins: op 'add_i_n_i' not found␤␤       in file '(file unknown)' line 58506025␤»
14:01 moritz huh :-)
14:01 moritz b: say 9999999999999999999999999 + 1
14:01 p6eval b 1b7dd1: OUTPUT«1.59089797835941e+18␤»
14:01 moritz locally:
14:01 moritz $ ./perl6 -e 'say 9999999999999999999999999 + 1'
14:01 moritz 10000000000000000000000000
14:02 moritz there's still a decent degree of brokenness in that branch
14:03 moritz but at least the codegen for ordinary int literals seems fine
14:03 moritz nom: say 9999 ** 10
14:03 p6eval nom ef4702: OUTPUT«-9223372036854775808␤»
14:06 mj41 joined #perl6
14:09 vmspb joined #perl6
14:11 pmurias joined #perl6
14:13 Trashlord joined #perl6
14:24 bazqux left #perl6
14:27 thou joined #perl6
14:28 tadzik moritz++
14:31 pmurias joined #perl6
14:38 pmurias joined #perl6
14:40 Trashlord joined #perl6
14:45 sayu joined #perl6
14:47 pmurias joined #perl6
14:50 pmurias_ joined #perl6
14:50 quicoju joined #perl6
15:03 moritz the radcalc code looks a bit weird/redundant
15:03 moritz the cases that creates a Rat, that is
15:04 pmurias joined #perl6
15:04 moritz return $*ST.add_constant('Rat', 'type_new',
15:04 moritz $*ST.add_numeric_constant('Int', $iresult)<compile_time_value>,
15:04 moritz $*ST.add_numeric_constant('Int', $fdivide)<compile_time_value>,
15:04 djanatyn joined #perl6
15:04 moritz :nocache(1)
15:04 moritz );
15:04 Tene joined #perl6
15:04 Tene joined #perl6
15:05 moritz why the the add_numeric_constant calls when the result is discarded?
15:06 moritz and it seems the Rat case is special-cased anyway to serialize the nu and de
15:06 tadzik what do you mean: discarded?
15:07 moritz I mean that only $thing<compile_time_value> is passed on to $*ST.add_constant
15:07 moritz but $thing (return value from add_numeric_constant) isn't used
15:07 moritz but $iresult and $fdivide already are compile-time values
15:08 tadzik but it's in the symboltable
15:08 tadzik the 'call add_constant and use only the <compile_time_value>' seems quite common in Actions, methinks
15:08 tadzik hmm, I may see your point
15:10 moritz $ST.add_constant special-cases the codegen for the arguments when the type is 'Rat'
15:11 pmurias joined #perl6
15:12 tadzik oh
15:14 moritz and the trouble with that special case is that it assumes that Int round-trips on unboxing to int, and then boxing again
15:14 moritz which is broken by bigints
15:14 moritz which is why Rat literals for big numbers are just as broken in the bigint branch as in nom
15:14 moritz nom: say 3.14444444444444444444444444444444444
15:14 p6eval nom ef4702: OUTPUT«===SORRY!===␤bigint_get_long: number too big␤»
15:15 moritz ok, broken in a different way :-)
15:15 moritz $ ./perl6 -e 'say 3.14444444444444444444444444444444444'
15:15 moritz Segmentation fault
15:15 tadzik I completely don't understand grammars in nom
15:15 moritz let's wait 'til after the rebuild
15:16 tadzik b: https://gist.github.com/1358234
15:16 p6eval b 1b7dd1: OUTPUT«keys: ("zebra")␤elems: 3␤elems2: 1␤"whatever"␤»
15:16 tadzik nom: https://gist.github.com/1358234
15:16 p6eval nom ef4702: OUTPUT«keys: ().list␤elems: 1␤elems2: 0␤"whatever"␤»
15:16 pmurias_ joined #perl6
15:16 tadzik seems that captures are lost more often than we thought
15:17 moritz try $/.list.keys
15:17 moritz erm
15:17 moritz $/.hash.keys
15:18 tadzik still ()
15:19 Trashlord joined #perl6
15:24 pmurias joined #perl6
15:28 moritz the bigints + rat business is rather fiddly :/
15:29 moritz when I call a nqp::something_I() op with something that isn't a bigint, it segfaults
15:38 pmurias joined #perl6
15:45 moritz jnthn: http://moritz.faui2k3.org/tmp/rat-bigint.patch on the bigint branch (needs newest nqp/bigint) makes the arguments to Rat.new() come out as Mu instead of Int while compiling the setting, and I don't understand why. Maybe you can take a look...
16:00 MayDaniel joined #perl6
16:06 pmurias joined #perl6
16:13 quicoju joined #perl6
16:23 pmurias joined #perl6
16:34 pmurias joined #perl6
16:43 quicoju joined #perl6
17:15 quicoju joined #perl6
17:25 quicoju left #perl6
17:32 IngisKahn joined #perl6
17:32 pmurias joined #perl6
17:36 dju joined #perl6
17:43 pmurias joined #perl6
17:43 phenny joined #perl6
17:54 moritz nom: BEGIN my $*QSIGIL = 5; $y
17:54 p6eval nom ef4702: OUTPUT«(signal SEGV)»
17:55 moritz oops.
17:55 simcop2387 joined #perl6
17:55 tty234 joined #perl6
17:57 Chillance joined #perl6
17:58 molaf joined #perl6
18:00 pmurias joined #perl6
18:03 dju joined #perl6
18:03 cognominal_ joined #perl6
18:05 paly joined #perl6
18:08 pmurias joined #perl6
18:18 paly left #perl6
18:21 pmurias joined #perl6
18:26 dalek rakudo/bigint: 3d97eda | moritz++ | src/core/Int.pm:
18:26 dalek rakudo/bigint: use new nqp::pow_I opcode
18:26 dalek rakudo/bigint: review: https://github.com/rakudo/rakudo/commit/3d97eda75a
18:26 dalek rakudo/bigint: 7c6a4a6 | moritz++ | src/Perl6/Actions.pm:
18:26 dalek rakudo/bigint: use add_numeric_constant for numeric constant
18:26 dalek rakudo/bigint: review: https://github.com/rakudo/rakudo/commit/7c6a4a6cb6
18:26 dalek rakudo/bigint: 933a1a5 | moritz++ | src/Perl6/Actions.pm:
18:26 dalek rakudo/bigint: document some assumptions; remove unused variable
18:26 dalek rakudo/bigint:
18:26 dalek rakudo/bigint: no functional changes
18:26 dalek rakudo/bigint: review: https://github.com/rakudo/rakudo/commit/933a1a52a5
18:28 pmurias joined #perl6
18:29 moritz perl6: say 9 ** -10
18:29 p6eval niecza v11-22-gbebf7a0: OUTPUT«1/3486784401␤»
18:29 p6eval ..rakudo ef4702: OUTPUT«2.86797199079244e-10␤»
18:29 p6eval ..pugs b927740: OUTPUT«*** ␤    Unexpected "-"␤    at /tmp/d5IRG5jOst line 1, column 10␤»
18:33 bluescreen100 joined #perl6
18:34 pmurias joined #perl6
18:36 moritz infix ** seems to work nicely in the bigint branch
18:37 moritz now if I could only get these f#### Rat literals working...
18:37 bluescreen10 joined #perl6
18:40 dju joined #perl6
18:41 pmurias joined #perl6
18:42 imarcusthis joined #perl6
18:49 pmurias joined #perl6
19:01 pmurias joined #perl6
19:05 M_o_C joined #perl6
19:06 nebuchadnezzar joined #perl6
19:07 pmurias joined #perl6
19:10 wolfman2000 joined #perl6
19:12 moritz nom: nqp::say(my $x)
19:12 p6eval nom ef4702: OUTPUT«Use of uninitialized value in string context␤␤»
19:12 moritz mqp: say(my $x)
19:12 moritz nqp: say(my $x)
19:12 p6eval nqp: OUTPUT«␤»
19:13 clsn nom: "e u a u e u a" ~~ /:sigspace ("a") ([<[aeiou]> ]+)$/
19:13 p6eval nom ef4702:  ( no output )
19:14 clsn nom: say ("e u a u e u a" ~~ /:sigspace ("a") ([<[aeiou]> ]+)$/)
19:14 p6eval nom ef4702: OUTPUT«=> < a u e u a>␤ 0 => <a>␤ 1 => <u e u a>␤␤»
19:14 clsn nom: say ("e u a u e u a" ~~ /:sigspace .("a") ([<[aeiou]> ]+)$/)
19:14 p6eval nom ef4702: OUTPUT«#<failed match>␤»
19:14 clsn Does that make sense to anyone?  The only difference was adding a . before the ("a"), and if you look at the prior match, there IS stuff before it.
19:15 clsn std: say ("e u a u e u a" ~~ /:sigspace ("a") ([<[aeiou]> ]+)$/)
19:15 p6eval std be1f10e: OUTPUT«Potential difficulties:â�¤  [<[aeiou]> ] appears to be an old-school character class; please use <[<[aeiou]>\x20]> if youâ�¤    mean a character class, or quote it like '<[aeiou]> ' to matchâ�¤    string as a unit at /tmp/Olyn9W30q8 line 1:â�¤------> [32me u a" ~~ /:sigspac…
19:15 moritz clsn: it seems that it doesn't backtrack when it should
19:15 clsn Yeah.  It gets weirder:
19:16 clsn nom: say ("e u a u e u a" ~~ /:sigspace .?("a") ([<[aeiou]> ]+)$/)
19:16 p6eval nom ef4702: OUTPUT«=> < a u e u a>␤ 0 => <a>␤ 1 => <u e u a>␤␤»
19:16 clsn But
19:16 clsn nom: say ("e u a u e u a" ~~ /:sigspace (.?)("a") ([<[aeiou]> ]+)$/)
19:16 p6eval nom ef4702: OUTPUT«#<failed match>␤»
19:16 clsn So it fails *only* if you're trying to capture that part.
19:16 sorear niecza: say(my $x) # is this entirely wrong, then?
19:16 p6eval niecza v11-22-gbebf7a0: OUTPUT«Potential difficulties:â�¤  $x is declared but not used at /tmp/Z_dLBnm2XM line 1:â�¤------> [32msay(my [33mâ��[31m$x) # is this entirely wrong, then?[0mâ�¤â�¤Any()â�¤Â»
19:16 moritz so another instance of "backtracking over capures wrongly"
19:17 moritz erm
19:17 moritz modulo English
19:17 moritz sorear: not at all
19:17 TimToady niecza: say ("e u a u e u a" ~~ /:sigspace (.?)("a") ([<[aeiou]> ]+)$/)
19:17 p6eval niecza v11-22-gbebf7a0: OUTPUT«#<match from(3) to(13) text( a u e u a) pos([#<match from(4) to(4) text() pos([].list) named({}.hash)>, #<match from(4) to(5) text(a) pos([].list) named({}.hash)>, #<match from(6) to(13) text(u e u a) pos([].list) named({}.hash)>].list) named({}.hash)>␤»
19:17 pmurias joined #perl6
19:17 clsn Is this stuff known, or worth sending in?
19:17 TimToady niecza: say ("e u a u e u a" ~~ /:sigspace .("a") ([<[aeiou]> ]+)$/)
19:17 p6eval niecza v11-22-gbebf7a0: OUTPUT«Match()␤»
19:17 moritz sorear: I've only tested nqp and nom with pir::say
19:17 * sorear needs to invent a less verbose syntax for Match.perl
19:17 moritz clsn: worth reporting
19:17 moritz sorear: for Match.gist at least
19:17 sorear ...right that's what I meant :|
19:18 clsn Thanks.  I live in deathly fear of sending in an extraneous bug report...
19:18 moritz clsn: don't be. We sometimes get duplicate bug reports, and they don't kill us
19:18 moritz clsn: the search facility of rt.perl.org sucks, so it's inevitable
19:19 moritz and with > 500 tickets it's simply impossible to track in your head what's submitted and what not
19:19 clsn OK.  Thanks for the encouragement.
19:20 TimToady niecza: say ("e ! a u e u a" ~~ /:sigspace .("a") ([<[aeiou]> ]+)$/)
19:20 p6eval niecza v11-22-gbebf7a0: OUTPUT«Match()␤»
19:21 TimToady niecza: say ("e !!a u e u a" ~~ /:sigspace .("a") ([<[aeiou]> ]+)$/)
19:21 p6eval niecza v11-22-gbebf7a0: OUTPUT«#<match from(3) to(13) text(!a u e u a) pos([#<match from(4) to(5) text(a) pos([].list) named({}.hash)>, #<match from(6) to(13) text(u e u a) pos([].list) named({}.hash)>].list) named({}.hash)>␤»
19:21 TimToady this is arguably correct behavior for bare .
19:21 TimToady if <ws> matches real ws it probably should not match '' on either end of it
19:22 clsn I was just looking at that.  using ". " instead of "." works... Is . not allowed to match space under :sigspace?
19:23 TimToady that's not the problem
19:23 moritz nom: say :10<3*10**3>
19:23 p6eval nom ef4702: OUTPUT«3000␤»
19:23 moritz nom: say :10<3*10**3>.WHAT
19:23 p6eval nom ef4702: OUTPUT«Num()␤»
19:23 TimToady <ws> matches one way or the other, but does not imply a backtrack inside it
19:24 moritz TimToady: should that prodcue a Num (in analogy to 3e3)?
19:24 moritz or an Int instead?
19:25 moritz and :10<3.0*10**3>? Rat? Num? Int?
19:25 TimToady S02:3287
19:28 moritz so even :10<0.1*10**1> produces an Int
19:28 TimToady according to current spec, yes
19:29 sorear TimToady: iirc, we want <.ws> <.ws> to mean the same thing as <.ws>
19:29 TimToady well, sure, since you can put two spaces in a row into sigspace patterns pretty easily
19:30 TimToady std uses memos to handle that, generally
19:31 sorear yeah, just saying that we need <.ws> to match "" on the _right_ side of "real ws"
19:31 TimToady sure, but it's still not backtracking either of them
19:31 clsn Does the space after the :sigspace adverb count as a <.ws> space?  I would expect not.
19:31 TimToady it currently does, though we've considered changing it
19:32 TimToady it would make some things easier, and also harder to explain :)
19:32 clsn In that case, the problems I'm seeing do make some sense, but then how does one make a :sigspace pattern that does not start with <.ws>?
19:32 TimToady put the :s after what you want to match without it, for one
19:33 TimToady or use an unspace
19:33 TimToady but in general, it would help rules participating in LTM if we changed it to ignore ws before the first subtoken
19:33 TimToady STD has a bunch of token decls with :s that could just be rules if that were the case
19:34 TimToady assuming that the 'ignore ws after :s' also applies to the implicit :s of "rule"
19:35 TimToady it would be a sane default, and one can always force it the other way with [ ] or <ws> if needed
19:35 clsn (these matches worked differently in past rakudos, btw, but if the current behavior can be claimed to be correct that isn't so important a point.)
19:35 TimToady but as I said, the only thing preventing it that I can see is that it'd be harder to explain
19:36 clsn I don't know; that the adverb has to be delimited by whitespace (which doesn't count) seems pretty intuitive to me.
19:36 TimToady I'd also note that the initial whitespaces in *any* alternation should probably be ignored, to keep LTM sane
19:36 TimToady I think std and niecza do this implicitly without telling anyone in any case
19:38 TimToady when you write a rule { stuff [ a | b | c ] } it really turns into rule { stuff [a |b |c ] }
19:38 TimToady it might only do that if there's ws outside the []; don't recall offhand
19:39 TimToady so perhaps the actual rule we should advertize is that sigspace will be ignored anywhere something can be used as an alternative under LTM
19:39 bluescreen10 joined #perl6
19:39 TimToady and since any token or rule could in theory be used in such an alternation, initial sigspace there is ignored
19:40 clsn Can you use an unspace inside a rule, btw?  I tried putting a backslash after the :s and it didn't work.  (putting the :s after the first element did)
19:41 TimToady there is potentially some ambiguity there, so may be outlawed unspace where it looks like a quoted space
19:41 TimToady std: / foo\ bar /
19:41 p6eval std be1f10e: OUTPUT«[31m===[0mSORRY![31m===[0m�No unspace allowed in regex; if you meant to match the literal character, please enclose in single quotes (' ') or use a backslashed form like \x20 at /tmp/Yg2saDkZHQ line 1:�------> [32m/ foo\[33m�[31m bar /[0m�Parse failed�FAILED …
19:41 TimToady heh, doesn't say what to do if you wanted unspace
19:42 TimToady so nevermind about that suggestion; I'm just going senile (hopefully slowly)
19:42 clsn OK, fair enough. :)
19:42 TimToady well, there's always [:!s   ]
19:42 TimToady std: / foo[:!s   ]bar /
19:43 p6eval std be1f10e: OUTPUT«ok 00:01 120m␤»
19:43 TimToady std: / foo#`(   )bar /
19:43 p6eval std be1f10e: OUTPUT«ok 00:01 120m␤»
19:43 TimToady there's embedded comments too
19:43 clsn Turns out that in the original case I was working with, I actually had /:sigspace ^.../, i.e. search anchored at the head of the string, which natually would always fail when that first space is counted!
19:43 TimToady yes, another argument for ignoring initial ws
19:43 pmurias joined #perl6
19:44 TimToady I think I'll spec it that way and see who panics this tie
19:45 diakopter pmurias: hi
19:45 clsn ok.
19:49 clsn nom: "e u a u e u a" ~~ /:sigspace^.*?("a") ([<[aeiou]> ]+)$/
19:49 p6eval nom ef4702:  ( no output )
19:49 clsn nom: say ("e u a u e u a" ~~ /:sigspace^.*?("a") ([<[aeiou]> ]+)$/)
19:49 p6eval nom ef4702: OUTPUT«=> <e u a u e u a>␤ 0 => <a>␤ 1 => <u e u a>␤␤»
19:49 clsn nom: say ("e u a u e u a" ~~ /:sigspace^(.*?)("a") ([<[aeiou]> ]+)$/)
19:49 p6eval nom ef4702: OUTPUT«#<failed match>␤»
19:50 clsn Still a problem that the capture parens make it fail.
19:52 dalek 6model: c52987f | diakopter++ | lua/ (3 files):
19:52 dalek 6model: minor improvements
19:52 dalek 6model: review: https://github.com/diakopte​r/6model/commit/c52987fcc5
19:55 clsn Looks like I can do without that capture in my single perl6 program... Now once the recursion thingy is fixed it will work again.
19:56 wk joined #perl6
19:57 dalek specs: d7e1a70 | larry++ | S05-regex.pod:
19:57 dalek specs: generalize rule relating sigspace to LTM
19:57 dalek specs: review: https://github.com/perl6/specs/commit/d7e1a70d86
19:58 TimToady this spec change means that much of STD is now wrongish :)
19:59 TimToady sorear: ^^
20:00 * TimToady tries hard to avoid the "But we already have 11 users" syndrome  :)
20:01 TimToady though we should not have much code depending on ws being significant at the front of rules, except maybe the TOP
20:01 TimToady where we might need an extra <.ws> to get LTM started up right
20:02 buubot_backup joined #perl6
20:02 TimToady once we've fixed this, we can then relax our token { :s } instances to mere rules
20:04 dalek rakudo/bigint: 3014678 | moritz++ | src/Perl6/Actions.pm:
20:04 dalek rakudo/bigint: fix calling of radcalc for radix literals; make them produce the right type, I hope
20:04 dalek rakudo/bigint: review: https://github.com/rakudo/rakudo/commit/3014678713
20:06 mkramer joined #perl6
20:06 mkramer left #perl6
20:10 sftp_ joined #perl6
20:13 dalek 6model: 66ccb5f | diakopter++ | lua/compiler/Makefile:
20:13 dalek 6model: Makefile oopsie
20:13 dalek 6model: review: https://github.com/diakopte​r/6model/commit/66ccb5f10f
20:14 pmurias joined #perl6
20:19 jaldhar joined #perl6
20:20 pmurias joined #perl6
20:23 TimToady oh, and clsn++ for reminding me that I wanted to do that...
20:24 clsn Thanks!
20:26 ksi joined #perl6
20:29 preflex_ joined #perl6
20:30 TimToady we might simplify it further and say that we look for significant whitespace only after an explicit matcher, never after declarations or syntactic functors like brackets
20:32 TimToady a quantified atom would count as a matcher for this, presumably
20:33 jaldhar joined #perl6
20:33 TimToady this might simplify both the semantics and the teaching
20:34 TimToady above I use "declaration" to mean things like :my and :sigspace, not in the declarational sense we use when discussing LTM
20:34 TimToady in rule { 'foo' } the 'foo' is declarational but not a declaration :)
20:34 sorear but metachar:sym<[ ]> is a quantified atom
20:34 sorear so is metachar:p6adv
20:35 cooper joined #perl6
20:35 cooper joined #perl6
20:35 TimToady true, so just the opening [ is exempt
20:36 TimToady as a degenerate case rule {'' ... } would give the current semantics
20:37 TimToady I think this simplification can also cut down on some of the <ws> pressure
20:38 TimToady and clarify the semantics of ws around ** and %
20:38 TimToady that is, we could just make those follow the same rule, and not special-case them
20:39 TimToady as we don now
20:39 TimToady *do
20:39 TimToady as for p5adv, we'd have to rethink that one, I imagine
20:41 TimToady a lexical scope might have to eat the initial ones explicitly
20:41 sorear I think we have :my as a quantified atom too
20:41 TimToady or normspace eats them
20:42 TimToady but this seems like a good simplification to me, and worth a little agony
20:42 thou joined #perl6
20:46 TimToady maybe it's just a lexer state, and any real matcher enables a 1-shot sigspace
20:47 TimToady well, wouldn't be lazy, rather a use-it-or-lose-it
20:47 TimToady but maybe that's just syntax
20:49 * TimToady -> catfood acquisition mode &
20:52 _jaldhar joined #perl6
20:52 Ingis joined #perl6
20:59 pmurias joined #perl6
21:04 vmspb joined #perl6
21:04 PerlJam That sigspace change seems useful but it also looks like it has a small gotcha:    token foo { :s [ foo | bar | baz ] ... }    # did the sigspace do its job or get ignored?
21:05 ethndbst joined #perl6
21:05 ethndbst joined #perl6
21:06 pmurias joined #perl6
21:08 am0c joined #perl6
21:15 pmurias joined #perl6
21:24 pmurias joined #perl6
21:28 moritz I've been struggling with the Rat codegen for half a day, and giving up now
21:28 moritz there's what seems to be an optimization for Rat in Perl6::SymbolTable.add_constant
21:28 moritz removing it causes segfaults
21:29 moritz changing it to deal with bigints in any way that I can imagine makes it die with opaque errors
21:29 am0c_ joined #perl6
21:29 TimToady PerlJam: only the trailing whitespace would be recognized, so it depends on what you think its job is
21:30 TimToady your declaration would be indistinguishable from a rule declaration
21:31 pmurias joined #perl6
21:34 Trashlord joined #perl6
21:37 PerlJam TimToady: token blah { ... [:s [ foo | bar | baz ] ] ... } # then.  What I'm trying to get at is that sometimes the regex author may need to be explicit about the <.ws> when they're trying to use :s
21:37 PerlJam (the ellipses are meta in this example :)
21:39 TimToady that will ignore whitespace before foo, bar, or baz
21:39 TimToady that is, not expect whitespace
21:39 TimToady use :s '' [ ] to mean the other thing now
21:39 dalek 6model: 8a63edd | diakopter++ | lua/runtime/ (3 files):
21:39 dalek 6model: clone fixups
21:39 dalek 6model: review: https://github.com/diakopte​r/6model/commit/8a63eddf23
21:39 dalek 6model: 7ecd0ed | diakopter++ | lua/compiler/Makefile:
21:39 dalek 6model: Merge branch 'master' of github.com:diakopter/6model
21:39 dalek 6model: review: https://github.com/diakopte​r/6model/commit/7ecd0ed687
21:40 PerlJam ah
21:41 donaldh joined #perl6
21:43 PerlJam Still that's likely to surprise people
21:48 TimToady it
21:49 TimToady it's impossible to never surprise people :)
21:49 TimToady unless maybe when you're dead
21:49 TimToady and sometimes even then...
21:50 TimToady I just hope I'm never surprisingly boring :)
21:52 pmurias joined #perl6
21:52 ethndbst joined #perl6
21:59 pmurias joined #perl6
22:02 buubot_backup joined #perl6
22:06 pmurias joined #perl6
22:11 bluescreen10 joined #perl6
22:16 overrosy joined #perl6
22:29 buubot_backup joined #perl6
22:35 bluescreen10 joined #perl6
22:35 donaldh joined #perl6
22:39 pmurias joined #perl6
22:46 pmurias joined #perl6
22:52 pmurias joined #perl6
22:59 pmurias joined #perl6
23:11 pmurias joined #perl6
23:13 _jaldhar joined #perl6
23:13 tkr joined #perl6
23:13 tkr hi. what about PDL for perl6?
23:13 tkr what is it's replacement.
23:13 tkr ?
23:14 TimToady S09, but not implemented yet
23:14 tkr Hm, let me peek.
23:14 alvis joined #perl6
23:15 dukeleto does Rakudo have any plans to implement S09 any time soon?
23:16 TimToady they're working up to it with 6model and native types
23:17 tkr TimToady: Im talking about superfast Linear Algebra libraries
23:18 tkr Ah. Im probably confused in the discussion as I just joined the channel.
23:19 TimToady sorry, on the phone at the moment
23:20 tkr on a wireless phone or normal?
23:21 tkr do you dial the number using your index finger?
23:22 tkr TimToady: np. :)
23:23 dukeleto tkr: you want superfast linear algebra in perl 6?
23:23 tkr dukeleto: well, not that I really need it. I was just curious.
23:23 tkr dukeleto: Ive been attending the Machine Learning class online and learnt a lot of linear algebra that used to be "black" magic for me.
23:24 dukeleto tkr: there are some bindings to BLAS from Parrot that you could probably use in Rakudo. I say probably. I don't think anybody has ever tried.
23:24 tkr dukeleto: than I was delighted to hear that perl5 can do about the same as Matlab/Octave, when it comes to performance related to number crunching, and I got curious if perl6 had something cool that I wasnt aware of yet. :)
23:25 tkr dukeleto: ok.
23:26 dukeleto tkr: perl5/matlab/octave are all basically C, so yeah, *roughly* the same performance, but different memory overheads
23:26 dukeleto tkr: nobody can number crunch like Fortran, still.
23:27 dukeleto really, all we need is for ingy to port Inline::Fortran to Parrot and then Rakudo will get it for free...
23:27 dukeleto what could go wrong?
23:29 pmurias joined #perl6
23:32 _jaldhar joined #perl6
23:34 zby_home__ joined #perl6
23:42 ab5tract joined #perl6
23:51 whiteknight joined #perl6
23:52 buubot_backup joined #perl6
23:54 _jaldhar joined #perl6

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

Perl 6 | Reference Documentation | Rakudo