»ö« | perl6.org/ | nopaste: paste.lisp.org/new/perl6 | evalbot usage: 'perl6: say 3;' or rakudo:, alpha:, pugs:, std:, or /msg p6eval perl6: ... | irclog: irc.pugscode.org/ | UTF-8 is our friend! Set by lichtkind on 5 March 2010. |
|||
00:00
ruoso joined
00:10
lue joined
|
|||
lue | ololitsme | 00:10 | |
jnthn | roflitslue | 00:11 | |
lue | who doesn't love their computer shutting off at 11PM while finishing up a paper? I do! :( | 00:15 | |
jnthn | :-/ | 00:16 | |
lue | ah well :D now to check the logs | 00:17 | |
00:17
quietfanatic joined
|
|||
quietfanatic | I just noticed, that "return ' ' ~ $_ if $_ = join( ' ', self.attributes>>.xml)" | 00:20 | |
could be more easily written "return ' ' X~ self.attributes>>.xml" | |||
jnthn | There's more than one way to cute it. :-) | 00:21 | |
quietfanatic | I know I'm half a day late on that but whatever | ||
jnthn | I hadn't thought of that one. :-) | ||
It is neat. :-) | |||
quietfanatic | seems half the time I enter this channel it's from an urge to reply to something in the log... | 00:25 | |
s/..// | |||
err, s/\.\.// :) | |||
lue | s/$mistakes/$success/ | 00:27 | |
jnthn | s/'..'// | ||
;-) | |||
00:28
payload left
|
|||
quietfanatic | more than one way to cute it. | 00:28 | |
lue | TIMTOWTCI | 00:29 | |
00:30
lue is now known as TimToki,
quietfanatic is now known as TimToteKey,
TimToteKey is now known as quietfanatic
00:31
TimToki is now known as lue,
frzntoz joined
|
|||
lue | phenny: "知無時" ? | 00:31 | |
jnthn | Oh no, I accidentally the meme. | ||
quietfanatic | Haha, "Wisdom ignorance time" | 00:33 | |
lue | Support Regular Language (promote "You is" and "I is") | ||
quietfanatic: I knew the Toki in TimToki is "time", but is it really Wisdom Ignorance Time? | |||
jnthn | Just speak Swedish. They use är for all of them anyway. :-) | ||
lue | (the japanese is TimuToki, btw) | ||
quietfanatic | or "Wisdom no time" | ||
but ignorance is the first interpretation my popup dictionary came up with | 00:34 | ||
lue | (checking babylon translator) | ||
quietfanatic | Incidentally, that's the same 無 as in Mu. | ||
jnthn | Well, I guess if you write Mu in a signature, you're being ignorant about what kinda thing can be passed. :) | 00:35 | |
quietfanatic | In fact, if it's pronounce "timutoki" than it definitely is mu meaning nothing... | ||
rakudo: say 無.WHAT | |||
p6eval | rakudo 43f865: OUTPUT«Could not find sub &無current instr.: '_block14' pc 29 (EVAL_1:0)» | ||
lue | "In intellect nothing" is what babylon.com says. (it's the most trustworthy translator as far as I can tell) | ||
quietfanatic | I'm a little disappointed that's not a synonym | ||
:) | 00:36 | ||
lue | TimToady: "知無時" ? | ||
jnthn | quietfanatic: Well...it could be made one... ;-) | ||
quietfanatic | rakudo: macro 無 { 'Mu' }; say 無.WHAT | 00:37 | |
p6eval | rakudo 43f865: OUTPUT«Could not find sub &無current instr.: '_block14' pc 29 (EVAL_1:0)» | ||
jnthn | .oO( There will be modules ) |
||
Sadly, macros NYI. | |||
quietfanatic | rakudo: constant 無 = Mu; say 無.WHAT | ||
p6eval | rakudo 43f865: OUTPUT«Could not find sub &無current instr.: '_block14' pc 29 (EVAL_1:0)» | ||
jnthn | rakudo: sub 無 { Mu }; say 無.WHAT | ||
p6eval | rakudo 43f865: OUTPUT«Mu()» | ||
jnthn | But then you can't use it as a type name...yeah, constant would be better. | ||
quietfanatic | gotta commute now | 00:38 | |
00:38
Yunga joined,
quietfanatic left
|
|||
jnthn | o/ | 00:38 | |
00:39
solu joined
|
|||
lue | bye-e o/ | 00:39 | |
rakudo: my Mu $a = 3; say $a | 00:40 | ||
p6eval | rakudo 43f865: OUTPUT«3» | ||
00:40
frzntoz left
00:43
frzntoz joined
|
|||
lue | rakudo: multi sub token:<無>{Mu();}; my 無 $a = 3; say $a | 00:43 | |
p6eval | rakudo 43f865: OUTPUT«error:imcc:syntax error, unexpected '\n' in file 'EVAL_1' line 58Malformed my at line 11, near "\u7121 $a = 3; "current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)» | ||
jnthn | ... | 00:46 | |
lue | .oO(worth a shot) |
||
jnthn | that's...impressive. | ||
lue | .oO(when you don't know how anything works) |
||
jnthn | You confused the codegenerator. | ||
multi sub term:<無>{Mu();}; | |||
rakudo: multi sub term:<無>{Mu();}; | |||
p6eval | rakudo 43f865: OUTPUT«error:imcc:syntax error, unexpected '\n' in file 'EVAL_1' line 58» | ||
lue | .oO(apparently, 無 (mu) means bad, poor, zero, nothing, ignorance) |
00:47 | |
00:47
frzntoz left
|
|||
jnthn | how on EARTH does that parse. | 00:47 | |
std: multi sub term:<無>{Mu();}; | |||
p6eval | std 30353: OUTPUT«ok 00:01 111m» | ||
jnthn | ...wow! | ||
lue | what would that do? | 00:48 | |
jnthn | Erm | ||
Well, I didn't particularly expect std to say it was OK! | |||
lue | perl6: multi sub term:<無>{Mu();}; | ||
jnthn | Given it has not one, but *two* unbalanced groping chars. | ||
p6eval | rakudo 43f865: OUTPUT«error:imcc:syntax error, unexpected '\n' in file 'EVAL_1' line 58» | ||
..elf 30353, pugs: ( no output ) | |||
jnthn | *grouping. | ||
oh wait | 00:49 | ||
I mis-read a curly as not a curly | |||
:-( | |||
jnthn is...too tired. | |||
lue | .oO(quick! how do you spell rakudo!) |
||
jnthn | rakudo: multi sub term:<無> { Mu(); }; | 00:50 | |
p6eval | rakudo 43f865: OUTPUT«error:imcc:syntax error, unexpected '\n' in file 'EVAL_1' line 58» | ||
jnthn | rakudo: multi sub infix:<無> { Mu(); }; | ||
p6eval | rakudo 43f865: ( no output ) | ||
jnthn | Oh, it's hosed on categories it doesn't grok. | ||
rakudo: multi sub omgMEDVED:<無> { Mu(); }; | |||
lue | .oO(an \n hydrant) |
||
p6eval | rakudo 43f865: OUTPUT«error:imcc:syntax error, unexpected '\n' in file 'EVAL_1' line 58» | ||
arnsholt | loliblogged | ||
jnthn | arnsholt: omfg where?! | 00:51 | |
lue | lolablagger | ||
arnsholt | Only took me a week to finish the damned post ^^ | ||
blogs.perl.org/users/arne_skjaerhol...cking.html | |||
I'm even starting to approach the point where I can start to try parsing som code and generating some ASTs | 00:53 | ||
Then we can see about generating some code | 00:54 | ||
wknight8111 | arnsholt++ | 00:55 | |
jnthn | arnsholt: Nice post! :-) | ||
wknight8111 | arnsholt: does that blog have a feed? I can't seem to find a link | ||
arnsholt | jnthn: Thank you! I'm still working on finding a tone and style that works for me, but I'm quite happy with that one | 00:56 | |
Looks like the front page links to blogs.perl.org/users/arne_skjaerholt/atom.xml | 00:57 | ||
lue | lolitschemistry (I'll stop now) | ||
wknight8111 | arnsholt++ # I've subscribed! | ||
arnsholt | (And exclusive behind-the-scenes info: What catalysed this post into being was the opening sentence coming to me as I was brushing my teeth =) | 00:58 | |
lue | It's an epiphany of semi-House proportions! (House proportions require people talking to you about random things) | 00:59 | |
arnsholt | Cool. Knowing that some people are looking at what I'm doing is certainly a good incentive to keep on working | ||
I tend to do anti-House epiphanies. I complain about my problems to someone that happens to be around, and find the solution in mid-sentence =) | 01:00 | ||
lue | that's also known as Active Epiphany. | 01:01 | |
.oO(I can't tell you how many sentences like your post's first I make in a day) |
|||
afk (and in IRC-midday too! ah well) | |||
01:08
snarkyboojum joined,
snarkyboojum left
|
|||
lisppaste3 | cognominal pasted "I added the missing pair syntaxes in nqp" at paste.lisp.org/display/97593 | 01:13 | |
cognominal | will go thru to src/Perl6/Actions.pm to use them | 01:14 | |
jnthn | It appears you patched the old NQP, not the new nqp-rx? | 01:15 | |
Rakudo uses the latter. | 01:16 | ||
cognominal | hum, let me see. | 01:17 | |
01:18
alester joined
|
|||
cognominal | yes, too bad. | 01:22 | |
I don't get it. rakudo mast does not pull nqp-rx? | 01:23 | ||
jnthn | No, it lives in etc/nqp-rx/ in Parrot. | ||
cognominal | why rakudo master does not use nqp-rx? | 01:24 | |
I am confused | |||
01:25
xabbu42 left
|
|||
cognominal | there are so much branches around, that I have trouble to follow things | 01:25 | |
arnsholt | From Rakudo's Makefile.in it does look like it uses Parrot's NQP | ||
Only references to nqp are "NQP_EXE = $(PARROT_BIN_DIR)/parrot-nqp$(EXE)" and a handful of files named .nqp | 01:26 | ||
cognominal | gen_parrot.pl pulls out : svn.parrot.org/parrot/trunk parrot | 01:28 | |
jnthn, I am completely lost there :( | 01:29 | ||
probably need some zzzz | |||
01:29
quietfanatic joined
|
|||
cognominal | so gen_parrot.pl pulls the new parrot but not nqp-rx... | 01:32 | |
anyway, even if my work is useless, I have learnt a lot in the process | 01:33 | ||
jnthn | cognominal: Rakudo master does use nqp-rx. | 01:34 | |
01:35
solu left
|
|||
cognominal | how can it if it only pulls the last parrot (which does not use nqp-rx)? | 01:35 | |
TimToady | std: constant 無 = Mu; | 01:37 | |
p6eval | std 30353: OUTPUT«ok 00:01 109m» | ||
TimToady | std: subset 無 of Mu; my 無 $x; | ||
p6eval | std 30353: OUTPUT«ok 00:01 107m» | ||
01:38
pausenclown joined
|
|||
TimToady | std: subset 無 of Mu; my 無 無 $x; | 01:38 | |
p6eval | std 30353: OUTPUT«===SORRY!===Multiple prefix constraints not yet supported at /tmp/016IAhnpTb line 1:------> subset 無 of Mu; my 無 無 ⏏$x;Compilation failedFAILED 00:01 107m» | ||
jnthn | Oh, subset should work in Rakudo. | ||
rakudo: subset 無 of Mu; my 無 $x; | |||
p6eval | rakudo 43f865: OUTPUT«Nominal type check failed for parameter '$original'; expected Any but got Mu insteadcurrent instr.: 'CREATE_SUBSET_TYPE' pc 336588 (src/gen/core.pir:17038)» | ||
jnthn | oh crap. | 01:39 | |
jnthn summons masak++ :-) | |||
pausenclown | rakudo: say 10.fmt("0x%s") | ||
p6eval | rakudo 43f865: OUTPUT«0x10» | ||
pausenclown | rakudo: say '10'.fmt("0x%s") | 01:40 | |
p6eval | rakudo 43f865: OUTPUT«0x10» | ||
TimToady | that seems relatively...useless... | ||
pausenclown | rakudo: say '50'.fmt("0x%s").chr | 01:41 | |
p6eval | rakudo 43f865: OUTPUT« | ||
pausenclown | rakudo: say '55'.fmt("0x%s").chr | ||
p6eval | rakudo 43f865: OUTPUT« | ||
pausenclown | rakudo: say "5065726C36".comb(/<xdigit>**2/)>>.fmt("0x%s")>>.chr | 01:42 | |
p6eval | rakudo 43f865: OUTPUT« | ||
pausenclown | rakudo: say "5065726C36".comb(/<xdigit>**2/)>>.fmt("0x%s") | 01:43 | |
p6eval | rakudo 43f865: OUTPUT«0x500x650x720x6C0x36» | ||
pausenclown | (published examples not working)-- | 01:45 | |
rakudo: my @array = <a b c>; for ^Inf Z @array -> $index, $item { say "$index, $item" } | 01:48 | ||
p6eval | rakudo 43f865: OUTPUT«0, a1, b2, c» | ||
pausenclown | rakudo: my @array = <a b c>; for 0..* Z @array -> $index, $item { say "$index, $item" } | 01:49 | |
p6eval | rakudo 43f865: OUTPUT«0, a1, b2, c» | ||
jnthn sleep, night o/ | |||
TimToady | rakudo: my @array = <a b c>; for ^* Z @array -> $index, $item { say "$index, $item" } | 01:53 | |
p6eval | rakudo 43f865: OUTPUT«0, a1, b2, c» | ||
TimToady | rakudo: my @array = <a b c>; for @array.kv -> $index, $item { say "$index, $item" } | ||
p6eval | rakudo 43f865: OUTPUT«0, a1, b2, c» | ||
pausenclown | how many elements has Inf..* ? ;-) | ||
TimToady | well, count 'em... | 01:54 | |
dinner & | |||
01:56
Psyche^ joined
01:58
hercynium joined
02:00
Psyche^ is now known as Patterner
|
|||
lue | aw, I just missed TimToady! (bye jnthn) | 02:01 | |
rakudo: my @a = Inf..*; for @array.kv -> $index, $item { say "$index, $item" } | 02:03 | ||
p6eval | rakudo 43f865: OUTPUT«Symbol '@array' not predeclared in <anonymous>current instr.: 'perl6;PCT;HLLCompiler;panic' pc 152 (compilers/pct/src/PCT/HLLCompiler.pir:108)» | ||
lue | rakudo: my @a = Inf..*; for @a.kv -> $index, $item { say "$index, $item" } | ||
p6eval | rakudo 43f865: ( no output ) | ||
02:19
frzntoz joined
02:30
wknight8111 left
02:31
mikehh joined
02:36
pausenclown left
|
|||
lue | afk | 02:56 | |
03:02
ash__ joined
03:17
fridim joined
|
|||
diakopter delurks | 03:20 | ||
03:32
am0c joined
03:40
TiMBuS left
03:41
am0c left
03:42
tylerni7 joined
03:53
meppel joined
03:54
meppel is now known as meppl
04:02
ash__ left
04:04
_jaldhar joined
|
|||
lue | oh hai whoevers der | 04:41 | |
04:44
hercynium left
04:52
eternaleye joined
|
|||
pugssvn | r30354 | lwall++ | [gimme5] support pointing to both ends of missing goal message | 04:52 | |
r30354 | [STD] "Couldn't find final" message now point to both ends | |||
r30354 | [STD] more tweaking of sorry messages and goal failure messages | |||
r30354 | [STD] standard quotes now use ~ construct to set goal | |||
r30354 | [STD] vws extra lines now eat line with \V* \v | |||
r30354 | [STD] suppress confusing backtracking on ~<< | |||
04:54
envi^home joined
|
|||
sorear | std: (some_big_function(subexp) | 05:00 | |
p6eval | std 30354: OUTPUT«===SORRY!===Unable to parse parenthesized expression; couldn't find final ')' at /tmp/nQlDnTyPiE line 1 (EOF):------> (some_big_function(subexp)⏏<EOL> expecting statement modifier loopUndeclared routines: 'some_big_function' used | ||
..at line … | |||
05:04
am0c joined
05:09
am0c left,
kaare joined
05:10
kaare is now known as Guest924
05:14
gfx joined,
Guest924 left
05:17
xinming_ joined
|
|||
TimToady | std: (some_big_function(subexp) | 05:21 | |
p6eval | std 30354: OUTPUT«===SORRY!===Unable to parse parenthesized expression; couldn't find final ')' at /tmp/yLllUVVPTh line 1 (EOF):------> (some_big_function(subexp)⏏<EOL> expecting statement modifier loopUndeclared routines: 'some_big_function' used | ||
..at line … | |||
TimToady | ENOTYET | ||
diakopter | I think std now gets rebuilt at the bottom of the hour | 05:24 | |
lue | .oO(ESTDNEVERWRONG (in addition, an EYOURFAULT error was returned.)) |
05:27 | |
05:28
am0c joined
|
|||
sorear | lue: rule 2 | 05:28 | |
lue | O great. There's a rule book? (next week I'll learn about Eastern Orthodox Camelism) | 05:29 | |
I guess rule 2 is "stay on topic" | 05:30 | ||
05:31
jrtayloriv joined
05:32
jrtayloriv left
|
|||
sorear | lue: It only has two rules | 05:34 | |
TimToady | std: (some_big_function(subexp) | 05:35 | |
p6eval | std 30354: OUTPUT«===SORRY!===Unable to parse parenthesized expression at /tmp/BJmfMnVNz9 line 1:------> (⏏some_big_function(subexp)Couldn't find final ')'; gave up at /tmp/BJmfMnVNz9 line 1 (EOF):------> (some_big_function(subexp)⏏<EOL> | ||
..… | |||
lue | std: [anArray[thatStatesthings] | 05:37 | |
p6eval | std 30354: OUTPUT«===SORRY!===Unable to parse array composer at /tmp/h5MNT7Gbln line 1:------> [⏏anArray[thatStatesthings]Couldn't find final ']'; gave up at /tmp/h5MNT7Gbln line 1 (EOF):------> [anArray[thatStatesthings]⏏<EOL> | ||
..expectin… | |||
lue | rule 1: camelCase is the only acceptable method of writing variable names with more than one word. :) | 05:38 | |
alpha: (my $words_of_joy = 3) andthen die('rule 1! rule 1!'); | 05:40 | ||
p6eval | alpha 30e0ed: OUTPUT«rule 1! rule 1!in Main (file /tmp/ufRLtbSzjd, line 0)» | 05:41 | |
diakopter | lue: see the 8th paragraph of perldoc.perl.org/perlhack.html#DESCRIPTION | 05:46 | |
lue | ...I was wrong about the rules by ~ 75 NaNometers | 05:49 | |
.oO(my rule 1&2 are good though (what to call them however...)) |
|||
I've heard of that before, I like the summary better (Larry is always right, even when he's wrong). I call it the right when wrong rule. :) | 05:50 | ||
05:52
frzntoz left
|
|||
lue | afk | 05:52 | |
06:01
frzntoz joined
06:31
alester left
06:43
Yunga left
|
|||
moritz_ | good morning | 07:14 | |
sorear | hello | ||
07:20
szabgabx joined
07:26
k23z__ joined
07:29
charnglinux_ joined,
charnglinux_ left
07:30
frzntoz left
07:31
masak joined
|
|||
masak | oh hai, #perl! | 07:31 | |
s/perl/perl6/ | |||
moritz_ | \o/ | 07:32 | |
masak mostly enjoys the Temporal discussions on p6l | |||
k23z__ | hai | 07:34 | |
hai masak | |||
I wants to ask if there is plans for symbolic computations like SymPy for Perl6 ? | 07:35 | ||
masak | no plans as far as I know. | ||
would be fun if someone made it a project. | |||
k23z__ | because I was trying recently to work out Math::Symbolic from Perl5 and I encountered serious problems at which point I switched to SymPy | 07:36 | |
sorear | "Not competing with Mathematica" is a stated design goal | ||
Rakudo build performance has increased 60 fold since I joined the project | |||
I just tried it, if finished in 13 minutes | 07:37 | ||
that's like, 1 month | |||
moritz_ | masak: do you agree with adding a Date-only type on Temporal? | ||
masak | moritz_: I'd tend to agree with anything autarch says :) | 07:38 | |
moritz_: what I am wondering is this: if there's to be a standalone Date type, is there also a need for a standalone Time type? | |||
maybe I should ask him that on the list... | |||
moritz_ | not sure | ||
k23z__ | anyone here know a good book on writing a Symbolic computation package ? | 07:40 | |
the main problem is that for example Math::Symbolic produces big expression trees that are hard to manipulate | |||
07:42
k23z__ is now known as kerz___
|
|||
moritz_ | I think that's the main problem with all CAS packages | 07:42 | |
because simplifying an expression tends to take exponential time | |||
kerz___ | well Math::Symbolic has Math::Symbolic::Custom::Transformation | 07:44 | |
with it you can write transformation for the expression trees | |||
07:44
mberends joined
|
|||
kerz___ | thus yielding bigger or smaller expressions depending on desire | 07:45 | |
but it has problems ... like for example I have to apply a lot of time some transformations to get the desired result | |||
and when I print my expression it has lots of redundant parenthesis | 07:46 | ||
masak | mberends! | ||
moritz_ | std: 'a' ~<< 1, 2 | ||
p6eval | std 30354: OUTPUT«===SORRY!===Unable to parse quote words at /tmp/R8tKpiVD7m line 1:------> 'a' ~<<⏏ 1, 2Couldn't find final '>'; gave up at /tmp/R8tKpiVD7m line 1 (EOF):------> 'a' ~<< 1, 2⏏<EOL>Compilation failedFAILED 00:01 109m» | ||
mberends | \o masak, I suggest a 'use Date' and Date.pm6 as an immediate solution | ||
for the question of whether Date as a type should be in core | 07:47 | ||
(I prefer to avoid core bloat) | 07:48 | ||
masak | I can definitely agree with that perspective. | 07:50 | |
it's still debatable whether DateTime itself belongs in core... | 07:51 | ||
mberends | we're starting to see candidate modules to be shipped with Rakudo * | ||
masak: well we need something time-related in the core, it's always a matter of drawing the line | 07:52 | ||
masak | *nod* | 07:53 | |
mberends | masak: something derived from proto's Installer.pm and Ecosystem.pm will also go into Rakudo * ;) | ||
and we have Test.pm and Safe.pm. I hope we begin copying them all to ~/.perl6/lib/ soon | 07:54 | ||
moritz_ | nope | ||
packages shipped with rakudo belong in the rakudo install dir | 07:55 | ||
so that a site wide install gets all the modules | |||
mberends | yes, that's better | 07:56 | |
07:57
Su-Shee joined
07:58
meppl left
|
|||
moritz_ has a new display, 24" Dell wide screen | 07:58 | ||
sad that non-wide-screen monitors in that size aren't cheap | 07:59 | ||
Su-Shee | good morning. | ||
mberends | the movie industry is setting the hardware specs for the computer industry | 08:00 | |
masak | Su-Shee: \o | ||
Su-Shee | sad that displays with a nice resolution are seriously expensive :/ | ||
moritz_ | aye | ||
\o/ melange sorting bug fix is shipped | 08:01 | ||
/o\ but I can't view any proposals :( | 08:02 | ||
08:04
gfx left
|
|||
masak | I got GGE to build on master yesterday. | 08:10 | |
but it fails the 03-optable.t tests with 'Null PMC access in can()'... will investigate that next. | 08:11 | ||
moritz_ | Null PMC access in can() - that rings a bell | 08:12 | |
masak | current instr.: '&infix:<=>' | 08:14 | |
if that helps. | |||
moritz_ | rakudo: use Test; plan 1; isa_ok (1|2), Junction | 08:15 | |
p6eval | rakudo 43f865: OUTPUT«1..1Null PMC access in get_iter()current instr.: '!DISPATCH_JUNCTION_CORE' pc 16360 (src/builtins/Signature.pir:151)» | ||
moritz_ | hm, not can() | ||
masak | it will be interesting to see what is the cause of this :) | ||
moritz_ | code.google.com/p/soc/issues/detail?id=869 | 08:19 | |
masak | typical adaptation of a mid-sized Perl 6 application to new Rakudo master: github.com/masak/gge/commit/839bd22...7d1e9560c9 | 08:28 | |
moritz_ | masak: how do you know it's typical? | 08:36 | |
08:37
snarkyboojum joined
|
|||
masak | because I've already done one before. :) | 08:38 | |
moritz_ | my changes to JSON::Tiny looked quite different | 08:39 | |
but that was in an earlier stage of rakudo | |||
and JSON::Tiny is much smaller | |||
masak | *nod* | ||
the November adaptation was a little bit less involved: github.com/viklund/november/commit/...5fa5f8d4cc | 08:48 | ||
my mom is showing me a bunch of plants, some of them of the Camelia family. :) apparently, the tea plant belongs in this family. | 08:53 | ||
s:g/family/genus/ | |||
08:54
fridim_ joined
08:55
am0c left
08:57
fridim left
09:04
JimmyZ joined
09:07
sorear joined
|
|||
masak | wow, we've come a long way since this: www.perlmonks.org/index.pl?node_id=434972 | 09:09 | |
we no longer allow subs to be called as methods. | |||
09:09
jrtayloriv joined
|
|||
masak | I'm not sure *$x means the same in a signature... maybe, maybe not. | 09:10 | |
we do, however, allow subs to be automatically created from methods, though 'is export'. | 09:12 | ||
09:15
kerz___ left,
jrtayloriv left
09:27
jhuni left
09:33
JimmyZ left
|
|||
masak | jnthn++ # parrot-dev email | 09:38 | |
09:41
payload joined,
am0c joined
|
|||
masak | rakudo: sub infix:<;>($a, $b) { $a + $b }; say 40; 2 | 09:42 | |
p6eval | rakudo 43f865: OUTPUT«42Method 'Num' not found for invocant of class 'Perl6Sub'current instr.: 'perl6;Mu;' pc -1 ((unknown file):-1)» | ||
masak cackles | |||
09:43
payload1 joined,
payload left
|
|||
masak | rakudo: sub infix:<;>($a, $b) { $a + $b } say 40; 2 | 09:43 | |
p6eval | rakudo 43f865: OUTPUT«42» | ||
09:43
payload1 left
|
|||
masak | whoa :) | 09:43 | |
09:43
payload joined
|
|||
masak | rakudo: sub infix:<#>($a, $b) { $a ~ $b }; say 'OH' # "HAI" | 09:44 | |
p6eval | rakudo 43f865: OUTPUT«OH» | ||
masak | oh. | ||
09:44
payload left,
payload joined
|
|||
masak | probably gets eaten by the whitespace monster. | 09:44 | |
rakudo: sub infix:<,>($a, $b) { $a + $b }; say 1, 2, 3 | 09:45 | ||
p6eval | rakudo 43f865: OUTPUT«123» | ||
masak | and there's a comma monster, too :) | ||
& | |||
sorear | sorry if this is too much traditionalthink, but why would a comment NOT take precedence over an infix operator? | ||
moritz_ | sorear: it's an implementation detail | 09:46 | |
09:48
jhuni joined,
payload left
|
|||
moritz_ | basically the rule that eats up the witespace before the # also eats the whole comment | 09:52 | |
which is quite sane in terms of parsing speed | |||
masak | sorear: I'd tend to agree with you. as far as I know, the spec doesn't say which things override operators and which don't. as usual, I'm looking for ways to achieve consistency. | 10:28 | |
sorear | std: sub infix:<#>($a, $b) { ... }; say 1 # syntax`error | 10:29 | |
p6eval | std 30354: OUTPUT«ok 00:01 110m» | ||
10:32
M_o_C joined
10:35
wknight8111 joined
10:48
masak left
10:55
M_o_C left
|
|||
jnthn | o/ | 11:07 | |
masak++ # Moving to master \o/ | 11:15 | ||
12:07
broquaint joined,
CokeBot9000 joined
12:08
payload joined
12:17
payload left
12:55
wknight8111 left
13:01
am0c left
|
|||
jnthn afk, herrfest | 13:13 | ||
13:20
noobn joined
13:21
payload joined
13:33
noobn left
13:36
payload left,
payload joined
13:43
pmurias joined
|
|||
cognominal now makes sense of rakudo using nqp-rx. I guess this now should be the default. | 13:45 | ||
13:45
szabgabx left
13:50
noobn joined
13:51
szabgabx joined
13:54
alester joined
14:01
ash__ joined
14:03
noobn left
14:07
alester left
14:09
agentzh joined
|
|||
moritz_ | rakudo: ([0, 0], [1, 1]).grep({say .perl; 1}).eager; | 14:13 | |
p6eval | rakudo 43f865: OUTPUT«[0, 0][1, 1]» | ||
14:15
xinming_ left
14:16
xinming joined
14:24
jhuni left
14:25
mikehh left
14:26
ash__ left
14:28
frzntoz joined
14:43
agentzh left
14:44
ash__ joined
14:48
TiMBuS joined
|
|||
moritz_ | rakudo: say [X] [<a b c>] xx 3 | 14:50 | |
p6eval | rakudo 43f865: ( no output ) | ||
moritz_ | rakudo: say [X] <a b c> xx 3 | ||
p6eval | rakudo 43f865: ( no output ) | ||
14:55
mikehh joined
14:56
athomaso1 left
14:57
arthur-_ joined
15:02
colomon joined
|
|||
colomon | we can haz intertubez? | 15:02 | |
moritz_ | seemz like you haz | 15:03 | |
15:05
mdxi joined
|
|||
pugssvn | r30355 | moritz++ | [t/spec] tests for RT #67948, .perl in .grep with arrays in the list | 15:06 | |
15:08
athomason joined
15:09
colomon left
15:11
synth joined
15:12
synth left
15:17
frzntoz left
15:18
clintongormley joined
15:24
meppl joined
15:29
payload left
|
|||
moritz_ | when I write a Date module, should I handled years > 9999? | 15:31 | |
:-) | |||
ash__ | what about years less than 1900? or in BC? | ||
:p | |||
(lots of date tools don't go very far backwards) | |||
moritz_ | less than 1900 can still be written as 0120 or so | ||
ash__ | how are you planning on storing the year? i don't see why it should stop at 9999 | 15:33 | |
TimToady | and year 1 BC is really 0 AD, and 2 BC is -1 AD, and so on. :) * 1/3 | 15:36 | |
moritz_ | ash__: integers... It's more about allowed formats for the constructor | 15:40 | |
ash__: but in the end I think it's sane to allow Date.new('YYYY-MM-DD') for years 0 to 9999, and require Date.new(:year(2e6), :day(), :month()) for all years outside that range | |||
ash__ | doesn't YYYY-MM-DD have a name? | 15:45 | |
like, that style of format | |||
moritz_ | yep, some ISO-$forgotthatnumber short format | ||
pugssvn | r30356 | lwall++ | [STD] inside quotes, when expecting a postfix extension, | 15:46 | |
r30356 | presume that a backslash belongs to the quotes and is not an unspace | |||
ash__ | you could do Date.iso-8601('YYYY-MM-DD') format | 15:47 | |
i should probably read the new temporal before i start making stupid suggestions though | |||
moritz_ | after the discussion today or yesterday I thought I'd prototype a Date (no time) module | 15:48 | |
and then ask people if they want something like that in core or not | |||
s/not/as an external module/ | |||
anway, going away for a while... | 15:49 | ||
ash__ | Date.new just seems vague, IMO | ||
i am obviously nit-picking the name of the constructor, but in this case i think Date.new can be confusing because there are so many different ways you can construct a date, being explicit might be useful to the date module to reduce confusion | 15:51 | ||
moritz_ | that's why I want MMD and awesome error messages | 15:52 | |
and a very narrow selection of allowed things | |||
ash__ | Date.now (new date with the current time), Date.iso-8601, etc. | ||
moritz_ | Date.today() | ||
ash__ | yeah, that makes me since, .now would be a time thing, not a date specifically | ||
moritz_ | really afk & | 15:53 | |
15:53
am0c joined
15:55
snarkyboojum left
15:56
fridim_ left
15:57
colomon joined
|
|||
colomon | we can haz intertubez -- fur realz? | 15:58 | |
16:01
synth joined
|
|||
diakopter | o_o | 16:03 | |
colomon | \o/ | 16:04 | |
ash__ | having intertubz is fun | ||
diakopter | \o_o/ | ||
synth imagines his tub being wired for the internet | 16:05 | ||
16:09
justatheory joined,
wknight8111 joined
16:10
am0c left
|
|||
pugssvn | r30357 | colomon++ | [Numeric] Move sqrt to Numeric. Remove incorrect return value type of roots. Move cis and unpolar to Real. Add to-radians and from-radians to Numeric. | 16:10 | |
16:11
am0c joined
16:15
M_o_C joined
|
|||
lue | y o hai! | 16:15 | |
colomon | o/ | ||
16:20
noobn joined
16:21
noobn left
|
|||
lue | 知無時! (wisdom ignorance time!) | 16:22 | |
16:23
am0c left
|
|||
avar | eval: my $foo; my $bar; my $n; $foo [1] [$bar] [$n + 7]; | 16:28 | |
pugssvn | r30358 | lwall++ | [STD] dwim texas <<>> better | 16:30 | |
lue | .oO(Larry's trying to DWIM Texas? How is that possible! (wonder what the <<>> are all about, though)) :) |
16:31 | |
mberends | lue: wonder no more. Enter Texas in the search box at the top of perlcabal.org/syn/ | 16:35 | |
lue | rakudo: my @a=1,3; say (ff @a) | 16:37 | |
p6eval | rakudo 43f865: OUTPUT«Could not find sub &ffcurrent instr.: '_block14' pc 29 (EVAL_1:0)» | ||
lue | what exactly do the ff and fff operators do? (looking...) | ||
TimToady | std: 1 <<+<< 2 | 16:38 | |
p6eval | std 30357: OUTPUT«ok 00:01 109m» | ||
TimToady | std: 1 <<+<<< 2 | ||
p6eval | std 30357: OUTPUT«===SORRY!===Unable to parse quote words at /tmp/WxurMP6nrX line 1:------> 1 <<+<<<⏏ 2Couldn't find final '>'; gave up at /tmp/WxurMP6nrX line 1 (EOF):------> 1 <<+<<< 2⏏<EOL>Compilation failedFAILED 00:01 107m» | ||
TimToady | darn, missed the boat | ||
std: my $x; "$x\[nonesuch\]"; | 16:39 | ||
p6eval | std 30357: OUTPUT«ok 00:01 107m» | ||
lue | .oO(don't worry, the boat's coming back!) |
||
TimToady | in an hour :( | ||
well, I'll go take a walk | |||
bbl & | |||
lue | rakudo: say 1..3; say 1 ff 3 | ||
p6eval | rakudo 43f865: OUTPUT«Confused at line 11, near "say 1 ff 3"current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)» | 16:40 | |
lue | alpha: say 1..3; say 1 ff 3 | ||
p6eval | alpha 30e0ed: OUTPUT«Confused at line 10, near "ff 3"in Main (file <unknown>, line <unknown>)» | ||
lue | perl6: say 1..3; say 1 ff 3 | ||
p6eval | pugs: OUTPUT«123*** No such subroutine: "&infix:ff" at /tmp/Wj6sKWTly2 line 1, column 15 - line 2, column 1» | ||
..elf 30358: OUTPUT«Undefined subroutine &GLOBAL::infix_ff called at (eval 125) line 4. at ./elf_h line 5881123» | |||
..rakudo 43f865: OUTPUT«Confused at line 11, near "say 1 ff 3"current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)» | |||
16:40
holli joined
|
|||
lue | :/ i guess it's still NYI then | 16:41 | |
16:41
szabgabx left
|
|||
lue | rakudo: Inf.int.say; NaN.int.say | 16:44 | |
p6eval | rakudo 43f865: OUTPUT«Method 'int' not found for invocant of class 'Num'current instr.: '_block14' pc 29 (EVAL_1:0)» | ||
lue | rakudo: Inf.Num.say; NaN.Num.say | ||
p6eval | rakudo 43f865: OUTPUT«InfNaN» | ||
lue | \o/ I guess that means #61602 is no more! (now to make sure there are tests...) | 16:45 | |
16:50
M_o_C left
|
|||
mberends | phenny, tell moritz_ nice to see a pure Date module, hopefully 'perldoc Date::Simple' is an appropriate feature set. | 16:51 | |
phenny | mberends: I'll pass that on when moritz_ is around. | ||
lue | rakudo: say (Inf.Num == Inf) | 16:53 | |
p6eval | rakudo 43f865: OUTPUT«1» | ||
lue | std: Inf.int.say | 16:54 | |
p6eval | std 30357: OUTPUT«ok 00:01 106m» | ||
lue | is it OK for int to die on Inf.int and NaN.int ? | ||
mberends | rakudo: say Inf+1 | ||
p6eval | rakudo 43f865: OUTPUT«Inf» | 16:55 | |
mberends | rakudo: say Inf+1 == Inf | ||
p6eval | rakudo 43f865: OUTPUT«1» | ||
mberends | therefore 1 == 0 ? | ||
lue | I'm just wondering if .int dying on Inf and NaN is because of implementation or because that's how it's supposed to be. | ||
( wouldn't want to test for something implementation-specific ;) ) | 16:56 | ||
mberends | probably implementation. Inf should not allow all these operations. | ||
lue | so Inf.Num must die as well? | 16:57 | |
Although .Num returns either Inf or NaN (depending), they aren't numbers. They're concepts. | |||
mberends | yes, that would make sense imho. But maybe someone with a stronger mathematical background can show how some operations do make sense. | 16:58 | |
lue | rakudo: say (Inf+1,Inf-1,Inf*1,Inf/1).join('\n') | ||
p6eval | rakudo 43f865: OUTPUT«Inf\nInf\nInf\nInf» | ||
mberends | whacky | 16:59 | |
lue | rakudo: say (Inf+1,Inf-1,Inf*1,Inf/1).join("\n") # *cough* | ||
p6eval | rakudo 43f865: OUTPUT«InfInfInfInf» | ||
lue | rakudo: say (Inf+1,Inf-1,Inf*2,Inf/2).join("\n") # this would be a more conclusive test :) | ||
p6eval | rakudo 43f865: OUTPUT«InfInfInfInf» | ||
lue | my @a=1..3; say @a ~~ Inf | 17:00 | |
mberends | rakudo: say Inf / Inf # heading for insanity | ||
p6eval | rakudo 43f865: OUTPUT«NaN» | ||
lue | rakudo: my @a=1..3; say @a ~~ Inf # *cough* | ||
p6eval | rakudo 43f865: OUTPUT«0» | ||
lue | rakudo: my @a=1..3; say @a ~~ (-Inf..Inf) | ||
p6eval | rakudo 43f865: OUTPUT«1» | ||
diakopter | std: 1 <<+<<< 2 | 17:01 | |
p6eval | std 30358: OUTPUT«ok 00:01 109m» | ||
lue | well, I'll be back soon (probably in ~ half-an-hour, considering that's when TimToady might come back), and discuss how Inf and NaN are handled :) | 17:03 | |
(rule 1!) | |||
holli | is there a way to make this dwim? | 17:05 | |
rakudo: say "2" ~~ /{ 1+1 }/ | |||
p6eval | rakudo 43f865: OUTPUT«» | ||
holli | should be 1 | ||
ash__ | diakopter: is there a <<< operator? or is that going to be split into a << and < | 17:12 | |
holli | .oO( >>>, same as >> but may spread calculations across alternative universes) |
17:13 | |
mberends | rakudo: say "2" ~~ / "2" { say "seen two" } / | 17:15 | |
p6eval | rakudo 43f865: OUTPUT«seen two2» | ||
17:15
alester joined
|
|||
mberends | holli: the / { ... } / is not part of the pattern to match, it's an action | 17:16 | |
holli | rakudo: say "3" ~~ / [ "2" { say "seen two" } | { say "where is the two?" } ] / | ||
p6eval | rakudo 43f865: OUTPUT«where is the two?» | ||
holli | mberends: yes, i know. question was how to make the return value of the action become part of the pattern. | 17:17 | |
mberends | holli: sorry, can't help you with that | 17:18 | |
17:18
alester left,
Su-Shee left,
am0c joined
17:26
ash__ left
|
|||
TimToady | rakudo: say "2" ~~ / <{ 1+1 }> / | 17:33 | |
p6eval | rakudo 43f865: OUTPUT«» | ||
17:33
Su-Shee joined
|
|||
TimToady | rakudo: say "2" ~~ / <{ ~(1+1) }> / | 17:33 | |
p6eval | rakudo 43f865: OUTPUT«» | ||
TimToady | well, that's supposed to work | ||
holli | lol | 17:34 | |
TimToady | rakudo: say "2" ~~ / $(1+1) / | ||
p6eval | rakudo 43f865: OUTPUT«» | ||
holli | i can literaly here the *sigh* | ||
17:34
alester joined
|
|||
TimToady | rakudo: say "2" ~~ / $(~(1+1)) / | 17:34 | |
p6eval | rakudo 43f865: OUTPUT«Confused at line 11, near "say \"2\" ~~"current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)» | ||
TimToady | std: say "2" ~~ / $(~(1+1)) / | 17:35 | |
p6eval | std 30358: OUTPUT«ok 00:02 111m» | ||
TimToady | std: say "2" ~~ / :my $x = 1+1; $x / | ||
p6eval | std 30358: OUTPUT«ok 00:01 108m» | ||
TimToady | rakudo: say "2" ~~ / :my $x = 1+1; $x / | ||
p6eval | rakudo 43f865: OUTPUT«» | 17:36 | |
TimToady | rakudo: say "2" ~~ / :my $x = ~(1+1); $x / | ||
p6eval | rakudo 43f865: OUTPUT«» | ||
TimToady | rakudo: say "2" ~~ / :my $x = '2'; $x / | ||
p6eval | rakudo 43f865: OUTPUT«» | ||
TimToady | rakudo: my $x; say "2" ~~ / { $x = '2'} $x / | ||
p6eval | rakudo 43f865: OUTPUT«» | ||
holli | what's the colon supposed to do? | ||
TimToady | let you put a declarator | 17:37 | |
rakudo: my $x = '2'; say "2" ~~ / $x / | |||
p6eval | rakudo 43f865: OUTPUT«» | ||
lue | rakudo: Inf.Num.say # should this work? | ||
p6eval | rakudo 43f865: OUTPUT«Inf» | ||
TimToady | I thought that worked once | ||
lue: sure | 17:38 | ||
lue | so that would be valid to test for in the spectest? (Inf.Num ~~ Inf) | ||
TimToady | rakudo: Inf.Int.say # this is also supposed to work | ||
p6eval | rakudo 43f865: OUTPUT«-9223372036854775808» | ||
TimToady | but not like that :/ | 17:39 | |
lue | ah, lowercasing doesn't work :) | ||
17:39
ash__ joined
|
|||
TimToady | rakudo: Inf.int.say # should blow up | 17:39 | |
lue | Inf.int (note lowercase int) used to return -2147483648 | ||
p6eval | rakudo 43f865: OUTPUT«Method 'int' not found for invocant of class 'Num'current instr.: '_block14' pc 29 (EVAL_1:0)» | ||
TimToady | int is a native type, and therefore can't hold Inf | 17:40 | |
only native num can hold Inf | |||
lue | rakudo: say -9223372036854775808 ~~ Inf | ||
TimToady | since IEEE defined it that way | ||
p6eval | rakudo 43f865: OUTPUT«0» | ||
lue | so #61602 is still a mystery :/ | ||
I can't help but feel uneasy that Inf and NaN are defined as numbers... | 17:41 | ||
17:42
alester left
|
|||
holli reads something like "get_hll_global $P24, ["XML";"Parser";"Namespace"], "_block23"" and quickly decides to close that file again | 17:43 | ||
17:44
cls_bsd joined
|
|||
lue | rakudo: say Inf.WHAT | 17:45 | |
p6eval | rakudo 43f865: OUTPUT«Num()» | ||
lue | rakudo: say NaN.WHAT | ||
p6eval | rakudo 43f865: OUTPUT«Num()» | ||
colomon | At one point we were muttering about maybe making Inf and NaN their own types, instead of making them values of every Numeric (Real?) type... | ||
lue | .oO(Not A Number is Num....) |
17:46 | |
17:46
alester joined
|
|||
lue | (again, the thought of a dependency-tree-like method of defining numbers is thought) | 17:47 | |
maybe NaN and Inf can be defined as a Concept, and not a Num :) | 17:48 | ||
17:49
alester left
|
|||
lue | rakudo: say Inf.Num.Int | 17:50 | |
p6eval | rakudo 43f865: OUTPUT«-9223372036854775808» | ||
lue wonders what posesses rakudo/parrot to return that as an Int | |||
lue (of Inf, of course) | 17:51 | ||
holli | It "feels" right, imho | 17:53 | |
I mean, why should Inf be fractional? | 17:54 | ||
17:54
am0c left
|
|||
holli | rakudo: say Inf ** Inf | 17:55 | |
p6eval | rakudo 43f865: OUTPUT«Inf» | ||
17:56
kst joined
|
|||
lue | why should Inf be an integer? It's not a number, it's a concept. | 17:56 | |
17:59
dj_goku joined
|
|||
lue | what I meant was why return that number? | 17:59 | |
holli | A concept of an arbitrarily large number | ||
lue | rakudo: say "17".fmt('%b') | 18:00 | |
p6eval | rakudo 43f865: OUTPUT«10001» | ||
lue | rakudo: say "-9223372036854775808".fmt('%b') | ||
p6eval | rakudo 43f865: OUTPUT«1000000000000000000000000000000000000000000000000000000000000000» | ||
lue | rakudo: say "-9223372036854775808".fmt('%b').chars | ||
p6eval | rakudo 43f865: OUTPUT«64» | ||
holli | there u got ur answer =) | 18:01 | |
nice catch | |||
lue | THAT'S IT! That's why it returns that number as Inf! | ||
holli | it it probably lower on my old 32 bit laptop | ||
yup. here it says -2147483648 | 18:02 | ||
rakudo: say :2(-2147483648) | |||
p6eval | rakudo 43f865: OUTPUT«DON'T PANIC! Invalid character (-)! Please try again :) current instr.: '&radcalc' pc 12048 (src/builtins/Parcel.pir:78)» | ||
lue | 2147483647 is what my computer says (G3 PPC) | 18:03 | |
holli | rakudo: say :2<-2147483648> | ||
p6eval | rakudo 43f865: OUTPUT«Malformed radix number at line 11, near "<-21474836"current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)» | ||
lue | try -2147483648.fmt('%b'). That's how you convert _to_ | ||
holli: you have 32-bit intel, correct? | 18:04 | ||
holli | rakudo: say :16(20) | 18:05 | |
p6eval | rakudo 43f865: OUTPUT«32» | ||
holli | rakudo: say :2(100) | ||
p6eval | rakudo 43f865: OUTPUT«4» | ||
holli | ah, thats the other way aŕound =) | ||
lue | rakudo: say :4(222) | ||
p6eval | rakudo 43f865: OUTPUT«42» | ||
holli | honestly i have now idea what processor this is. but 32 bit, for sure | 18:06 | |
lue | who manufactured the computer? | ||
holli | Its a Thinkpaf | ||
lue | rakudo: say "-2147483648".fmt('%b') | ||
p6eval | rakudo 43f865: OUTPUT«1111111111111111111111111111111110000000000000000000000000000000» | ||
holli | *Thinkpad | ||
lue | then it's most likely intel | ||
18:06
M_o_C joined
|
|||
lue | rakudo: say :2(1111111111111111111111111111111110000000000000000000000000000000) | 18:07 | |
p6eval | rakudo 43f865: OUTPUT«DON'T PANIC! Invalid character (8)! Please try again :) current instr.: '&radcalc' pc 12048 (src/builtins/Parcel.pir:78)» | ||
holli discovers the sticker where it says Centrino and feels a bit silly | |||
lue | ō.o wow | ||
how did the 8 get there? | |||
holli | rakudo: say :2(1111111) | 18:08 | |
p6eval | rakudo 43f865: OUTPUT«127» | ||
holli | rakudo: say :2(11111111) | ||
p6eval | rakudo 43f865: OUTPUT«255» | ||
holli | rakudo: say :2(111111111) | ||
p6eval | rakudo 43f865: OUTPUT«511» | ||
holli | rakudo: say :2(1111111111) | ||
p6eval | rakudo 43f865: OUTPUT«1023» | ||
holli | rakudo: say :2(1111111111111) | ||
p6eval | rakudo 43f865: OUTPUT«8191» | ||
holli | rakudo: say :2(1111111111111111) | ||
p6eval | rakudo 43f865: OUTPUT«65535» | ||
holli | rakudo: say :2(1111111111111111111) | ||
p6eval | rakudo 43f865: OUTPUT«524287» | ||
holli | rakudo: say :2(1111111111111111111111) | ||
p6eval | rakudo 43f865: OUTPUT«DON'T PANIC! Invalid character (4)! Please try again :) current instr.: '&radcalc' pc 12048 (src/builtins/Parcel.pir:78)» | ||
lue | 10000000000000000000000000000000 is what it should be. (now to go talk to who implemented .fmt) | ||
holli | rakudo: say :2(111111111111111111111) | ||
p6eval | rakudo 43f865: OUTPUT«DON'T PANIC! Invalid character (4)! Please try again :) current instr.: '&radcalc' pc 12048 (src/builtins/Parcel.pir:78)» | ||
holli | rakudo: say :2(11111111111111111111) | ||
p6eval | rakudo 43f865: OUTPUT«DON'T PANIC! Invalid character (-)! Please try again :) current instr.: '&radcalc' pc 12048 (src/builtins/Parcel.pir:78)» | ||
holli | rakudo: say :2(1111111111111111111) | ||
p6eval | rakudo 43f865: OUTPUT«524287» | 18:09 | |
lue | rakudo: say radcalc('1111111111111111111111',2,10) | ||
p6eval | rakudo 43f865: OUTPUT«DON'T PANIC! The radix is out of range (2..36 only)current instr.: '&radcalc' pc 12048 (src/builtins/Parcel.pir:78)» | ||
lue | rakudo: say radcalc('1111111111111111111111',2) | ||
p6eval | rakudo 43f865: OUTPUT«DON'T PANIC! The radix is out of range (2..36 only)current instr.: '&radcalc' pc 12048 (src/builtins/Parcel.pir:78)» | ||
lue goes to look at radcalc again | |||
rakudo: say radcalc(2,'1111111111111111111111') | 18:10 | ||
p6eval | rakudo 43f865: OUTPUT«4194303» | ||
lue | rakudo: say :2(1111111111111111111111) | ||
p6eval | rakudo 43f865: OUTPUT«DON'T PANIC! Invalid character (4)! Please try again :) current instr.: '&radcalc' pc 12048 (src/builtins/Parcel.pir:78)» | ||
lue | good, it's a problem with the :[number] code, not with the radcalc helper function (which helps :[number]) | 18:11 | |
holli | rakudo: say :2('1111111111111111111111') | ||
p6eval | rakudo 43f865: OUTPUT«4194303» | ||
holli | rakudo: say :2('11111111111111111111111111') | ||
p6eval | rakudo 43f865: OUTPUT«67108863» | ||
holli | now that is strange | 18:12 | |
pugssvn | r30359 | lwall++ | [S02] explicate (non)-relationship of interpolation and whitespace/unspace | ||
holli | or maybe not. | ||
rakudo: say :2('111111111111111111111111111111111111111111111111111') | |||
p6eval | rakudo 43f865: OUTPUT«2.25179981368525e+15» | 18:13 | |
lue | apparently, you need to string your number if it's big ō.o | ||
holli | that makes sense. No number could become bigger than the systems llimit anyway. | 18:14 | |
TimToady | rakudo doesn't actually support Int yet | ||
18:15
synth left
|
|||
TimToady | Int is arbitrary precision, including Inf :) | 18:15 | |
well, arbitrary size, to be precise | |||
all integers have the same precision :) | |||
lue | a precision of 1, correct? | 18:16 | |
rakudo: say '2147483647'.fmt('%b') | |||
p6eval | rakudo 43f865: OUTPUT«1111111111111111111111111111111» | ||
TimToady | well, it will depend on how you define precision, of course | ||
lue | rakudo: say '2147483647'.fmt('%b').chars | ||
p6eval | rakudo 43f865: OUTPUT«31» | ||
holli | rakudo: say -1 ** 0.5 | ||
p6eval | rakudo 43f865: OUTPUT«-1» | ||
TimToady | they're not equally precise under the "digits of precision" definition | ||
holli | ahemm. =) | ||
TimToady | rakudo: say (-1) ** 0.5 | 18:17 | |
p6eval | rakudo 43f865: OUTPUT«NaN» | ||
lue | that's should be i (for imaginary), actually | ||
TimToady | you will note that the precedence of ** is tighter than symbolic unaries | 18:18 | |
lue | isn't that how it works in math? | ||
18:18
iblechbot joined
|
|||
TimToady | yes, but holli seems to expect -1 ** 0.5 to make i | 18:18 | |
where -1 is the correct answer | |||
holli | expect is maybe a big word =) | 18:19 | |
*too big | |||
TimToady expectorates when he wants a big word | |||
colomon | rakudo: (-1 + 0i) ** .5 | ||
p6eval | rakudo 43f865: ( no output ) | ||
colomon | rakudo: say (-1 + 0i) ** .5 | ||
p6eval | rakudo 43f865: OUTPUT«6.12323399573677e-17 + 1i» | ||
holli | sure, make fun of the non native speakers ;-) | 18:20 | |
holli goes looking up expectorate | |||
TimToady | I have nothing against the Romans... | ||
lue | I hate them, except for the irrigation system :) | 18:21 | |
'Romani Ite Domum' | |||
TimToady | Roman Meal bread is pretty good, except I'm allergic to it. | ||
sigh | |||
taxes & | |||
lue | .oO(let us all mourn for Larry) |
||
lue thinks of annoying the math teacher by say exponents are tighter than negation | 18:22 | ||
holli | lue: 5 + 2 * 3 - 1 | ||
lue | "So, you do multiplication first, and then addition, and--" "So, multiplication is tighter than addition?" "what?" | 18:23 | |
colomon: now we see the violence inherent in the system! (and by that I mean the murderous error given by rakudo) | 18:25 | ||
holli opens a Can Of Pittiness (+10 Adorabilty) for TimToady | |||
rakudo: say Inf - Inf | 18:26 | ||
p6eval | rakudo 43f865: OUTPUT«NaN» | ||
lue | shouldn't that be 0? Or maybe it's Inf? Or maybe... .oO(AAAAAAAAAAAAAAAAAAAAAAAAAAAHHHHHHHHHHHHHHH!!) | 18:27 | |
ash__ | Inf +|-|*|/|% Inf should be Inf | ||
holli considers Inf - Inf to be special case | 18:28 | ||
No rule without exception =) | |||
ash__ | but there is no magnitude on the Inf, and who's to say that two Inf's are the same value of Inf? | 18:29 | |
18:29
nihiliad joined
|
|||
ash__ | if you know that it might as well be a number | 18:29 | |
lue | .oO(aleph and beth numbers in my head again) as I love saying: It's NaN, it's a concept. |
||
holli | rakudo: say 2*Inf < 3*Inf | ||
p6eval | rakudo 43f865: OUTPUT«0» | ||
holli | ;-D | 18:30 | |
rakudo: say 2*Inf == 3*Inf | |||
p6eval | rakudo 43f865: OUTPUT«1» | ||
holli | rakudo: say Nan.WHAT | 18:31 | |
p6eval | rakudo 43f865: OUTPUT«Could not find sub &Nancurrent instr.: '_block14' pc 29 (EVAL_1:0)» | ||
holli | rakudo: say NaN.WHAT | ||
p6eval | rakudo 43f865: OUTPUT«Num()» | ||
holli | Now, THAT is paradox. ^^ | ||
ash__ | lol, its a special kind of number, like imaginary ones | 18:32 | |
lue | exactly. I'm thinking of the next #rs be about the state of the implementation of numbers. | ||
(of course, not my decision, but...) | |||
mberends | "It's Number, Jim, but not as we know it..." | ||
holli | next #rs? | 18:33 | |
mberends++ # Master of Star Trek (Original) References | 18:34 | ||
lue | short for the #rakudosketch channel. It's to discuss the design & progress of rakudo. | ||
holli | aha, well, i looked at PIR code today. | 18:35 | |
so i dont want to have nothing to do with your #rs =) | |||
18:36
envi^home left
|
|||
lue | Well, then I guess I'm part of the JPF (or is it the PFJ? I can't remember) :) | 18:36 | |
colomon | splitter! | 18:37 | |
mberends | future #rakudosketch meetings will probably happen on Tuesdays at 19:00 UTC | ||
lue | 11 AM (for me) on Tuesday? aw :( | 18:38 | |
There's no way I could make that until summer! :/ | 18:39 | ||
holli | mberends++ # Master of Monty Python References | ||
lue | .oO(Romanus Eunt Domus) |
18:41 | |
"Well, division by zero is not so much 'physically impossible' as it is 'in violation of mathematical axioms.'" | 18:43 | ||
afk | 18:46 | ||
19:12
Exodist_ joined
19:21
zapad_ joined
19:24
M_o_C left
19:26
mantovani joined
|
|||
holli | how do i get the last changed timestamp of a file? | 19:26 | |
19:30
jhuni joined
|
|||
lue | *chirp* | 19:33 | |
.oO(Oh hey, why do I have TimToady's cricket?) |
19:34 | ||
19:36
cls_bsd_ joined,
cls_bsd left
|
|||
mberends | holli: stat calls are available in Parrot, but only partly in Rakudo, and the dates are NYI. | 19:41 | |
holli | ah, ok. | 19:42 | |
anyway, i got another problem. I did "ln ~/perl6/rakudo/perl6 /usr/bin/perl6" | 19:43 | ||
but when i then start rakudu, i get a bunch of errors: | 19:44 | ||
elements() not implemented in class 'Sub' | |||
current instr.: '' pc -1 ((unknown file):-1) | |||
is there something i can do about this? | |||
mberends | yes. | 19:46 | |
you probably did not "make install" | 19:47 | ||
then you would "sudo ln -s /some/path/parrot_install/bin/perl6 /usr/bin/perl6" | 19:48 | ||
lue | I know rakudo's famous for this: if I go into the src folder of rakudo, then call ../perl6, this happens: | 19:49 | |
Null PMC access in find_method('get_parrotclass') | |||
current instr.: 'perl6;ClassHOW;onload' pc -1 ((unknown file):-1) | |||
Segmentation fault | |||
19:49
jferrero joined
|
|||
mberends | holli: did you use "perl Configure.pl --gen-parrot" to begin building Rakudo? | 19:50 | |
holli | I did. and i did make install. | ||
mberends | holli: then don't link to the perl6 in the rakudo directory, link to the one in parrot_install/bin/ | 19:52 | |
holli | ah, ln -s /some/path/parrot_install/bin/perl6 /usr/bin/perl6 did the trick | ||
mberends | :) | ||
I personally prefer /usr/local/bin/ on Ubuntu because it is less cluttered | 19:53 | ||
also, I have /usr/local/bin/rakudo and /usr/local/bin/alpha to match the evalbot names :) | 19:55 | ||
lue | mberends: any chance you know the cause of this famous rakudo error? (look up) | ||
mberends looks | |||
19:56
shyam_iyer joined
|
|||
lue | where you can't call rakudo by navigating the directories (i.e. ../perl6 or rakudo/perl6) | 19:57 | |
mberends | lue: it works locally, but could be related to this "parrot_install/bin" dependency. The perl6 in the rakudo directory is not expected to work when run from any other directory. | 19:58 | |
lue | that seems a bit counter-productive. :) | 19:59 | |
mberends | so it's documented. That makes it a "feature", not a "bug" ;P | ||
because "make install" solves the problem, there is no incentive to work on a second solution. | 20:01 | ||
colomon | except maybe giving a better error message when you haven't done "make install" (like alpha did) | ||
lue | I'm not the BDFL on the server I work on (so I don't feel like mucking around with make install), and locally I don't have the resources to compile anything I could install! :( | 20:02 | |
(I could make a symlink, but...) | |||
colomon | lue: for rakudo, make install installs locally by default. You don't need any fancy permissions. | ||
lue | :D | 20:03 | |
mberends | colomon: good point, probably worth a little look | 20:04 | |
lue | but perl6 doesn't work after make install :( (still would need ./perl) | ||
mberends | lue: instead of "ln -s" you could define a bash alias | 20:05 | |
lue | ō.o | ||
cotto | ooc, what kind of obstacles exist to writing a Perl 6 compiler targeting the DLR? | 20:06 | |
20:06
cls_bsd_ is now known as cls_bsd
|
|||
pmurias | lack of manpower? | 20:06 | |
cotto | there's a gsoc proposal about doing that and I'm curious what kind of difficulties the student will face | 20:07 | |
diakopter | 1. The student would need to use one of the existing parsers, since implementing one of those for Perl 6 takes years | 20:08 | |
pmurias | with STD and rakudo's one being the do sensible possibilitys | 20:09 | |
cotto | Yeah. I guess the vastness of Perl 6 itself would be the biggest hurdle. | 20:10 | |
diakopter | 2. Perl 6 control flow (return via exceptions) is different enough from the CLRs that using Callsites in the DLR wouldn't gain anything. | ||
mberends | a scaled down but very achievable goal would be to add a DLR emitter to Perlito. | 20:12 | |
diakopter | 3. Perl 6 types need multiple inheritance and roles; the binding and dispatch builders in the languages already implemented on the DLR wouldn't be of much help. | 20:13 | |
cotto | perlito? | 20:14 | |
pmurias | fglock's subset of Perl 6 to multiple backends compiler | 20:15 | |
diakopter | github.com/fglock/Perlito | ||
4. Perl 6's multiple-stage compilation/evaluation is an issue that I'm not sure the DLR can surmount. | 20:16 | ||
mberends | see also www.perlito.org/ and try it online: www.perlito.org/js/ | 20:17 | |
pmurias | diakopter: sprixel targets .NET right? | ||
diakopter | pmurias: yes, in addition to the first stage being written in C# | ||
pmurias | first stage? | 20:18 | |
diakopter | yes. akin to rakudo's stage0, stage1, etc. | ||
pmurias | sprixel lives at github.com/diakopter/sprixel? | 20:19 | |
diakopter | no | ||
pmurias | diakopter: where can i find that? | 20:20 | |
diakopter | cotto: do you have any comments on the other points I mentioned? | 20:21 | |
pmurias: it's embedded somewhere in csmeta.org | |||
cotto | diakopter, no | 20:26 | |
what you've mentioned is very helpful, especially perlito | |||
20:33
clintongormley left
|
|||
lue | afk | 20:36 | |
20:40
iblechbot left
|
|||
cotto | thanks | 20:41 | |
20:41
masak joined
|
|||
diakopter | pmurias: are you looking into csmeta? I've left it deliberately unusable except for those on vs2010rc. | 20:41 | |
masak | ahoy, #perl6! | ||
mberends | \o masak | 20:42 | |
20:42
Su-Shee left
|
|||
masak continues to debug GGE under Rakudo master | 20:43 | ||
cotto hopes he's not trolling the dlr perl 6 proposal | 20:44 | ||
diakopter | cotto: btw, I was the one whose private commented included "... for several technical reasons" | 20:46 | |
masak | rakudo: subset 無 of Mu; my 無 $x; | ||
p6eval | rakudo 43f865: OUTPUT«Nominal type check failed for parameter '$original'; expected Any but got Mu insteadcurrent instr.: 'CREATE_SUBSET_TYPE' pc 336588 (src/gen/core.pir:17038)» | ||
masak | rakudo: subset A of Mu; my A $x | ||
p6eval | rakudo 43f865: OUTPUT«Nominal type check failed for parameter '$original'; expected Any but got Mu insteadcurrent instr.: 'CREATE_SUBSET_TYPE' pc 336588 (src/gen/core.pir:17038)» | 20:47 | |
pmurias | diakopter: just wanted to see how it's doing, i'm not very interested in .NET | ||
masak submits rakudobug | |||
diakopter | rakudo: subset A of Mu; my A $x; | 20:49 | |
p6eval | rakudo 43f865: OUTPUT«Nominal type check failed for parameter '$original'; expected Any but got Mu insteadcurrent instr.: 'CREATE_SUBSET_TYPE' pc 336588 (src/gen/core.pir:17038)» | ||
diakopter | oh | ||
hee | |||
pmurias wanders if there are any privates comments on his gsoc proposal ;) | 20:57 | ||
mberends | diakopter++: the Sprixel first stage roadmap code.google.com/p/csmeta/source/bro.../notes.txt describes a fairly powerful bootstrapping language. Linking to any .NET class is a brilliant feature. How complete is the Sprixel0 implementation? | 20:58 | |
diakopter | not very | 21:00 | |
static invocations work, e.g. Console.WriteLine("blah", 4432 + 332) | 21:01 | ||
I'm just finishing up named sub declarations | 21:02 | ||
mberends | that must already have a lot of underlying code working. These things don't come easily. | ||
masak | diakopter++ | 21:03 | |
diakopter | today, I'm thinking it will be an assembly language, targetted by viv and/or nqp-rx | 21:04 | |
at least until I can get associativity working in the expression parser | |||
but until then, precedence must have parens | |||
I'm hoping that STD will be able to compile itself to this language, which I'm calling perlesque | 21:05 | ||
masak | perlesque \o/ | ||
mberends | masak: Sprixel0 almost compiles on Linux as well, using mono 2.4.4 | 21:06 | |
diakopter | lots of transformations will be needed in its edition of viv; it probably won't be able to infer types in STD's output, so something will need to be done there | ||
but "a lot can be accomplished with closures" | |||
masak | mberends: nice | ||
:) | 21:07 | ||
diakopter | also, class declarations, sorta like PIR's | 21:08 | |
including generics eventually, I guess | 21:09 | ||
so basically, a very small strongly typed impure functional subset of Perl 5/6 | |||
mberends | sounds like a fun language :) | 21:10 | |
diakopter | it'll remain vaporware, though, for a while longer. if anyone wants to help, they could take a look at extending viv to other emitters | 21:12 | |
or to help TimToady in his quest to make viv --p5 emit the same thing as gimme5 | 21:13 | ||
, from which would provide a stable starting point to derive a perlesque emitter | |||
masak | ah. gotcha. | 21:14 | |
rakudo: class A {}; my $x = &A::nosuch | |||
p6eval | rakudo 43f865: OUTPUT«Null PMC access in can()current instr.: '&infix:<=>' pc 16989 (src/builtins/Junction.pir:245)» | ||
masak | alpha: class A {}; my $x = &A::nosuch | ||
p6eval | alpha 30e0ed: ( no output ) | ||
masak submits rakudobug | |||
is that still the way to get at a method in Perl 6? | 21:15 | ||
ash__ | i only know of using .^methods | 21:21 | |
to get a method | |||
rakudo: class Foo { method f { say 'f' } }; my $a = Foo.^methods(:local); say $a[0](); | |||
p6eval | rakudo 43f865: OUTPUT«Not enough positional parameters passed; got 0 but expected 1current instr.: 'perl6;Foo;f' pc 450 (EVAL_1:178)» | ||
ash__ | ehe, still nees a self | 21:22 | |
needs* | |||
masak | I've previously been using &Class::methodname to get at a method, and it's worked. | ||
ash__ | maybe thats supposed to work | ||
rakudo: class Foo { method f { say 'f' } }; my $a = Foo.^methods(:local); $a[0](); | 21:23 | ||
p6eval | rakudo 43f865: OUTPUT«Not enough positional parameters passed; got 0 but expected 1current instr.: 'perl6;Foo;f' pc 439 (EVAL_1:177)» | ||
ash__ | oops | ||
rakudo: class Foo { method f { say 'f' } }; my $a = Foo.^methods(:local); $a[0]('lol_not a foo'); | 21:24 | ||
masak | I'm kinda expecting to use a way that doesn't involve the introspect API. | ||
p6eval | rakudo 43f865: OUTPUT«f» | ||
masak | mostly because I haven't needed it for this before. | ||
ash__ | well, maybe we should ask someone about &Class::methodname that seems perfectly reasonable | ||
masak | I'm all for asking someone perfectly reasonable :) | 21:25 | |
mberends seems perfectly reasonable, until asked such a question ;) | |||
ash__ | is there a &() context? | 21:26 | |
colomon | is the alternative Class::&methodname? I feel like I'm missing context in this discussion... | 21:27 | |
ash__ | would be nice to also grab methods off an instance as a closure, so you don't have to pass self | 21:28 | |
colomon should probably go downstairs and find out what his father-in-law is doing to the house's electrical system... | |||
masak | ash__: you can always do that manually, through a closure. I did that in Rakudo back in late 2008 :) | 21:29 | |
I was greatly surprised that it worked... | |||
ash__ | yeah, but if your talking convenient method accessors... | 21:30 | |
21:30
JohnDoe365 joined
|
|||
ash__ | doing like: my &a = &($foo.methodname); and having it still bound to $foo might be nice | 21:30 | |
masak | in my case, I just expect to send in the invocant parameter as the first argument. | ||
ash__ | i guess thats currying isn't it? | 21:31 | |
masak | no, it's passing the invocant parameter to something which has the form of a sub :) | ||
alpha: class A { method foo($message) { say $message } }; my $bar = &A::foo; my $a = A.new; $bar($a, "OH HAI") | 21:32 | ||
p6eval | alpha 30e0ed: OUTPUT«OH HAI» | ||
masak | alpha: class A { method foo($message) { say $message } }; my $bar = &A::foo; my $a = A.new; my &closure = -> $m { $bar($a, $m) }; closure("currying! \o/") | 21:33 | |
p6eval | alpha 30e0ed: OUTPUT«currying! | ||
21:33
sundar joined
|
|||
masak | I guess that's currying, though... | 21:33 | |
a fairly manual kind. | 21:34 | ||
alpha: class A { method foo($message) { say $message } }; my $bar = &A::foo; my $a = A.new; my &closure = $bar.assuming($a); closure("currying! \o/") | |||
p6eval | alpha 30e0ed: OUTPUT«currying! | ||
ash__ | rakudo: class A { method foo($message) { say $message } }; my $bar = &A::foo; my $a = A.new; my &closure = $bar.assuming($a); closure("currying! \o/") | ||
p6eval | rakudo 43f865: OUTPUT«Unrecognized backslash sequence: '\o' at line 11, near "/\")"current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)» | ||
masak | oops, shoulda had double backslashes there... :) | 21:35 | |
ash__ | rakudo: class A { method foo($message) { say $message } }; my $bar = &A::foo; my $a = A.new; my &closure = $bar.assuming($a); closure("currying! \\o/") | ||
p6eval | rakudo 43f865: OUTPUT«Null PMC access in can()current instr.: '&infix:<=>' pc 16989 (src/builtins/Junction.pir:245)» | ||
ash__ | so... some functionality from alpha still missing | 21:36 | |
masak | nuh huh. | ||
:) | |||
to be fair, I'm missing less than I thought I would. | 21:37 | ||
ash__ | perlcabal.org/syn/S06.html#Currying | 21:38 | |
masak | rakudo: class A { method foo { say "OH HAI" } }; my $meth = A.can("foo"); $meth(A.new) | ||
p6eval | rakudo 43f865: OUTPUT«OH HAI» | ||
masak | ah. I seemed to remember it was something like that. | ||
ash__ | is that the proper way of doing it? | 21:39 | |
masak | I think jnthn++ said so. | ||
slightly surprising, in my opinion. :) | 21:40 | ||
ash__ | perlcabal.org/~azawawi/html/spec/S1...can.t.html has an example of that | 21:41 | |
mberends goes to sleep, o/ | 21:43 | ||
colomon | \o | ||
21:43
mberends left
|
|||
masak | o/ | 21:43 | |
hm; I guess technically it is introspection, too. :) | 21:44 | ||
but at least it doesn't explicitly involve the metaclass. | |||
ruoso | ash__, in Perl 6 methods are not registered in the package by default... | 21:48 | |
rakudo: class A { our method foo($message) { say $message } }; my $bar = &a::foo; my $a = A.new; $bar($a, "Hello"); | 21:49 | ||
p6eval | rakudo 43f865: OUTPUT«Null PMC access in can()current instr.: '&infix:<=>' pc 16989 (src/builtins/Junction.pir:245)» | ||
ash__ | so doing &Classname::methodname shouldn't work? | ||
unless you use our | |||
ruoso | ash__, unless you have a "our method" | ||
ash__ | got ya | ||
masak | ah. | ||
ruoso | rakudo: class A { our method foo($message) { say $message } }; my $bar = &A::foo; my $a = A.new; $bar($a, "Hello"); | ||
p6eval | rakudo 43f865: OUTPUT«Hello» | ||
ruoso | it's important to notice that this &A::foo lookup is absolutely non-OO | 21:51 | |
it will look for a routine declared in that package | |||
ash__ | rakudo: class A { our method foo($message) { say $message } }; my $a = A.new; my &bar = &A::foo.assuming(self => $a); &bar("Hi"); | 21:52 | |
masak | gotcha. | ||
p6eval | rakudo 43f865: OUTPUT«Symbol 'self' not predeclared in <anonymous> (/tmp/sRy5L0z4Ap:11)current instr.: 'perl6;PCT;HLLCompiler;panic' pc 152 (compilers/pct/src/PCT/HLLCompiler.pir:108)» | ||
ash__ | rakudo: class A { our method foo($message) { say $message } }; my $a = A.new; my &bar = &A::foo.assuming(:self($a)); &bar("Hi"); | ||
p6eval | rakudo 43f865: OUTPUT«Not enough positional parameters passed; got 1 but expected 2current instr.: 'perl6;A;foo' pc 508 (EVAL_1:0)» | ||
ruoso | rakudo: class A { our method foo($s: $message) { say $message } }; my $a = A.new; my &bar = &A::foo.assuming($s => $a); &bar("Hi") | 21:53 | |
p6eval | rakudo 43f865: OUTPUT«Symbol '$s' not predeclared in <anonymous>current instr.: 'perl6;PCT;HLLCompiler;panic' pc 152 (compilers/pct/src/PCT/HLLCompiler.pir:108)» | ||
ruoso | rakudo: class A { our method foo($s: $message) { say $message } }; my $a = A.new; my &bar = &A::foo.assuming($a); &bar("Hi") | ||
p6eval | rakudo 43f865: OUTPUT«Hi» | ||
ash__ | cool | ||
that works too | |||
ruoso | when you look at a method as a routine, the invocant is just the first positional argument... just like p5 | 21:57 | |
22:02
espadrine joined
|
|||
lue | ohai there! | 22:03 | |
masak | lue! | ||
lue | .oO(I can't believe it. masak joined 5 minutes after I left a couple hours ago!) |
22:04 | |
pmurias | ruoso: i'm running devel cover on mildew | ||
* Devel::Cover | 22:05 | ||
22:05
yjh joined,
user_7310 joined
|
|||
lue | last off, I was hoping to resolve #61602, when I really opened a new can of worms :) | 22:06 | |
rakudo: Inf.Num.say; NaN.Num.say; Inf.Int.say; Inf.NaN.say; # note the number; it's only on 64-bit computers | |||
p6eval | rakudo 43f865: OUTPUT«InfNaN-9223372036854775808Method 'NaN' not found for invocant of class 'Num'current instr.: '_block14' pc 29 (EVAL_1:0)» | ||
lue | rakudo: NaN.Int.say # *cough* | 22:07 | |
p6eval | rakudo 43f865: OUTPUT«-9223372036854775808» | ||
22:08
espadrine left
22:09
IllvilJa left
22:12
JohnDoe365 left
|
|||
pugssvn | r30360 | pmurias++ | [mildew] fix our, saner handling of names with packages | 22:13 | |
masak | that's not not a number. :) | ||
lue | exactly. If you look at #61602, i noted it returns the decimal of a binary number with the highest bit set (# of bits dependent on your CPU) | 22:14 | |
s/highest/most significant/ | 22:15 | ||
lue is starting to get annoyed no-one has implemented := yet, it gets in the way of making sure some pre-ng tickets are still tickets :/ | 22:17 | ||
alpha: my @a = (1); @a[0] := @a; @a.perl | |||
p6eval | alpha 30e0ed: OUTPUT«rtype not setin Main (file <unknown>, line <unknown>)» | ||
lue | ō.o was expecting it to hang | 22:18 | |
masak | it did, at one point. | 22:21 | |
lue | I wanted to see if master is fine with it, but := is NYI :/ | ||
rakudo: say 3 ~~ !NaN | 22:22 | ||
p6eval | rakudo 43f865: OUTPUT«0» | ||
masak | that's not how you match negatively against types :) | 22:23 | |
though I've toyed with the idea myself of overloading prefix:<!> that way... :) | |||
ash__ | is the !NaN Inf? | 22:24 | |
lue | rakudo: say 3 is not NaN # testing real-language :) | ||
p6eval | rakudo 43f865: OUTPUT«Confused at line 11, near "say 3 is n"current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)» | ||
masak | lue: !~~ | 22:25 | |
lue | rakudo: say 3 !~~ NaN | ||
p6eval | rakudo 43f865: OUTPUT«1» | ||
lue | but that's just not equals. It would be more fun to say equals not Not a Number :) | ||
wait, NaN is a *type*? | 22:26 | ||
moritz_ | nope | ||
phenny | moritz_: 16:51Z <mberends> tell moritz_ nice to see a pure Date module, hopefully 'perldoc Date::Simple' is an appropriate feature set. | ||
moritz_ | rakudo: say NaN.WHAT | ||
p6eval | rakudo 43f865: OUTPUT«Num()» | ||
moritz_ | phenny: tell mberends yes, Date::Simple is my main source of inspiration | ||
phenny | moritz_: I'll pass that on when mberends is around. | ||
sorear | lue: a type in Perl 6 is a set of values. {NaN} is a type | 22:27 | |
moritz_ | the other view is that every value that responds with False to .defined is a type | ||
lue | rakudo: say NaN.defined | ||
p6eval | rakudo 43f865: OUTPUT«1» | 22:28 | |
lue | rakudo: my NaN $a = 3; say $a # if it's a type, I should be able to do this (?) | ||
p6eval | rakudo 43f865: OUTPUT«Type check failed for assignmentcurrent instr.: '&die' pc 17293 (src/builtins/Junction.pir:404)» | ||
22:28
pmurias left
|
|||
masak | it's not a type. | 22:30 | |
lue | rakudo: say 3 !~~ 4; say 3 ~~ !(4) | ||
p6eval | rakudo 43f865: OUTPUT«10» | ||
sundar | Hi... I have some free time at hand, and would like to contribute to Perl6. What is something that might be easy to implement for a newbie? | 22:32 | |
masak | sundar: cool! almost anything you do at this point that produces runnable Perl 6 code is of value. | 22:33 | |
sundar: it usually drags out bugs and highlights what needs to be done in order to make it to Rakudo Star. | |||
sundar | masak: you mean trying writing Perl 6 code and playing with it? | 22:34 | |
masak | yes. | ||
lue | I agree with masak. I can't tell you how many weird bugs I've found trying out Perl6 code to do something completely random. | 22:35 | |
masak | well, you're welcome to write something completely non-random too :) | ||
22:35
ash__ left
22:36
IllvilJa joined
|
|||
sundar | Ok, that sounds good.. I'd learn Perl 6 better too this way. Thanks, getting to it right away. :) | 22:36 | |
masak | \o/ | ||
sundar: when you do hit a snag -- and you will, if you keep at it long enough -- feel free to highlight it by executing a golfed line of code on p6eval here on the channel. | 22:37 | ||
rakudo: $_ = "OH NOES"; s/NOES/HAI/; say $_ | 22:38 | ||
p6eval | rakudo 43f865: OUTPUT«OH NOES» | ||
lue | I seriously think P6 is the most fun I've ever had learning a language. It may not be as quick (lack of documentation), but you'll have much more fun learning :) | ||
masak: THAT'S how you use s///! | 22:39 | ||
sundar | masak: sure.. I've been watching "masak submits rakudobug"s for some time now. Ll be good to see one prompted by me too.. :) | ||
lue | .oO(I got very giddy when I caused a spec bloodbath a while ago (file test operators)) |
||
masak | sundar: :) | 22:40 | |
22:41
zapad_ left
|
|||
lue still wonders about this: $_ means "it", @_ means "them", %_ means... | 22:41 | ||
masak | 'themz' :) | 22:44 | |
sundar | lue: some languages have a words for 'those two'... though that would still be a Pair, not a hash.. | ||
lue | It bugs me that we have english pronouns for a bunch of things (*,$_, and so on) EXCEPT for %_ | 22:47 | |
I'm going to be asking until Perl7 comes out, when %_ is abolished :) | |||
lue is looking at en.wikipedia.org/wiki/English_personal_pronouns for guidance | 22:49 | ||
22:50
snarkyboojum joined
|
|||
lue | o hai snarkyboojum o/ | 22:51 | |
(right now I'm trying to find an english language equivalent to %_) | |||
snarkyboojum | hi lue | 22:52 | |
lue is currently resorting to old english, before moving on to other languages | 22:54 | ||
pugssvn | r30361 | lwall++ | [STD] clean up some unneeded locmesses | 22:57 | |
r30361 | distinguish "Parse failed" from "Check failed" | |||
lue | TimToady++ for clarity :) | 22:59 | |
.oO(is there a language out there that defines a pronoun referring to a hash-like structure?) |
23:02 | ||
afk (in the meantime considering inventing a new english word if nothing else) | 23:03 | ||
23:03
masak left
23:08
orafu left,
orafu joined
|
|||
snarkyboojum | re inconsistency in method naming in Temporal.pm, 'multi method day-of-week' vs 'multi method from_epoch' for example? | 23:11 | |
ruoso | damian++ "that's a very sad reflection on our profession." | 23:20 | |
heh | 23:21 | ||
23:31
payload joined
23:34
payload1 joined,
payload left
|
|||
snarkyboojum | not an argument though :) | 23:42 | |
arnsholt | ruoso: Where's that from? | 23:54 | |
TimToady | std: my $x; "$x\[nonesuch\]"; | ||
p6eval | std 30361: OUTPUT«ok 00:01 109m» | ||
diakopter | arnsholt: p6l | 23:55 | |
arnsholt | Ah, right. I should probably subscribe to p6l |