»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: irc.perl6.org/ | UTF-8 is our friend!
Set by sorear on 4 February 2011.
sorear TimToady: ping. clarification needed on S05:263 01:38
colomon sorear, o/ 01:39
sorear TimToady: the description seems to assume that [ :graphs . ] means [ :codes <!:Gc(/M/)> <:Gc(/M/)>* ] 01:41
TimToady: but there are many other kinds of grapheme clusters ... what about CRLF, Korean graphemes, Lao graphemes? 01:42
colomon: hi 01:43
colomon still working on the grand unicode project, I take it? 01:46
sorear yes 02:01
colomon I've peeked at the Gtk# specs looking for pixbuf info, but that's all I've had time for. Tuits in short supply here. 02:03
TimToady sorear: yes, that bit is partially fossilized, but I'm not sure what to replace it with yet; certainly NFD prefixing is a partial answer, but only a partial answer 02:21
p5 doesn't really have an answer for this yet either 02:22
sorear TimToady: every extended grapheme cluster which is not a single code point contains in NFD either a Hangul-syllable, a CRLF, or a non-mark character 02:39
TimToady: for :m I can see a solution based on equality of these "nuclei"
TimToady: I'm still wondering about character properties though. If we count only the nuclei, what character properties should be given to a CRLF or a Hangul-syllable? 02:40
I would like \w+ and \s+ to DTRT in as many cases as possible 02:41
I'm particularly thinking about the #?niecza 2 skip 'VOWEL SIGNs in identifiers' 02:42
which requires "cjkAccountingNumeric; kAccountingNumeric 02:43
cjkOtherNumeric; kOtherNumeric
cjkPrimaryNumeric; kPrimaryNumeric
wtf? 02:44
that was apparently in CUT_BUFFER0
"पहला" ~~ / :lang(STD) <ident> / # needs to work 02:45
I wonder what that word means, if anything 02:56
sorear o/ dukeleto 04:05
dukeleto sorear: howdy 04:10
cognominal_ nqp: my $a:=<1 2 3 10>; say( @( $a ) ) 07:34
p6eval nqp: OUTPUT«Method 'list' not found for invocant of class 'ResizablePMCArray'␤current instr.: '_block1000' pc 63 ((file unknown):47) (/tmp/HgMG423s9t:1)␤»
cognominal_ nqp: my $a:=<1 2 3 10>; say( $a.list )
p6eval nqp: OUTPUT«Method 'list' not found for invocant of class 'ResizablePMCArray'␤current instr.: '_block1000' pc 63 ((file unknown):47) (/tmp/f9AxVCoAB1:1)␤»
cognominal_ nqp: my $a:=<1 2 3 10>; say( |a ) 07:36
p6eval nqp: OUTPUT«flattened parameters must be a hash or array␤current instr.: '_block1000' pc 71 ((file unknown):51) (/tmp/EJuHBbE5yx:1)␤»
cognominal_ nqp: my $a:=<1 2 3 10>; say( |$a )
p6eval nqp: OUTPUT«12310␤»
cognominal_ :)
sorear ooh, cool. 08:04
the Unicode 6.1.0 public draft actually _simplifies_ the extended grapheme cluster rules 08:05
the "nuclei" I was talking about earlier? they are now always at the _beginning_ of the cluster
moritz sounds like an improvement indeed 08:08
snarkyboojum does Perl 6 plan to 'internationalize' it's error messages etc? 08:36
sorear snarkyboojum: yes, that's one of moritz' projects 09:12
moritz well, not the i18n itself, but laying the foundation for making that possible 09:29
moritz xkcd++ 10:12
tadzik just read that 10:13
g'morning 10:14
moritz o/ tadzik
avar hahaha 10:27
"Your favorite musical genre is 'post-'"
felher masak++ for gist.github.com/1293853, very interesting, thnx :) 11:54
flussence bah, why doesn't "map $subref @list" work in p5? :( 11:56
tadzik how about &$subref? 11:56
flussence I've tried several variations of it and the only one that works properly is "map { $subref->($_) 11:57
bleh
s/$/ } @list /
flussence perl6: sub n { :16($^a) }; «a b c d e f».map(&n).say 12:01
p6eval rakudo ef4702: OUTPUT«10 11 12 13 14 15␤»
..pugs b927740: OUTPUT«decodeUTF8': bad data: '\171'␤decodeUTF8': bad data: '\187'␤*** Undeclared variable: ("$^a",MkPad (padToList [("$_",PELexical {pe_type = (mkType "Scalar"), pe_proto = <Scalar:0x7f64e4319bf9>, pe_flags = MkEntryFlags {ef_isContext = True}, pe_store = <ref:0x7f64e4319…
..niecza v11-23-g18f7db0: OUTPUT«Use of uninitialized value in string context␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 773 (warn @ 2) ␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 168 (Mu.Str @ 9) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /home/p6eval/niecza/src/Nie…
flussence (I'm rewriting some ugly code at $dayjob, and finding combining List::MoreUtils with subrefs strangely addictive) 12:03
tadzik :) 12:06
cognominal_ flussence, may be you should check perlude? 12:06
github.com/eiro/p5-perlude 12:07
flussence wow, that looks pretty useful actually... 12:10
cognominal_ eiro tried to do haskell-like functional programming in perl 12:11
cognominal_ perlude is a pun on haskell prelude, btw. 12:12
flussence I know just enough haskell to be scared by that example code :)
moritz haskell without the static type checks... sounds like lisp :-) 12:31
dalek p/bigint: f7b182b | moritz++ | / (3 files):
float -> bigint op

round-trips big FLOATVALs
13:48
cognominal_ moritz, indeed but I think eiro discovered that programming style thru haskell. 13:57
dalek kudo/bigint: 9a01b11 | moritz++ | / (2 files):
use nqp::fromnum_I in Num.Int
14:24
moritz $ ./perl6 -e 'say 1234e120.Int' 14:28
1234000000000000032088370686438714170547122766761560296159775498714130972155570822049891345893609670390352866249059805954048
colomon interesting 14:29
moritz the digits after the '12340000000000000' are just the binary zeros that are added after the mantissa of the double is used up
perl6: say 1234e120.Int 14:30
p6eval pugs b927740: OUTPUT«*** No such method in class Rat: "&Int"␤ at /tmp/jcUjLAFhGR line 1, column 5 - line 2, column 1␤»
..niecza v11-23-g18f7db0: OUTPUT«1234000000000000032088370686438714170547122766761560296159775498714130972155570822049891345893609670390352866249059805954048␤»
..rakudo ef4702: OUTPUT«-9223372036854775808␤»
moritz it seems that niecza agrees :-) 14:31
since I've developed that independent of niecza, that's a good sign :-)
moritz phenny: tell jnthn about gist.github.com/1364229 (rakudo and nqp bigint status summary). I'll mostly be offline between 2011-11-16 and 2011-11-23 15:52
phenny moritz: I'll pass that on when jnthn is around.
colomon thinks about volunteering to help with bigint while moritz is gone, only to remember his tuits are sharply limited and unknowable in advance. :( 15:55
moritz most of the LHFs have likely been picked 16:00
moritz unless codegen in the SymbolTable counts as LHF, or architecture-dependent bit fiddling :-) 16:01
moritz -> afk 16:01
jnthn back from trip 17:03
phenny jnthn: 15:52Z <moritz> tell jnthn about gist.github.com/1364229 (rakudo and nqp bigint status summary). I'll mostly be offline between 2011-11-16 and 2011-11-23
jnthn moritz++ 17:04
jnthn phenny: tell moritz thank you! Now the various workshops are done, I should have a good supply of tuits to continue working on bigint. :) 17:05
phenny jnthn: I'll pass that on when moritz is around.
tadzik o/ 17:06
jnthn hi, tadzik 17:07
jnthn has been immersed in London Perl Workshop and visiting friends and is rather behind with whatever's been going on around here :)
tadzik is on Python users group meeting :) 17:08
jnthn :)
jnthn enjoyed visiting the Beer User's Group in London ;) 17:09
kboga \o/ jnthn round-tripped :) 17:12
awful pun... hi btw 17:13
jnthn :P 17:16
kboga question, should in "src/core/Instant.pm" line 113, the value of pir::time__n perhaps be boxed? 17:21
jnthn kboga: yeah, it'd be far better to do that explicitly 17:24
well
kinda :0
:)
The binder actually handles natives just fine.
And since it's being used directly as a call argument it'll likely work out
TimToady sorear: I really hate the idea of corrupting smartmatching merely to accomodate a poor decision of the Unicode Consortium. 17:41
though possibly it indicates the need for a case-folded type that smartmatches by also folding the acceptee 17:43
TimToady so instead of :Blk<ASCII> you could write :Blk(fc 'ascii') 17:46
but casefolding should be more of a user convenience than a programmer convenience, in my estimation 17:47
TimToady but it seems like a really bad design for the UC to on the one hand define a really complex and linguistically problematic casefolding operation, and on the other hand require use of it for programming. 17:50
I think this is one spot where I'd rather fight the Unicode Consortium than cave. 17:51
cognominal_ TimToady is certainly not a caveman. 17:54
slavik1 we don't know that 17:58
TimToady slavik1: the French are experts on cavemen 18:05
cognominal_ :) 18:08
slavik1 "takes one to know one" in full effect? 18:18
[Coke] TimToady: do you read p5p? 18:22
TimToady [Coke]: nope 18:30
[Coke] Not to give you any ideas, but someone just said they missed you. 18:33
sorear TimToady: should we also shun aliases, and require use of <:Gc<Lo>> or <:General_Category<Other_Letter>>? If so which one? 19:08
sorear the database uses the former for natural space reasons 19:08
sorear I suppose you're also opposed to casefolding, spacefolding, and hyphen-folding in \c 19:09
djanatyn hey! 19:12
djanatyn has anyone here heard of GCI? 19:12
colomon Gannett Co, Inc? Great Coasters International? Grace Communion International? Getty Conservation Institute? 19:14
[Coke] djanatyn: googles Code In. Aye. 19:16
TPF is a registered mentoring organization. 19:17
sorear djanatyn: not sure about TPF, but PaFo was active in last GCI 19:22
sorear [Coke]: is it possible to get a list of p5p emails sorted by _time_? 19:25
Trashlord what the hell 19:26
[Coke] sorear: I have no idea. the archives tend to be threaded, I think. 19:30
(GCI) both orgs are registered this year (out of a total of under 20 or so) 19:31
sorear [Coke]: could you tell me what thread you're reading, then? 19:32
sorear nntp.perl.org won't tell me which threads are active, and all the other archives I've seen are 6mo-5yr out of date 19:33
sorear o/ benabik 19:34
benabik o/ sorear 19:34
sorear: You're fast. My computer had barely finished waking up.
[Coke] sorerar: www.nntp.perl.org/group/perl.perl5....79175.html
colomon is wishing svn had stash... 19:35
benabik colomon: git-svn is your friend 19:36
[Coke] colomon: git-svn!
benabik (Or at least it wants to be your friend.)
colomon Tried it, was not wild about it.
colomon I'd probably consider moving the core portion of my svn repo to git before git-svn at this point. 19:37
benabik My experience with git-svn was "not great, but better than raw svn." Found that cloning the SVN database locally with svnsync (or something like that) made it a lot faster to set up.
[Coke] colomon: I hated it as an intro to git, but love it now that I am a git user forced to use svn.
(move to git) much better solution if you like git, yes.
colomon As I recall, part of the problem with git-svn was that I tend to have 10+ different copies of the repo checked out on my machine at once, and git-svn only could work on one? 19:38
[Coke] you could have 10 git-svn checkouts, sure. 19:39
[Coke] I would probably have 10 different local branches in a single git-svn working copy, though. 19:40
benabik would probably have one central repo for git->svn and clone -s from it. 19:41
sorear [Coke]: thanks!
benabik (I think git-svn can handle multiple repos doing the git->svn direction.)
djanatyn Is there any perl6 stuff in the Google-Code-In perl project? 19:56
if there is, I'm really interested in participating.
colomon Seems like something perl6 can be arranged, no? 19:57
sorear I wouldn't be suprised, there's a very interesting demographic split between the p5 and p6 community
hi colomon 19:58
[Coke] Need to find the TPF GCI guy and talk to him, I suppose. 19:58
colomon sorear, o/
I mean, TPF is both p5 and p6.
Probably just a matter of organizing...
[Coke] colomon: yah. 19:59
djanatyn so, what exactly do I have to do to get involved in GCI with perl? :) 20:01
my friend just linked it to me because he thought it would be something I was interested in, though he's a perl5 dude 20:02
I've written a few things in perl5, but I'm a lot more interested in doing something with perl6
benabik I think the GCI process has started, so if Perl 6/TPF hasn't gotten involved yet, it may be too late. 20:03
djanatyn aww. 20:04
well, I'm pretty sure the perl foundation has already started.
wiki.enlightenedperl.org/gci2011 20:05
oh, looks like the perl foundation has been officially accepted. 20:06
Is...perl6 a seperate entity from the perl foudnation?
colomon djanatyn: nope, TPF is over us, too 20:14
colomon well, for some sense of "over us", anyway. 20:14
colomon hmmm... guess the question is, is it still possible for Parrot and TPF to submit more tasks? 20:16
colomon is busy surfing the Code-In web pages, which seem to have about half the information he'd like to find... 20:17
colomon wiki.enlightenedperl.org/gci2011/gci2011/ideas -- and the front page seems to imply task ideas can still come in. perhaps we need to have a #perl6 brainstorming session and add a batch? 20:30
dalek odel: 48d0b24 | diakopter++ | lua/compiler/ (2 files):
rollback the STable and FormWith 'optimization' attempts...
20:37
[Coke] note that students don't go live until... monday, I think. 20:39
(working with local HS teacher here to get us some more students this year.)
GlitchMr perl6: 1/∞ 20:42
p6eval pugs b927740: OUTPUT«decodeUTF8': bad data: '\8734'␤*** ␤ Unexpected end of input␤ at /tmp/cQlM9UVNBZ line 1, column 4␤»
..niecza v11-23-g18f7db0: OUTPUT«===SORRY!===␤␤Bogus term at /tmp/QGzQavTryH line 1:␤------> 1/⏏∞␤␤Parse failed␤␤»
..rakudo ef4702: OUTPUT«===SORRY!===␤Confused at line 1, near "1/\u221e"␤»
GlitchMr How can I add support for "∞" in Perl 6?
perl6: sub ∞ {Inf}; print 1/∞ 20:43
p6eval pugs b927740: OUTPUT«decodeUTF8': bad data: '\8734'␤decodeUTF8': bad data: '\8734'␤*** ␤ Unexpected "\8734"␤ expecting "=", subroutine parameters, trait or block␤ at /tmp/jMuoAC42sS line 1, column 5␤»
..niecza v11-23-g18f7db0: OUTPUT«===SORRY!===␤␤Malformed block at /tmp/uymMQ7_ZUv line 1:␤------> sub ⏏∞ {Inf}; print 1/∞␤␤Parse failed␤␤»
..rakudo ef4702: OUTPUT«===SORRY!===␤Malformed block at line 1, near "\u221e {Inf}; p"␤»
GlitchMr ... doesn't work... 20:43
Too bad...
TimToady niecza: constant term:<∞> = Inf; say ∞ 20:43
p6eval niecza v11-23-g18f7db0: OUTPUT«===SORRY!===␤␤Colonpair traits NYI at /tmp/AWBrXErpAU line 1:␤------> constant term:<∞> ⏏= Inf; say ∞␤␤Unsupported use of bare 'say'; in Perl 6 please use .say if you meant $_, or use an explicit invocant or argument a…
TimToady you can't use bare ∞ as an identifier, since it's not considered alphanumeric 20:47
GlitchMr :( 20:47
TimToady that's where term:<∞> is supposed to help
GlitchMr But ∞ is number...
So it's alphanumeric ;). I guess it's not alphanumeric for Unicode... 20:48
[Coke] Unicode thinks it's a math symbol, aye. 20:48
GlitchMr Makes sense...
TimToady std: constant term:<∞> = Inf; say ∞ 20:49
p6eval std be1f10e: OUTPUT«===SORRY!===␤Unsupported use of bare 'say'; in Perl 6 please use .say if you meant $_, or use an explicit invocant or argument at /tmp/5yzj1CVqo_ line 1:␤------> constant term:<∞> = Inf; say⏏ ∞␤Confused at /tmp/5yzj1CVqo_ line 1:␤…
TimToady hmm
TimToady std: constant term:<∞> = Inf; ∞ ∞ 20:49
p6eval std be1f10e: OUTPUT«===SORRY!===␤Bogus statement at /tmp/t8xA9nHCTG line 1:␤------> constant term:<∞> = Inf; ⏏∞ ∞␤Parse failed␤FAILED 00:01 121m␤»
TimToady I though term: was ipmlemented 20:49
*ght
GlitchMr s/ipm/imp/; # ? 20:50
TimToady that too
TimToady std: sub term:<∞>() { Inf }; say ∞ 20:53
p6eval std be1f10e: OUTPUT«ok 00:01 125m␤»
TimToady niecza: sub term:<∞>() { Inf }; say ∞
p6eval niecza v11-23-g18f7db0: OUTPUT«Infinity␤»
TimToady \o/
niecza: sub term:<∞>() { Inf }; say ∞ ∞
p6eval niecza v11-23-g18f7db0: OUTPUT«===SORRY!===␤␤Confused at /tmp/7uQVjLZCFx line 1:␤------> sub term:<∞>() { Inf }; say ∞ ⏏∞␤␤Parse failed␤␤» 20:54
TimToady and is parsed as a term
japhb sub term:<∞>() { Inf }; say ~∞
niecza: sub term:<∞>() { Inf }; say ~∞
p6eval niecza v11-23-g18f7db0: OUTPUT«Infinity␤»
jnthn That should probably be Inf, iirc
japhb Shouldn't that .Str to 'Inf'?
jnthn o/ japhb :)
japhb jinx
o/
jnthn ok, now I have tuits again...albeit slightly tired ones this evening... 20:55
japhb (In the Str.Numeric() rewrite, 'Inf' disallows trailing characters, and in the stress test, 'Infinity' is one of the cases that is supposed to fail. :-) )
Yay for tuits! 20:56
jnthn Yeah, my workshoppin' is done for the year. :)
japhb BTW, even though it still has problems, moritz++'s bigint work led to a Str.Numeric() stress test with several hundred results incorrectly typed as Num correctly returning Int or Rat instead. 20:58
jnthn oh noes, current nqp build fails for me
japhb And holy cow, TimToady, let me just say that when you decide to generalize something, you don't mess around! 21:00
jnthn inline op nqp_bigint_is_big 21:01
OH RLY?
:D
dalek p/bigint: f41528b | jnthn++ | src/ops/nqp_bigint.ops:
Work around MSVC++ being too clever and catching a compile time divide by zero.
21:03
jnthn phenny: tell moritz Hm. On my platform the "to_num and from_num round-trip" tests fail 21:20
phenny jnthn: I'll pass that on when moritz is around.
jnthn phenny: tell moritz ah, it's off by a tiny bit... 1.23456789e+248 vs 1.23456788999987e+248. 21:32
phenny jnthn: I'll pass that on when moritz is around.
jnthn OK, seems Num.Rat is totally hosed on my system 21:45
jnthn oh, no wonder 21:47
> say 1e1.Int
0
benabik That doesn't seem right.
jnthn Indeed
moritz ouch 21:55
phenny moritz: 17:05Z <jnthn> tell moritz thank you! Now the various workshops are done, I should have a good supply of tuits to continue working on bigint. :)
moritz: 21:20Z <jnthn> tell moritz Hm. On my platform the "to_num and from_num round-trip" tests fail
moritz: 21:32Z <jnthn> tell moritz ah, it's off by a tiny bit... 1.23456789e+248 vs 1.23456788999987e+248.
jnthn moritz: What does this output for you:
gist.github.com/1365326
jnthn moritz: Added my output to the gist 21:56
moritz too 21:57
jnthn ok...different
if I change the test code to
my $float := 12345;
I get out
12345 21:58
0
Goes without saying the test suite gets interesting with this issue ;-) 21:59
jnthn (many hangs!) 21:59
moritz seems I hosed the conversion of the small floats
moritz ah, I see why 22:00
jnthn moritz: But...it works for you? Or? 22:01
moritz no
moritz compiles a possible fix
jnthn \o/
moritz: How do I trigger the Rat compilation issue? I suspect I know how to fix it...but the thing I thought would show it here actually works now :) 22:02
("say -1.56079666010823" used to give a very wrong answer, but now does not)
moritz the problem is nqp_bigint.ops lines 63..65
jnthn: I guess you need to compile a long Rat to PIR
something like 3.14444444444444444444444444444444444444 22:03
jnthn oh!
moritz better to add an odd number at the end :-)
dalek p/bigint: beb69a6 | moritz++ | src/ops/nqp_bigint.ops:
unbust conversion from float to bigint (hopefully)
22:04
jnthn tries the patch 22:05
jnthn moritz: seems to help my nqp example 22:06
jnthn moritz: I still have the smaller error for the test 26 and 27 of 60-bigint.t 22:06
OK, let's have another go around the spectest :) 22:08
moritz jnthn: do you know how many bits your FLOATVAL mantissa has, and what DIGIT_BIT is on your platform? 22:09
jnthn moritz: not off hand; I guess DIGIT_BIT is easy to find out...
jnthn moritz: here, DIGIT_BIT = 28 22:13
moritz OH 22:13
it's 60 here 22:14
jnthn Curious. I'm on a 64-bit platform too
moritz then I see why it loses precision
jnthn Microsoft (R) C/C++ Optimizing Compiler Version 16.00.30319.01 for x64
It even says it's compiling as 64-bit. Interesting.
moritz jnthn: I can you can tweak some #define's to make 60 bit too then
jnthn looking at them 22:16
moritz anyway
what the conversion currently does is devide and modf by 2 ** DIGIT_BIT 22:17
*divide
that's enough if DIGIT_BIT >= mantissa of double (52 bit iirc)
if that's not the case, we'd need to rinse & repeat
until (no_of_repetitions + 1) * DIGIT_BIT >= 52 22:18
erm, -1
jnthn moritz: Do you get a great deal of spectest fail, ooc? 22:19
The main thing I see is hangs.
t\spec\S02-types\infinity.rakudo, t\spec\S32-num\int.rakudo and t\spec\S32-num\rat.rakudo all do so 22:20
ah 22:21
my $x = Inf.Int
yeah, don't need the assignment :)
nom: say Inf.Int 22:22
p6eval nom ef4702: OUTPUT«-9223372036854775808␤»
jnthn perl6: say Inf.Int
p6eval niecza v11-23-g18f7db0: OUTPUT«1797693134862315907729305190789024733617976978942306572734300811577326758055009631327084773224075360211201138798713933576587897688144166224928474306394741243777678934248654852763022196012460941194530829520850057688381506823424628814739131105408272371633505…
..pugs b927740: OUTPUT«*** No such method in class Num: "&Int"␤ at /tmp/Qzc_4WIvsu line 1, column 5 - line 2, column 1␤»
..rakudo ef4702: OUTPUT«-9223372036854775808␤»
jnthn niecza: say Inf.Int.Str.chars 22:23
p6eval niecza v11-23-g18f7db0: OUTPUT«309␤»
jnthn Apparently, infinity is 309 digits long :D
OTOH, it's closer to inifinity that what Rakudo currently does :P 22:24
sorear japhb: niecza just uses System.Double.ToString(CultureInfo.InvariantCulture) 22:26
jnthn sorear: I'm jnthn ;) 22:27
sorear japhb: writing a proper Str.Numeric/Num.Str is on my long-term TODO
jnthn oh
similar topic, but right person after all :)
sorry :)
sorear: any opinions on what Inf.Int should do?
moritz: All the hanging tests boil down to Inf.Int. 22:28
sorear jnthn: last time I pressed TimToady on this, the opinion I got was that Inf ~~ Int already so it was a noop 22:28
jnthn o>O
sorear jnthn: also we still need to figure out how Failure ~~ Int is going to work
jnthn I'm...not sure how to fit that into my mental model. 22:28
Oh, I'd assumed that one could work becuase you mix in to individual objects. 22:29
moritz jnthn: ah right, need to special-case that one. I guess it should fail() or die() for now 22:29
same for Rat.Int
sorear I have the same mental model issue
jnthn moritz: wfm 22:30
moritz speaking of mental models...
sorear niecza's Num/exact-Rat converter is a bit simplistic
moritz 99 ** 99 # are these two numbers Int or int ?
if they are allowed to be int, then the operation might overflow 22:31
sorear 2000000000 + 2000000000 # are these two numbers Int or int, on a 32-bit system?
I think it's very obvious the result should be 4e9.Int
jnthn waves his hands about :) 22:31
moritz sorear: exactly my question... but I'm not sure about the result -) 22:32
jnthn I've been seeing the literals as kinda polymorphic
But it gets a bit odd
jnthn Especially when dispatchy issues arise 22:32
(like the two mentioned)
I guess we lean towards Int but lower to int "when context suggests we should" 22:33
sorear moritz: I would argue that if user code does not explicitly contain the token "int" it should not be wordsize-sensitive
this is a case of constant allomorphism 22:34
jnthn sorear: I agree in a sense. Knowing what to do in the my int $x = 42; case isn't so much the issue
sorear 99 has to be either int or Int, depending on context
jnthn It's knowing what to then do with $x + 1
And we normally don't flow context in that kinda way
sorear int + constant is like int + int, Int + constant = Int + Int, constant + constant = Int + Int 22:35
*waves* 22:36
jnthn sorear: heh, that's where I'd kinda got to :) 22:37
jnthn Though the optimizer gets a bit overexcited about the constant + constant case at the moment... 22:37
japhb sorear, re: Num.Str: ah, OK, NYCI, got it.
sorear rakudo: say 8_000_000_000_000_000_000
p6eval rakudo ef4702: OUTPUT«8000000000000000000␤»
sorear rakudo: say 8_000_000_000_000_000_000 + 8_000_000_000_000_000_000 22:38
p6eval rakudo 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_n' not found␤␤ in file '(file unknown)' line 37795777␤»
sorear What?
rakudo: my $x = 8_000_000_000_000_000_000; say $x + $x
p6eval rakudo ef4702: OUTPUT«-2446744073709551616␤»
jnthn sorear: f**king imcc
japhb sorear, re: constant + constant: shouldn't that be => constant-fold(constant + constant) => constant-fold(Int + Int) => constant-polymorphic?
jnthn sorear: It converts an I literal into an N literal
sorear: If it detects it'll overflow
sorear japhb: yes, ish
jnthn o.O
sorear: On my box it further gets it wrong, having 64-bit integer registers, but only letting in 32-bit literals :( 22:39
sorear wonders how close rakudo is to ditching imcc
moritz the bigint branch detects size of integers > what the platform can hold, and emits different code for that 22:40
(at least on platforms where nqp::isbig_I works properly)
moritz (and if those integers don't form rats :/ ) 22:40
jnthn moritz: What spectest fallout do you get from the rat issue? 22:41
jnthn moritz: Is it only a pre-comp issue? 22:41
(I understand the pre-comp issue, I'm just struggling on how it affects the spectests much) 22:42
moritz jnthn: I think it's not only precomp, but I don't really understand it :( 22:42
it seems that some rat literals come out completely wrong, even without precomp
but my debugging output from radcalc seems to imply that the rats get created with the right numerator and denominator, so I'm kinda lost 22:43
jnthn moritz: I used to see a load of tests in the trig 22:44
moritz: But that's all cleared up here now
pi.t aside
moritz \o/
I won't get around to the Num.Int fix for Inf/-Inf/NaN tonight 22:45
moritz ETOOCLOSETOSLEEP 22:45
jnthn moritz: OK, working on that here
moritz: Would be good to have examples of rats that fail for you
moritz jnthn: they might be gone too, will see after the recompile 22:46
jnthn k
moritz (now running through IMCC) 22:46
urks... forgot to install nqp 22:47
jnthn oh noes
moritz $ ./perl6 -e 'say 0.523598775603156' 22:47
0.695983722377273
tadzik :P 22:48
jnthn > say 0.523598775603156
moritz (that's without the last NQP fix, but I think it should be unrelated)
jnthn 0.523598775603156
:(
Works here :/
moritz will see tomorrow
sleep &
jnthn o/
colomon \o 22:49
sorear seems Perl 5 can't do 22:50
seems Perl 5 can't do "spin̈al" =~ /\w+/ correctly either.
jnthn > my $PI = 3.141592653589e0;
0.552631241154582
hm
sorear In Texas π is 3 / In Slovakia it's just over 1/2 ... 22:51
jnthn :P 22:53
dalek kudo/bigint: 296212e | jnthn++ | src/core/Num.pm:
fail for Inf.Int and Inf.Rat. Maybe not the perfect solution, but it's far better than hanging.
jnthn Only 3? I'da thunk it'd be much bigger
sorear something something Ezekiel something
tadzik they have pi in farenheits? 22:54
japhb jnthn, in Texas those are Texas-sized integers. A 3 in Texas is bigger than a house in one of those other states .... 22:54
sorear jnthn: so I've heard ch is a letter in Slovakia. 22:55
jnthn Well, it represents a single sound, if that's what you mean by letter :) 22:56
tadzik "cz"? :)
. o O ( Brzęczyszczykiewicz )
I think it's called a vowel
jnthn oh 22:57
en.wikipedia.org/wiki/Ch_%28digraph%29
tadzik I once heard that only a Polish man can distinguish "sz" from "sh" and "ś"
jnthn Wikipedia has it as "a letter"
tadzik funny, they never told me it's a letter
jnthn My Slovak teacher never really explained it to me that way though.
But after a while my brane chunked the two. 22:58
japhb jnthn, in commit 296212ebe9, you say "Cannot coerce NaN to an Int" where it looks like you meant Inf instead of NaN.
tadzik also, there's nothing about it being a letter on Polish wikipedea
japhb And actual, in the 'to Rat' message as well
tadzik it's called a digraph, being a set of two letters
so, not a letter
(says mi limited knowledge) 22:59
jnthn japhb: also I missed the negatives :/ 23:00
sorear I wonder if, instead of pestering TimToady about 'what does \p{hst:lvt} even mean in grapheme cluster mode' 23:00
japhb jnthn, yup. :-)
sorear I should take my questions to the people on the top of UTR18
Mark Davis and Andy Heninger 23:01
sorear seems both are ICU hackers 23:05
dalek kudo/bigint: e4cd7a4 | jnthn++ | src/core/Num.pm:
fail for Inf.Int and Inf.Rat. Maybe not the perfect solution, but it's far better than hanging.
23:06
masak gu-reetings, #perl6 23:09
tadzik . o O ( wild idea: JAPH printed from substrings of exceptions ) 23:10
tadzik hello masak 23:10
jnthn o/ masak
masak TimToady: jnthn hadn't seen your recent speculations about macros, so I gave him a summary. we Talked It Over. up until now I've been resisting the introduction of a new placeholder sigil, but jnthn pointed out a few real weaknesses in the idea of non-term placeholders. 23:11
masak two, to be exact. I'll list them as I remember them. 23:12
masak (1) with terms, parsing is easy. with any kind of grammatical category, we... can't parse. (as I understood it.) specifically, some operators such as assignment are very magical and generate wildly different ASTs. 23:13
it feels... wrong to throw out parsability at parse-time.
jnthn (the simpler case is that if we don't know the precedence we can't parse...) 23:14
masak oh right! 23:14
yeah, the optable parser simply cannot operate (no pun intended) under such circumstances.
I was quite relieved when I realized that. :)
because if it's impossible, I don't have to implement it, right?
masak right? :S 23:15
(2) none of the three syntaxes for macro invocation (subcall, listop, operator) allow for passing non-terms.
that indicates (to me, at least), that macros are for terms.
masak s/\),/)/ 23:15
jnthn masak: no, as Perl 6 implementors we're expected to the impossible ;P 23:16
masak augh
probably three times before breakfast, too. 23:17
or was that just thinking the impossible? I forget.
sorear maaaaasaaaak
masak soooooreaaaar
masak runs over a field towards sorear in slow motion with outstreched arms 23:17
diakopter lol "over" 23:18
masak um. "across"?
masak English. it's hard. 23:18
diakopter yeah
sorear aaagh. that was my last field, I'll have to use rings now 23:19
masak I've been in .uk over the weekend. that probably broke my preposition box.
jnthn Huh? Why you not speak Queen's English now?
diakopter I suppose one can mow over a field 23:19
masak jnthn: the Queen freaks me out. she lays so many eggs. 23:20
masak sorear: I had to throw all the fields away because they had become skewed. 23:20
jnthn masak: Plus she looks kinda old. Not surprising, given she has 10 times the lifespan or ordinary workers...
masak jnthn: *lol*
jnthn *of
masak jnthn: this explains everything
everyone else: jnthn is referring to regex jokes in my recent presentation. 23:21
well, one of them.
tadzik I thought it's somewhat about bees
masak tadzik: it's about Reuters who s/\bthe queen\b/Queen Elisabeth/g in their news. 23:22
masak tadzik: it worked OK until they had an article about bees. 23:22
tadzik :>
masak clairvy: hey, cut it out! 23:23
tadzik oh, you also don't ignore enter/leave events? :) 23:24
sorear masak: I tried banning clairvy once. Didn't work. 23:25
jnthn sorear: ...didn't work? 23:25
masak tadzik: no, I consider them useful. except when people have some kind of autojoin mechanism on.
sorear jnthn: despite never talking, ey knows about ban evasion
sorear maybe if I set something really wide like $x:*clairvy* 23:26
jnthn sorear: fine by me 23:26
masak +1 23:26
sorear mode #perl6 +b 23:26
tadzik masak: especially then I find them useless :)
sorear tadzik: there is a large contingent of users, like masak and benabik, who join when they want to talk and part when they don't 23:29
masak well, used to.
now I'm running irssi+screen.
tadzik sorear: I wouldn't call that large
sorear as distinguished from people like me, who never join/quit, and people like pmurias and clairvy, who join/quit constantly for no reason 23:30
tadzik sorear: and that's exactly the reason why I pay no attention to that; in the world I see, the knowledge about someone being on the channel or not is worthless
sorear also someday I should persuade moritz to let me fix the lack of quit reporting in ilbot
but that would require effort
flussence I've been trying to think up a cleverer algorithm for join/part messages than "barf everything to screen asap". Preferably one that does what everyone wants...
tadzik I wanted to have a 2-3 line wide buffer on top of the weechat/irssi window 23:31
there was even an irssi theme like that, which, as some people claim, didn't segfault at some point in history
also, those few people who actually join and quit when they want to usually say "hello" and "bye", and that's fine for me 23:32
</opinion>
masak I'll be not-very-active in the next two days. will be teaching. however, I'm eager to blog about the macro work so far, as well as dig into the last bit of D1. 23:33
for now, 'night #perl6
tadzik o/ 23:35
sorear o/ 23:36
djanatyn hey, back. 23:38
tadzik hey djanatyn 23:39
djanatyn is there anyone here I can talk to about Google Code-In? 23:40
Should I like, submit a resume or sample code or something? 23:41
tadzik no, nope
you just apply for the specific task
then you have like 24 hours to deliver the result, then you pick another task
djanatyn Oh, cool. 23:43
Where are the tasks?
tadzik well, GCI has not yet officially started, methinks 23:44
djanatyn Oh, interesting
do I need to sign up somewhere first?
tadzik I suppose so
www.google-melange.com/gci/homepage...le/gci2011
djanatyn I'm pretty excited, I haven't really done anything like this before :)
thanks
jnthn 'night, #perl6 23:58