»ö« 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. |
|||
00:08
MayDaniel left
00:34
raiph left
00:37
colomon left
|
|||
dalek | p-jvm-prep: c50db7c | jonathan++ | t/qast_6model.t: Sketch out a basic test for attributes. |
00:53 | |
p-jvm-prep: bce9af6 | jonathan++ | / (2 files): Add getattr/bindattr ops. Currently, not useful for anything as P6opaque doesn't yet support attributes. |
|||
p-jvm-prep: 7e1b0d3 | jonathan++ | src/org/perl6/nqp/sixmodel/reprs/P6Opaque (3 files): Make P6opaque support reference type attributes. Done in a way that will be relatively easily extensible to natively typed attributes and the box/unbox stuff later on. Makes the previously added basic attributes test pass. |
|||
00:55
colomon joined
01:00
spider-mario left
|
|||
jnthn | sleep & | 01:04 | |
[Coke] | jnthn++ | 01:09 | |
colomon | [Coke]++ | 01:14 | |
01:22
tokuhiro_ joined,
tokuhiro_ left
01:28
geekosaur left
01:29
geekosaur joined
01:37
tokuhiro_ joined
|
|||
kthakore | 3~/win 2 | 01:51 | |
01:52
crazedpsyc joined
02:23
jeffreykegler joined
02:24
jeffreykegler left
02:32
FROGGS_ joined
02:35
FROGGS left
03:01
tokuhiro_ left
|
|||
timotimo | that interview with damian conway was very pleasant to watch | 03:04 | |
03:11
grondilu left
03:28
adu_ joined
03:33
geekosaur left
|
|||
lue | got this trying to run latest panda: ===SORRY!===\nNo object at index 333 | 03:34 | |
03:36
geekosaur joined
03:39
geekosaur left
03:40
geekosaur joined
|
|||
sorear | lue: you are experiencing stale compiled files. delete your ~/.perl6 and reinstall panda | 03:41 | |
lue | Ah. Will have to do that later then, fortunately I don't need any modules at the moment. | 03:42 | |
flussence | it's a bug in git rakudo or something. I've been unable to fix it for weeks :/ | 03:50 | |
(well, besides deleting all the .pir files on my system, but that doesn't fix the root of it) | 03:51 | ||
03:57
orafu left,
orafu joined
03:58
ifim left
04:13
atrodo left
04:21
xinming_ left
04:24
xinming joined
04:38
skids left
04:51
Targen left
|
|||
adu_ | hi sorear | 04:53 | |
05:00
skids joined
05:02
skids_ joined
05:05
skids left
|
|||
sorear | hi adu_ | 05:09 | |
adu_ | how goes? | 05:15 | |
05:15
am0c left
|
|||
sorear | ok | 05:21 | |
05:27
am0c joined
05:31
adu_ left,
telex left
05:36
telex joined
05:41
quester joined
06:04
kaleem joined
06:12
Kharec joined
06:15
FROGGS_ is now known as FROGGS
|
|||
FROGGS | morning *yawn* | 06:15 | |
06:20
jaldhar_ joined
06:30
am0c left
06:32
jokar joined
06:33
jokar left
06:36
jokar joined
06:37
jokar left
06:38
jokar joined
|
|||
FROGGS | jnthn: I've noticed that there are cases where $foreign_proto is a dispatcher but $_.value is not, see github.com/rakudo/rakudo/blob/frog...ld.pm#L277 | 07:04 | |
jnthn: before I added the conditions to line 277 there, the following test caused a NULLPMC error in clone(): github.com/perl6/roast/blob/master...sub.t#L227 | 07:05 | ||
07:06
cognominal left
|
|||
FROGGS | jnthn: is it wise to make a new branch to roast to add/unfudge merge tests? I dont wanna wait for the time my patch is merged in to recognize that there are issues which are not covered yet | 07:07 | |
jnthn: so I guess I got my answer already ;o) | |||
07:09
jokar left
07:21
Chillance left
|
|||
moritz | \o | 07:31 | |
07:38
SamuraiJack joined
07:50
fgomez joined
07:59
quester left
08:12
Pleiades` left,
FROGGS_ joined
08:17
rindolf joined,
rindolf left,
rindolf joined
08:18
Pleiades` joined
|
|||
Woodi | good morning everyone :) | 08:21 | |
moritz | sorear: fwiw rakudo doesn't look into ~/.perl6/lib anymore, but int %*CUSTOM_LIB<site> ~ '/lib' | 08:23 | |
08:26
FROGGS_ left
|
|||
Woodi | about coloring syntax: if perl can be parsed only by perl then there is a need for at least one code editor colored by perl... but, as stated many times, it will be slow so: is checking syntax on whole document is needed on every keystroke ? maybe fire syntax highlighting on \W like braces, operators is good enought ? or maybe caching colors of lines above current line ? | 08:26 | |
moritz | you don't need to parse code to hilight it | 08:28 | |
it's enough to an approximate lexing | 08:29 | ||
08:31
FROGGS_ joined
|
|||
Woodi | in recent years big MMO games like EVE maked UI threaded which realy improved user experience :) second thread executing perl interpreter can be fast enought... and additional to colouring it can display errors and warnings in status line or contextual messages... | 08:31 | |
08:32
brrt joined
|
|||
Woodi | moritz: just doing sci-fi autor thinking with hope of help a bit :) | 08:32 | |
brrt | hi p6 | ||
Woodi | o/ | ||
work & | 08:33 | ||
brrt | \o woodi | ||
moritz | Woodi: then also consider the dystopia | ||
you don't want your editor to run the perl compiler over the code all by itself | |||
consider BEGIN shell 'rm -rf ~' | |||
Woodi | hmm, I thinked about code I can type :) | 08:34 | |
but right | |||
perl is dangerous! | |||
avoid it on all costs ! :) | 08:35 | ||
brrt | :-) | ||
use safe languages such as python and java! | |||
08:35
alec joined
|
|||
Woodi | but realy second thread for highlighting can be good | 08:35 | |
yea, even asm have better ridability... | 08:36 | ||
moritz | good riddance | ||
Woodi | so perl6-debugger is voulnerable to BEGIN shell trick ? :) | 08:38 | |
tadzik | well, if you put such things in your code... :) | ||
good morning #perl6 | |||
Woodi | hallo tadzik :) | ||
moritz | Woodi: in first approximation, the debugger runs the code just like the compiler | ||
FROGGS_ | someone should glue STD.pm6 to an editor | 08:41 | |
... together with hoelzro's highlighter | 08:42 | ||
lets make Qadre! \o/ | 08:43 | ||
hoelzro | FROGGS_: but then the editor would have to use Python =( | 08:46 | |
FROGGS_ | hoelzro: both | 08:48 | |
wouldnt hurt IMO | |||
Woodi | can we replace Python with something ? :) | 08:50 | |
FROGGS_ | rewrite the highlighter... sounds like a lot of work... | 08:51 | |
08:53
tokuhiro_ joined
|
|||
hoelzro | actually, it wouldn't be *that* much work | 08:55 | |
then again, I'm probably ignorant of all the work that Pygments does behind the scenes | 08:56 | ||
the lexer itself is fairly simple, especially considering the language it's lexing | |||
Woodi | hoelzro: what you think about 2 threads in editor ? one for user input second for highlighting (and displaying) ? | 09:05 | |
hmm, ldd vim already shows libpthread... | 09:06 | ||
hoelzro | Woodi: you probably wouldn't need a second thread for highlighting if your highlighter were smart enough | 09:07 | |
Woodi | hoelzro: I think about user experience and parsing always takes time, sometimes chokes... | ||
hoelzro | so you would need to get a lock on the text every time the user changes it? | 09:08 | |
Woodi | generally I do not want pragmatk aproach here :) thinking about future arhitectures with many cores, etc, bla bla bla :) | 09:10 | |
09:11
tokuhir__ joined,
tokuhiro_ left
|
|||
Woodi | hoelzro: no, good data struct can get user text and take user input and rest of app can do editor work... | 09:11 | |
hoelzro | I don't think that another thread for highlighting is necessarily a bad idea, but it sounds like a pain to implement | ||
Woodi | hoelzro: I know :) and that is a point ! we need to start small with just 2 threads ! :) | 09:12 | |
or just 1 main thread doing work delegation to small threads... and then make small changes in programs arhitecture planning... | 09:14 | ||
09:17
kresike joined
|
|||
kresike | hello all you happy perl6 people | 09:17 | |
Woodi | sugar 25 kg, gelatin 4 kg... work 7 :) | ||
09:18
bitonic joined
|
|||
FROGGS_ | Woodi: you are making statue? | 09:32 | |
masak | a happy morning to you, #perl6 | 09:37 | |
09:38
fgomez left
|
|||
FROGGS | morning kresike, masak | 09:40 | |
09:43
Patterner left
09:45
tokuhir__ left
|
|||
Woodi | FROGGS_: no, just stacktaking on end of year in bakery :) | 09:47 | |
09:47
Psyche^ joined,
Psyche^ is now known as Patterner
|
|||
kresike | FROGGS, o/ | 09:47 | |
Woodi | but we do cakes too :) | ||
FROGGS | a | 09:48 | |
cakes++ | |||
-a | |||
09:50
MayDaniel joined
09:52
SmokeMachine joined
09:58
SamuraiJack left
10:01
_ilbot joined
10:35
denisboyun_ joined
|
|||
masak | just to be clear, you don't have to account for any en.wikipedia.org/wiki/Siphon effect in t4. | 10:37 | |
moritz | github.com/munificent/vigil | ||
masak: of course not, since all the spaces between blocks can let air through | 10:38 | ||
arnsholt | "This is similar to contracts, but less legal and more medieval." =D | 10:40 | |
moritz | aye :-) | 10:42 | |
au | vigil seems like a natural fit with TDDD (test-deletion-driven development). | 10:45 | |
10:48
am0c joined
10:51
bitonic left
10:53
stevan_ left
|
|||
moritz | I think you could use it to train people to "commit early, commit often" | 10:56 | |
and after you found an assertion violation, you do a 'git diff' and immediately see which method triggered it | 10:57 | ||
masak | moritz: you're right. I still believe the original t4 description is carefully worded enough to make it clear. but it doesn't hurt to be over-specific, and I just got an email asking me about the siphon effect. :) | 10:58 | |
10:59
denisboyun_ left
|
|||
masak laughed out loud upon reaching "it will be deleted from your source code." | 11:00 | ||
of course! so simple! | |||
11:05
hash_table joined
11:08
foodoo joined
|
|||
arnsholt | Indeed. Dropping those hints about "must be punished" and then keeping that gem until the end was brilliant! | 11:10 | |
tadzik | maybe it should have a soft-core mode, carving "I must not tell lies" in blood somewhere in the source code | 11:11 | |
11:21
foodoo left
|
|||
jnthn | morning o/ | 11:24 | |
FROGGS | morning jnthn | ||
jnthn | Going to be doing a bunch of visiting folks in the next few days, so will probably not be online a great deal. | 11:26 | |
Woodi: The point of a debuggers is to run the code without doing things differently to if it was being run normally, just letting the user see what's going on at various points. It'd be a pretty useless debugger if it didn't run the BEGIN blocks. :) | 11:28 | ||
moritz | if you want to debug a program that deletes your hard drive, you want it to delete your hard drive while debugging too :-) | 11:31 | |
jnthn | FROGGS: The reason you have the get_bool not implemented thing is probably because you put something (looks like PROCESS) in boolean context that doesn't (at that point) know how to be. You could always use defined, or nqp::concrete(...) instead. | ||
probably nqp::defined, in fact | |||
That'd about the NQPCursorRole special case too | 11:32 | ||
Also just calling .is_dispatcher on any symbol is probably a bad idea. Probably should be protected with nqp::can check | |||
11:33
brrt left
11:36
FROGGS_ left,
FROGGS_ joined
11:39
mtk joined,
geekosaur left
11:40
geekosaur joined
|
|||
moritz | also I think we should only merge if both protos are marked as onlystar | 11:41 | |
jnthn | moritz: I already mentiond that one to FROGGS | 11:43 | |
oh, and I thought it was done, but now I look at the branch I don't see it... | 11:44 | ||
Note that to de-duplicate we can also use the .static_id thingy | 11:45 | ||
moritz | good idea | ||
11:49
denisboyun_ joined
|
|||
dalek | p-jvm-prep: 4ab6071 | jonathan++ | / (2 files): Add box/unbox ops. Note that P6opaque will also need some work before it can support these. |
11:57 | |
p-jvm-prep: 9615c61 | jonathan++ | t/qast_6model.t: Test box/unbox with the boot types. |
|||
p-jvm-prep: 9a2db5b | jonathan++ | docs/ROADMAP: ROADMAP update. |
11:59 | ||
11:59
FROGGS_ left
12:00
FROGGS_ joined
|
|||
FROGGS | moritz: so you mean that we only should merge the dispatchees if their proto is onlystar? | 12:06 | |
hmmm | 12:07 | ||
jnthn | If *both* protos are onlystar | ||
FROGGS | ahh, yeah, makes sense | ||
jnthn | Which is the common case. | ||
12:08
hash_table left
|
|||
FROGGS | r: proto sub a { 42 }; multi sub a ( $a ) { $a }; say a(7) | 12:08 | |
p6eval | rakudo f5037e: OUTPUT«Too many positional parameters passed; got 1 but expected 0 in sub a at /tmp/PFMftDURHN:1 in block at /tmp/PFMftDURHN:1» | ||
FROGGS | r: proto sub a ( Mu ) { 42 }; multi sub a ( $a ) { $a }; say a(7) | ||
p6eval | rakudo f5037e: OUTPUT«42» | ||
FROGGS | r: proto sub a ( Mu ) { 42 }; multi sub a ( Int $a ) { $a }; say a(7) | 12:09 | |
p6eval | rakudo f5037e: OUTPUT«42» | ||
FROGGS | r: proto sub a ( Mu ) { * }; multi sub a ( Int $a ) { $a }; say a(7) | ||
p6eval | rakudo f5037e: OUTPUT«7» | ||
FROGGS | r: proto sub a { * }; multi sub a ( Int $a ) { $a }; say a(7) | ||
p6eval | rakudo f5037e: OUTPUT«===SORRY!===CHECK FAILED:Calling proto of 'a' will never work with argument types (int) (line 1) Expected: :()» | ||
FROGGS | why does it ignore the multi? | 12:10 | |
moritz | multis work by first calling the proto | ||
jnthn | The proto's signature must be at least as wide as that of the candidates. | ||
moritz | and the proto can then decide to re-dispatch to the candidates | ||
12:10
FROGGS_ left
|
|||
jnthn | Otherwise you never make it into the proto and never hit the * thtat triggers the multi-dispatch | 12:10 | |
moritz | but if you write proto sub a { * }, it has a signature of () | ||
so the proto (and thus the candidates) cannot be called | 12:11 | ||
FROGGS | ahh, k, cool | ||
12:11
FROGGS_ joined
|
|||
FROGGS | r: proto sub a { * }; multi sub a ( Int $a ) { $a }; say a( a => 7) | 12:12 | |
p6eval | rakudo f5037e: OUTPUT«Cannot call 'a'; none of these signatures match::(Int $a) in block at /tmp/Qn4X7fgWWB:1» | ||
FROGGS | r: proto sub a ( Mu ) { * }; multi sub a ( Int $a ) { $a }; say a( a => 7) | ||
p6eval | rakudo f5037e: OUTPUT«Cannot call 'a'; none of these signatures match::(Int $a) in block at /tmp/6eihJU511h:1» | ||
FROGGS | r: proto sub a ( Mu ) { * }; multi sub a ( Int :$a! ) { $a }; say a( a => 7) | ||
p6eval | rakudo f5037e: OUTPUT«7» | ||
FROGGS | r: proto sub a ( Mu ) { 42 }; multi sub a ( Int :$a! ) { $a }; say a( a => 7) | 12:13 | |
p6eval | rakudo f5037e: OUTPUT«Not enough positional parameters passed; got 0 but expected 1 in sub a at /tmp/5m8kubQR8R:1 in block at /tmp/5m8kubQR8R:1» | ||
FROGGS | k | ||
12:13
JJ_Brain left
12:14
JJ_Brain joined
12:20
brrt joined
12:27
JJ_Brain left,
JJ_Brain joined
12:34
denisboyun_ left
|
|||
dalek | ast: 065efbb | moritz++ | S02-names-vars/variables-and-packages.t: unfudge a passing test for rakudo |
12:36 | |
ast: 896563b | moritz++ | S29-context/die.t: another rakudo unfudge |
12:37 | ||
12:39
JJ_Brain left
|
|||
masak | could rosettacode.org/wiki/Balanced_brackets be map-reduced? I always thought it couldn't because nesting isn't a "local" property... but Steele in labs.oracle.com/projects/plrg/Publi...Steele.pdf mentions monoid-cached trees, which seem applicable here. | 12:39 | |
12:40
JJ_Brain joined
|
|||
masak | (more exactly, the "parallel prefix problem" that he solves seems structurally very similar to the nested brackets property) | 12:41 | |
12:43
denisboyun_ joined
12:48
JJ_Brain left,
JJ_Brain joined
|
|||
sorear | masak: en.wikipedia.org/wiki/Syntactic_monoid | 12:50 | |
2nd example | 12:51 | ||
sleep& | |||
masak | damn, I gotta learn more of this category theory stuff. it's like it's calling me from the other side of a veil. | 12:53 | |
dalek | p-jvm-prep: d70c951 | jonathan++ | / (4 files): Preparations for supporting native attributes. |
12:54 | |
jnthn | Away for some days...worst case until Monday. o/ | 12:55 | |
brrt | bye jnthn! | ||
masak | fare thyself well, jnthn. | ||
12:56
JJ_Brain_ joined
12:58
JJ_Brain left
13:00
JJ_Brain_ left,
JJ_Brain joined
|
|||
masak | ok, so the balanced brackets do form a monoid. I'd still be curious to see an actual map-reduce solution implemented for this. | 13:01 | |
it's not 100% clear to me what it'd look like. | |||
arnsholt | One idea I had was to map a string fragment to a number | 13:03 | |
Nah, won't work after all | |||
Parallel parsing is kinda nasty to wrap your brain around =) | |||
masak resolves to study monoids some more | 13:05 | ||
13:07
JJ_Brain left,
JJ_Brain joined
13:09
mtk left,
mtk joined
13:11
bitonic joined
|
|||
mikemol | This thread needs some love: www.reddit.com/r/programming/commen...6_writing/ | 13:12 | |
13:13
JJ_Brain left,
JJ_Brain joined,
rindolf left
|
|||
masak | there's a kind of saturation level at which I feel I need to stay away from such threads, help further Perl 6 along, and leave bickering over semantics to others. | 13:19 | |
hoelzro | it's kind of troubling to observe that kind of reaction to Perl 6, though | ||
half of the people don't expect it to be ready anytime soon, and the other half seem to have given up | 13:20 | ||
masak | the only way to really silence that kind of reaction to Perl 6 is to put Perl 6 to good, objectively undeniable uses. | ||
brrt | chromatic has posted a nice thing about p6 too recently | 13:21 | |
hoelzro | brrt: really? | ||
masak | I'm not claiming Perl 6 is ready for everyone. I'm claiming it's ready for a whole lot of people with an interest in the features Perl 6 provides, not too great a need for perf, and something of a tolerance for bugs. | ||
13:21
xinming left
|
|||
hoelzro | I see him as one of the larger critics, so I'd like to see that | 13:22 | |
see, that's an interesting point, masak | |||
masak | keep in mind that chromatic is not evil. he used to be a big supporter or Perl 6, but he burned out. | ||
of* | |||
hoelzro | masak: oh, I don't think he's evil! I'm just saying that he's critical | ||
which isn't a bad thing, but it makes it harder to advocate | |||
brrt | hoelzro, it was nice-and-not-nice at the same time | ||
masak | his criticisms should be read in the light of him being disappointed. | 13:23 | |
brrt | it was nice in that it said perl6 is a well-designed language | ||
masak | on his best days, chromatic acts as a counterweight to exuberant Perl 6 optimism on reddit. | ||
brrt | it was not nice in that it said that rakudo isn't going anywhere | ||
hoelzro | brrt: ah | ||
13:23
xinming joined
13:24
pmurias joined
|
|||
masak | chromatic was also heavily invested in Parrot as a platform, so Rakudo's investigating the JVM counts in his mind as Rakudo "not going anywhere". | 13:24 | |
hoelzro | see, my trouble is I'd like to write something in Perl 6, but a) I occasionally encounter show-stopper bugs, like with my chat bot, or b) I'd like it be used and improved by others, and I feel that many people wouldn't want to deal with installing/learning Perl 6 just to use my stuff | ||
13:24
JJ_Brain left
|
|||
brrt | i personally have doubts about rakudo-on-jvm | 13:25 | |
13:25
cedrvint joined
|
|||
brrt | it could work, it could also not work | 13:25 | |
masak | all of this, by the way, is trying to put a context to what chromatic is saying. not psychoanalysing him. :) | ||
brrt | although i'm also very much pro-rakudo-in-nqp | ||
as in, 'lets kill PIR fast' | |||
cedrvint | masak++ # irclog.perlgeek.de/perl6/2013-01-03#i_6294423 | 13:27 | |
masak | cedrvint: well, it's like this: I've seen hundreds of these threads at this point. they all look alike. | 13:28 | |
cedrvint: the *good* outcome (from our perspective) is that the other guys say "well, I'm willing to wait and see if it turns into something nice". | 13:29 | ||
cedrvint: at which point I get back to helping Perl 6 and its implementations improve. | |||
so I just figure, why not short-circuit the process and avoid reddit altogether? :) it's not like convincing people on reddit is a intellectually fulfilling anyway :) | 13:30 | ||
13:30
geekosaur left
|
|||
cedrvint | for sure! :) | 13:31 | |
13:31
geekosaur joined
|
|||
masak | brrt: PIR is well on its way to obsolescence, if I read the tea leaves right. | 13:33 | |
brrt | good riddance | 13:35 | |
13:35
xinming left
|
|||
hoelzro | what's wrong with PIR? | 13:36 | |
hoelzro is lost | |||
masak | all other things being equal, the fewer the steps between source code and object code, the better. PIR is one of the steps that don't belong. | ||
13:36
xinming joined
|
|||
hoelzro | oh, ok | 13:36 | |
masak | you have to generate the PIR, then you have to parse the PIR. madness. | ||
it's committing the sin of making an intermediate format textual/linear, rather than structured/tree-like. | 13:37 | ||
13:38
JJ_Brain joined
|
|||
timotimo | if i have a grammar, can i easily create a parse tree from just data and use the grammar to emit a correct string representation? where in the spec do i find this? | 13:42 | |
masak | define "just data". | 13:43 | |
moritz | a Str? :-) | ||
masak | grammars won't get you a string from something else, no. not if I understand your question right. | 13:44 | |
anyway, if you have the parse tree and all the nodes know their string representation... just traverse and concatenate. :) | |||
13:45
Oejet joined
|
|||
arnsholt | Various people (myself included) have debated trying to generate from grammars, but it's definitely non-trivial (and not possible in the fully general case, I suspect) | 13:45 | |
13:45
am0c left
|
|||
arnsholt | But as masak says, if you have the data structure, generating a string representation should just be a matter of traversing the structure | 13:45 | |
Which may or may not be easy, depending on how complicated your data structure is | 13:46 | ||
timotimo | right. | ||
mikemol is very, very pro-rakudo-in-nqp. | |||
moritz | is there anybody how is contra rakudo-in-nqp? | 13:47 | |
mikemol | The more it's built on top of NQP, the more it becomes trivial to run it on top of god knows how many different languages. | ||
arnsholt is optimistic about the NQP/JVM thing | 13:48 | ||
I think it'll be good both for Perl 6 and Rakudo | |||
masak | yeah. | ||
Woodi | I have impression that Perl6 implementations have annoing habit of slapping you in face when you start to write something bigger... you start project becouse there is nice, shiny feature but after some lines you are blocked by lack of some basic feature every language should have... IO::Sockets problems in rakudo, GUI in Niecza... | 13:50 | |
arnsholt | Part of that boils down to the fact that interacting with the outside world is actually quite complicated and labour intensive | ||
mikemol | I mean, I've got a guy somewhat interested in writing NQP in Go. I know a JavaScript fan I might conceivably persuade to take an interest. I want to try it in C++ and Python. And I bet a cdent implementation from ingy would be fascinating. | ||
arnsholt | I think | ||
moritz | Woodi: then do something about it | 13:51 | |
masak | "progress depends on the unreasonable man" :) | 13:52 | |
Woodi | only one think which work nearly perfect in Perl6 is text mangling :) in text and network form :) | ||
moritz finds that object orientation works pretty well in rakudo too | |||
13:53
denisboyun_ left
13:54
stevan_ joined
|
|||
Woodi | moritz: I plan to try packaging I was talking few days before... but programming isn't my no. 1 or #2 skill :) | 13:55 | |
13:59
alec left
14:00
spider-mario joined
14:01
am0c joined
14:03
fgomez joined
|
|||
masak | today's mini-challenge: let f be a random mapping from 1..N to 1..N. what's the expected number of steps for the sequence 1, f(1), f(f(1)) ... to start repeating itself? | 14:04 | |
(courtesy of Knuth's 2011 Christmas tree lecture. apparently the answer contains pi somehow.) | |||
14:04
alec joined
|
|||
moritz | and you want... an answer? or a program that approximates an average? | 14:05 | |
masak | a Perl 6 program that simulates an answer, and tabulates it with the correct formula for comparison :) | 14:06 | |
masak is halfway done already | |||
14:06
cedrvint left
|
|||
masak | notice that the sequence doesn't have to go back to 1. it just has to loop back to any previous number in the sequence. | 14:08 | |
moritz | does 1, 1, 1, 1 count as a repetition count of 1? | 14:09 | |
or 0? | |||
masak | 0 isn't part of the mapping. | ||
oh, sorry. I see what you mean. | 14:10 | ||
it starts repeating after 1 step. | |||
so the sequence will always repeat after >1 steps. | |||
er >= 1 steps. | |||
14:11
PacoAir joined
|
|||
Woodi | answer should be quantified in % or should be Num ? | 14:11 | |
masak | the case N=1 contains only your sequence of only 1s. | ||
Woodi: the average of a lot of integers is either a Rat or a Num :) | 14:12 | ||
Woodi | but you need to interpret a given number shomehow :) | 14:13 | |
14:13
stevan_ left
|
|||
Woodi | or formula ? | 14:13 | |
moritz | masak: gist.github.com/45202bfd81a2a8dbdf87 | ||
14:15
stevan_ joined
|
|||
masak | ooh, you just run through them all. | 14:15 | |
I simulated randomly chosen mappings, Monte-Carlo-style. | |||
moritz | me too | ||
no, I don't generate all permutations | 14:16 | ||
masak | oh, right. | ||
but you adapt the number of trials to the size of $N. | |||
moritz | yes | ||
though it's rather crude | |||
masak | anyway, this is half the solution. the other half is to find the formula for the average. | ||
I still haven't found it. | |||
I should post my code, too. | 14:17 | ||
moritz | are you sure it's a mini challenge? :-) | ||
Woodi | if f is random mapping then f(f(1)) can be simplified as f(1) ? :) | 14:18 | |
masak | moritz: pretty sure :) | ||
moritz | random, not identical | ||
masak | here's mine: gist.github.com/4443780 | 14:19 | |
I'm usually not this different in style to moritz :) | |||
14:19
stevan_ left
|
|||
pmurias | mikemol: re built on top of nqp, to be more accurent rakudo is written in nqp and compiles code to QAST (which nqp also compiles code too) | 14:20 | |
moritz | oh, f doesn't need to be bijective? | ||
pmurias | mikemol: and someone was compiling tcl to QAST too ;) | 14:21 | |
masak | moritz: if it did, I woulda said "permutation", not "mapping". | ||
moritz: oh, now I see you assumed that. | |||
moritz: so did one in the audience of Knuth's lecture :) | |||
I simplified my gist.github.com/4443780 a bit -- the gather is better written as infix:<xx> | 14:22 | ||
moritz | uhm | 14:24 | |
if it's not bijective, the simulation doesn't terminate | |||
erm | |||
masak | surely you can't keep applying a function in a finite... | ||
moritz | nevermind | ||
masak | ...set without generating a loop? :) | ||
pmurias | jnthn: how are functions like &say,&prints loaded? | 14:25 | |
moritz | ok, now it's much faster | 14:26 | |
and produces smaller numbers | |||
masak | :) | ||
pmurias | jnthn: they don't get serialized right? | ||
masak | moritz: for reference, for N=20 I have the average as 5.2490 | 14:27 | |
moritz | masak: I have 5.365 | 14:28 | |
14:28
atrodo joined
|
|||
moritz has to run errands before turning to the analytical part of the solution | 14:29 | ||
masak | yeah, that's within the expected variation. I'm only running 1000 trials right now. | ||
moritz | well, I run 400 for 20 :-) | 14:30 | |
masak | things vary in the first decimal from run to run for me. | ||
pmurias | jnthn: I have found the answer to my question ;) | 14:31 | |
moritz | hey, I can generate @f lazily | ||
masak | searching for various things on ddg turns up nothing for this problem. makes it more interesting :) | ||
arnsholt | I wonder if this can't be seen as some kind of markov chain | ||
moritz | I have an idea on how to approach the analytical solution | 14:32 | |
but will have to delay persuing it | |||
bbl | |||
Woodi | if f will be defined sub f(x) { return x+1 } then answer will be N ? | ||
masak | arnsholt: it's a markov chain, but the set of state transitions is the thing we're varying. | ||
arnsholt | Yeah, it's not quite a standard markov chain | 14:33 | |
masak | Woodi: assuming f(N) = 1, yes. | ||
Woodi: but we're averaging over all possible f. | |||
[Coke] | (tcl to qast) ... was that me? | ||
and if not, who was it? ;) | |||
masak | Woodi: it's impossible for the cycle length to be >N | ||
14:35
denisboyun_ joined
14:43
JJ_Brain left
14:45
kaare_ joined
|
|||
masak | hmm. define L(N) as being the expected length for a random mapping from 1..N to 1..N. | 14:49 | |
from what I can see, L(1) = 1.0, L(7) = 3.0, L(12) = 4.0, L(18) = 5.0, and all these are exact. | 14:51 | ||
of course, it's hard to tell because of the Monte Carlo nature of it all. | |||
pmurias | [Coke]: I think that was you ;) | ||
14:51
erkan joined
|
|||
masak | if we find the analytical formula, this would be a nice task for rosetta code :) | 14:52 | |
pmurias | [Coke]: so your long term plan is to have tcl on the JVM? ;) | ||
[Coke] | pmurias: nah, that's already there. | 14:56 | |
it was "get tcl running on parrot for interop purposes." | 14:59 | ||
14:59
fgomez left
|
|||
[Coke] | ... but that failed due to a lack of general interest in interop. | 14:59 | |
(there was some very specific interest, but not widereaching) | 15:00 | ||
15:01
stopbit joined
15:02
am0c left
15:08
JJ_Brain joined
|
|||
masak | ok, I believe I have the analytical formula now. | 15:09 | |
15:13
JJ_Brain left,
nwc10 joined
|
|||
gfldex | r: gist.github.com/4444255 | 15:24 | |
p6eval | rakudo f5037e: OUTPUT«88("price" => 9800, "value" => 484953/50, "components" => Bool::False).hash8("price" => 9800, "value" => 484953/50, "components" => Bool::False).hash4("price" => 274974/25, "value" => 522151/50, "components" => Bool::False).hash158("price" => 1779/20, "value" =… | ||
gfldex | rn: gist.github.com/4444266 | 15:27 | |
p6eval | niecza v24-12-g8e50362: OUTPUT«(timeout)Potential difficulties: $k is declared but not used at /tmp/OXQm0Iz6yr line 131:------> caldari-fuel-block<components>[0,1] -> ⏏$k, $v { $v is declared but not used at /tmp/OXQm0Iz6yr line 131:------> dari-fuel-block… | 15:28 | |
..rakudo f5037e: OUTPUT«8Not enough positional parameters passed; got 1 but expected 2 in block at /tmp/qD1hVtUzmy:138» | |||
gfldex | i have two questions about that gist | ||
first, why the heck does niecza timeout? | |||
secondly, why does rakudo make a difference between line 134 and 138? | 15:29 | ||
[Coke] | gfldex: in one case you're iterating over a hash. in the other, you're iterating over a list. | 15:30 | |
the bare hash is better written ...<components>.kv -> $k, $v | |||
I think without the .kv you're getting the hash in $k, and then nothing for the $v. | 15:31 | ||
gfldex | it's not a hash | ||
check line 77 to 85 | |||
[Coke] | ... or my initial read could be way off! :) | ||
masak | rn: say sprintf '%12.5f', NaN | 15:32 | |
p6eval | rakudo f5037e: OUTPUT«NaN» | ||
..niecza v24-12-g8e50362: OUTPUT« NaN» | |||
masak submits rakudobug | |||
rn: say sprintf '%12.5f', Inf | |||
p6eval | niecza v24-12-g8e50362: OUTPUT« Infinity» | ||
..rakudo f5037e: OUTPUT«Inf» | |||
masak | rn: say sprintf '%12.5f', -Inf | ||
p6eval | rakudo f5037e: OUTPUT«-Inf» | ||
..niecza v24-12-g8e50362: OUTPUT« -Infinity» | |||
[Coke] | er, Parcel vs. List. hurm. | 15:33 | |
gfldex | and i'm quite sure that used to work before for got lazy | 15:34 | |
[Coke] | <components>.list seems to work. | 15:35 | |
masak | rn: say sprintf '%12.5f', 42 | ||
[Coke] | seems very similar to another lazy bug that was recently reported. | ||
p6eval | rakudo f5037e, niecza v24-12-g8e50362: OUTPUT« 42.00000» | ||
[Coke] | (sorry about my initial misread) | ||
gfldex | i can live with a .list workaround | 15:37 | |
does .list force it to be eager? | |||
15:38
bluescreen10 joined,
isBEKaml joined
|
|||
isBEKaml | hello, #perl6! | 15:38 | |
masak | isBEKaml! \o/ | 15:39 | |
timotimo | r: gist.github.com/3034309 | ||
p6eval | rakudo f5037e: OUTPUT«1..2ok 1 - ok 2 - » | ||
timotimo | yay | ||
[Coke] | gfldex: (.eager also STW.) | ||
isBEKaml | hello, masak! How's things? (Faster today? ;) | 15:41 | |
timotimo | hm. i've lost the file, but recently i tried to create a listing of all combinations and all lengths of A and B as a lazy list with a breadth-first-search type of output and ran into really, really strange effects that i couldn't explain to myself | 15:43 | |
15:43
colomon left
|
|||
timotimo | i think i may have done that in /tmp and then my laptop turned itself off at some point :| | 15:43 | |
i think i'll try to recreate that | |||
masak | um, hm. no, I don't think I have found the analytical formula after all :/ | 15:44 | |
kresike | bye folks | ||
15:45
kresike left
|
|||
nwc10 | moritz: is rakudo good enough to run the IRC logger yet? | 15:48 | |
15:48
[particle] left
|
|||
isBEKaml | masak: you're still on that balanced brackets thing? :) | 15:49 | |
dalek | rl6-roast-data: 98b6f30 | coke++ | / (4 files): today (automated commit) |
||
isBEKaml | .oO(Hours at a problem, problem of hours) :P |
15:50 | |
masak | isBEKaml: nono, this is the random maps thing :) completely different. irclog.perlgeek.de/perl6/2013-01-03#i_6294536 | 15:51 | |
timotimo | hrmpf. writing it for the second time i got to the solution faster, the code is cleaner, it's less strange and it works as it's intended to. great :| | 15:54 | |
gfldex | timotimo: do you fail at failing? | ||
timotimo | i think i just did :| | 15:55 | |
then again, i failed at failing at failing, so it's all right | |||
now i've hit a little roadblock WRT lazyness | 15:59 | ||
i'd like to have a list of lazy lists, so i want to replace this code: | |||
my @a := gather do_it([@start, A]); my @b := gather do_it([@start, B]); - with a loop over @values, where @values would have A and B in it | 16:00 | ||
my first attempt was this: my @sub-lists := gather do_it([@start[], $_]) for @values; | |||
but that seems to immediately eagerly want to resolve the lists - i believe that's due to flattening | 16:01 | ||
moritz | nwc10: might be worth a trial | ||
timotimo | so my next attempt was this: my @sub-lists := $(gather do_it([@start[], $_])) for @values; but that didn't cause it to work. maybe it's not a flattening problem after all? | ||
r: my @a := (1..., 2..., 3...); say @a[0][0]; say @a[1][10]; say @a[2][100]; | 16:05 | ||
p6eval | rakudo f5037e: OUTPUT«===SORRY!===Preceding context expects a term, but found infix , insteadat /tmp/ElVdkDX2XM:1------> my @a := (1...,⏏ 2..., 3...); say @a[0][0]; say @a[1][10» | ||
timotimo | r: say 1 ... *; | ||
p6eval | rakudo f5037e: OUTPUT«1 2 3 4 ...» | ||
timotimo | r: my @a := (1, 1 ... *, 2, 2 ... *, 3, 3 ... *); say @a[0][0]; say @a[1][10]; say @a[2][100]; | 16:06 | |
p6eval | rakudo f5037e: OUTPUT«===SORRY!===CHECK FAILED:Calling 'infix:<...>' will never work with argument types (Mu, Mu, Mu, Whatever) (line 1) Expected any of: :($a, $b)» | ||
timotimo | r: my @a := ((1, 1 ... *), (2, 2 ... *), (3, 3 ... *)); say @a[0][0]; say @a[1][10]; say @a[2][100]; | ||
p6eval | rakudo f5037e: OUTPUT«1Index out of range. Is: 10, should be in 0..0 in method gist at src/gen/CORE.setting:10346 in sub say at src/gen/CORE.setting:7515 in block at /tmp/CtnC9WJUYN:1» | ||
timotimo | er, now i'm somewhat confused | ||
oh, i think i may have the solution | 16:08 | ||
16:09
SamuraiJack joined
|
|||
timotimo | yes, indeed. this works: | 16:09 | |
my @a = \([$_, $_, ... *] for 1, 2, 3, 4); say @a[0][0]; say @a[1][10]; say @a[3][40]; | 16:10 | ||
r: my @a = \([$_, $_, ... *] for 1, 2, 3, 4); say @a[0][0]; say @a[1][10]; say @a[3][40]; | |||
p6eval | rakudo f5037e: OUTPUT«===SORRY!===Comma found before apparent series operator; please remove comma (or put parens\n around the ... listop, or use 'fail' instead of ...)at /tmp/rJNf894hU1:1------> my @a = \([$_, $_,⏏ ... *] for 1, 2, 3, 4); say @a[0… | ||
masak | r: say 42 ... *; | ||
timotimo | r: my @a = \([$_, $_ ... *] for (1, 2, 3, 4)); say @a[0][0]; say @a[1][10]; say @a[3][40]; | ||
p6eval | rakudo f5037e: OUTPUT«42 43 44 45 ...» | ||
rakudo f5037e: OUTPUT«1 1 1 1 ... 2 2 2 2 ... 3 3 3 3 ... 4 4 4 4 ...Any()Any()» | |||
timotimo | er, that's not what i expected after all :| | ||
moritz | timotimo: what do you want to achieve? | 16:13 | |
timotimo | r: my @a = \([$_, $_ ... *] for (1, 2, 3, 4)); say @a[0]; say @a[0]; say @a[0][0]; say @a[0][0][0]; say 'whyyyyyyyyyy?!'; | ||
p6eval | rakudo f5037e: OUTPUT«1 1 1 1 ... 2 2 2 2 ... 3 3 3 3 ... 4 4 4 4 ...1 1 1 1 ... 2 2 2 2 ... 3 3 3 3 ... 4 4 4 4 ...1 1 1 1 ... 2 2 2 2 ... 3 3 3 3 ... 4 4 4 4 ...1 1 1 1 ...whyyyyyyyyyy?!» | ||
moritz | and what's the \ supposed to do? | ||
timotimo | it's supposed to cause the lists to not be eagerly evaluated immediately | 16:14 | |
moritz | r: my @a := map { [$_ xx * ] }, 0..*; say @a[0][^5]; say @a[5][^5] | ||
p6eval | rakudo f5037e: OUTPUT«0 0 0 0 05 5 5 5 5» | ||
16:14
JJ_Brain joined
|
|||
moritz | timotimo: use binding instead | 16:14 | |
16:15
JJ_Brain left
|
|||
timotimo | doesn't seem to work on my more complicated example | 16:16 | |
which looks like my @sub-lists := map { gather doer([@start[], $_]) }, @values; | |||
the for @sub-lists { seems to cause it to be eagerly evaluated immediately. | |||
i'll quickly put it up on gist. | |||
16:17
bitonic` joined
|
|||
timotimo | r: gist.github.com/4444626 | 16:18 | |
16:18
jtpalmer joined
|
|||
p6eval | rakudo f5037e: OUTPUT«(timeout)» | 16:18 | |
16:19
bitonic left
|
|||
moritz | timotimo: well, you have that infinite loop { } | 16:21 | |
as soon as you try to .perl that, it runs away | 16:22 | ||
all the laziness can't fix your logic for you :-) | |||
timotimo | it's inside an outer gather, no? | ||
before i generalised it, it worked just fine. each element that falls out of do_it should be a finite list | 16:23 | ||
it should start with A and then B, then A, A and A, B then B, A and B, B and then three-element lists would follow | |||
16:23
aindilis joined
|
|||
timotimo | also, i limited the execution of do_it to yield only [^20] elements | 16:24 | |
oooh, i only now realized, you could do this with junctions: | 16:26 | ||
moritz 's brain explodes | |||
time to reconfigure | |||
timotimo | r: say any(&uc, &lc)("Foo!") | ||
p6eval | rakudo f5037e: OUTPUT«any(FOO!, foo!)» | ||
timotimo | r: say (&uc | &lc)("Foo!" | "Bar!") | 16:27 | |
p6eval | rakudo f5037e: OUTPUT«any(any(FOO!, BAR!), any(foo!, bar!))» | ||
masak | heh, I remember discovering that trick a few years back... :) | 16:29 | |
junctioning callables... and it Just Works. :) | |||
doesn't mean it's a good idea, though. in many cases, I would recommend against it. | |||
timotimo | sure | 16:30 | |
masak | in fact, I use junctions very sparingly nowadays. | ||
rule 1: don't let them escape an expression. | |||
moritz | masak: you discovered that trick, and opened a rakudobug | ||
masak | rule 2: don't let them escape a function. | ||
moritz: oh, I don't remember the rakudobug part, but that's entirely possible :) | |||
16:31
brrt left,
bitonic` is now known as bitonic
|
|||
timotimo | what's the worst than can happen when a junction escapes? | 16:31 | |
[Coke] | Replicators. | ||
masak | :) | ||
timotimo: I just find it gets difficult to reason about. | |||
timotimo | right. | 16:32 | |
did you look at my gist? i seem to have blown moritz' mind with it, but i still would like to get some help :) | |||
[Coke] | wow, pugs has been failing the daily runs for some time. | ||
16:32
kaleem left
|
|||
[Coke] | yesterday the build happened, but all the tests failed because the build had been failing for so long, I hadn't been able to make sure anything past that worked. | 16:32 | |
masak | timotimo: I have no idea what your goal is with that code. | 16:33 | |
timotimo | ah, of course | 16:34 | |
i was trying to lazily enumerate all combinations of all lengths of @values in a breadth-first-search kind of manner | |||
so A, B, AA, AB, BA, BB, AAA, AAB, ABA, ... | |||
the problem was to generalize from A, B to @values | |||
i could do my @a := gather doer(...); my @b := gather doer(...) just fine, but with the new code it immediately tries to eagerly create that @sub-lists list of lists | 16:35 | ||
i was hoping i could get the list of lists to be a list of lazy lists and shift one element from each of the lists in turn | |||
moritz | masak: my analytical result: www.wolframalpha.com/input/?i=Sum[n...C+1%2C+n}] | 16:38 | |
16:38
PacoAir left
|
|||
doy | oeis has the sequence, for what it's worth | 16:39 | |
oeis.org/A063169 | |||
moritz | yes, the description fits | 16:43 | |
16:43
denisboyun_ left
|
|||
masak | timotimo: does this work? | 16:45 | |
r: my @seed = <A B>; my @e = ""; loop { .say for @e = @e X~ @seed } | |||
p6eval | rakudo f5037e: OUTPUT«(timeout)ABAAABBABBAAAAABABAABBBAABABBBABBBAAAAAAABAABAAABBABAAABABABBAABBBBAAABAABBABABABBBBAABBABBBBABBBBAAAAAAAAABAAABAAAABBAABAAAABABAABBAAABBBABAAAABAABABABAABABBABBAAABBABABBBAABBBBBAAAABAAABBAABABAABBBABAABA… | ||
16:46
lolage joined
|
|||
timotimo | yeah, but that's way too simple! :) | 16:46 | |
masak | doy++ | ||
timotimo: I removed the laziness, but you should be able to add it back. | |||
16:46
rindolf joined
|
|||
timotimo | i used that example to learn more about lazyness in perl6 :P | 16:47 | |
maybe i can change the description of the problem to "get a lazy breadth-first-search of a graph"? ;) | 16:48 | ||
is there anything about tail recursion in the perl6 language? | |||
recursion would be a nice way to write down the BFS, but it could cause the stack to reach its limit easily in bigger graphs | 16:49 | ||
16:51
stevan_ joined
|
|||
timotimo | sprunge.us/AOFJ - i found the very old version of this code in the irclog | 16:55 | |
ingy | does rakudo or friends have a binding to a pcre engine at this time? | 17:01 | |
ingy has a module that he wants to write in perl6 today | |||
moritz | I don't think so | ||
timotimo | but perl6 has a backwards compatible perl5 regex mode | ||
moritz | which is only partially implemented | 17:02 | |
timotimo | hm, right. | ||
ingy | what's missing? | ||
come to think of it I might not need pcre style (like I would for pegex) | 17:03 | ||
I might be able to use p6rules | |||
17:04
isBEKaml left
17:05
isBEKaml joined
|
|||
ingy | this time I'm porting from Ruby! | 17:07 | |
ingy is a gem author finally: rubygems.org/profiles/ingy | 17:09 | ||
moritz | masak: gist.github.com/4445008 | 17:10 | |
masak | moritz: gist.github.com/4443780 | 17:11 | |
oh, I should add an error column, too :) | |||
also, I should extract the constant term from inside of the sum... :) | 17:12 | ||
moritz stole the FIRST trick for printing the headings | 17:13 | ||
17:13
JJ_Brain joined
|
|||
moritz | masak: since you call sprintf three times separately, it might be nicer to just use .fmt | 17:13 | |
17:14
Oejet left
|
|||
masak | hm, yes. | 17:15 | |
moritz | masak++ # nice mini challenge | 17:21 | |
moritz suppresses the urge to -- for distracting me from doing p6cc coding | |||
masak | :P | 17:22 | |
that's part of the challenge :) | |||
also, very punny naming the script "monte-carl.pl" :) | 17:23 | ||
now the only mystery is: where's pi? Knuth promised us a pi. | |||
moritz | :-) gald you noticed | ||
*glad | |||
masak | :) | ||
moritz | masak: maybe in the closed form of that sum | ||
masak | was it a red herring, or did I miss it as it snuck by? | 17:24 | |
right. | |||
could someone please close the sum? there's a draft, and the pi is getting cold. | |||
moritz | note that the sum looks an awful lot like a taylor series of an exp(x) function | ||
or maybe exp(x^2) or so | 17:25 | ||
masak is getting very good statistics | |||
moritz | and the integral over exp(-x^2) is sqrt(pi), iirc | 17:26 | |
masak | it is. | ||
something that took until multi-dim analysis to explain to us. >:( | |||
moritz | ah, the good integral-of-the-square trick, with coordinate transform | 17:27 | |
masak | aye. | ||
it's also trivial to solve with complex analysis, IIRC. | |||
moritz | oh, and it seems that the $N**2 dependency on the number of iterations is overkill | ||
$N is enough | |||
masak | ooh | ||
ingy has a strange craving for multi-dimsum | |||
masak | ingy++ # bad pun :) | 17:28 | |
moritz | well, complex analysis does the same coordinate transformation as the square trick | ||
masak | well, I seem to recall the trick as similar but different. | ||
there was an arbitrarily large circle involved. | |||
moritz | oh, you have the singularity, and do a line integral around it | 17:29 | |
masak | right. | ||
moritz | what's the name of that theorem again? | ||
17:29
JJ_Brain left
|
|||
masak | residue theorem? Picard's theorem? | 17:30 | |
"Cauchy's residue theorem" seems to be it. | 17:31 | ||
moritz | I think I know it as Cauchy's, aye | ||
masak | it's a special case of the generalized Stokes' theorem, according to Wikipedia. | ||
moritz | right, same stuff | 17:32 | |
very useful in physics, where integrating over an 1/r potential in space diverges, but you can always integrate over the perimeter | 17:33 | ||
17:34
bitonic left
|
|||
masak | ...literally circumventing the problem. | 17:34 | |
moritz | :-) | ||
17:35
SmokeMachine left
17:36
bitonic joined
|
|||
pmurias | is it possible to have to different settings in a compunit? | 17:39 | |
s/to/2 | |||
17:40
diakopter joined
|
|||
masak | "is it possible 2 have to different..." -- I don't get it. :) | 17:40 | |
17:41
SmokeMachine joined
|
|||
masak | pmurias: I think you're meant to be able to nest settings. | 17:42 | |
17:42
bitonic left
|
|||
masak | pmurias: but I have a hard time imagining more than one OUTER for a single block. | 17:42 | |
moritz | a setting can have an outer setting | 17:43 | |
masak | right. | 17:44 | |
so the answer is "transitively, yes. directly, no." | |||
[Coke] | ... we need to rename setting to turtle. | ||
17:45
bitonic joined
17:46
stevan_ left
|
|||
felher puts masak's mini challenge on top of his just4fun pile, where it might get tackled after $work | 17:47 | ||
17:47
kaleem joined
|
|||
masak | felher: it was fun indeed! | 17:48 | |
#perl6 solves the whole thing! -- gist.github.com/4443780 | 17:49 | ||
[Coke]: "it's settings all the way out." | |||
felher takes a closer look at this solution as soon as he has some spare time and at least one of the following statements is true: he has solved the problem himself || he has given up :) | 17:50 | ||
masak++ # providing a mini-challenge and a solution | 17:51 | ||
17:51
skids_ left
|
|||
masak | felher: actually, it was moritz++ who found the formula. | 17:51 | |
felher | well, moritz++ too, then :) | ||
masak | and it's still a sum, not a closed formula. we have reason to believe there's a closed formula and that it contains pi. | ||
see backlog. | |||
felher | kk, will probably do after $work | 17:52 | |
felher is afk again :) | |||
17:53
PacoAir joined
|
|||
masak creates an RC task :) | 17:54 | ||
pmurias | re chromatic blog post what "impedance mismatch of an alien memory model" do either JVM or JavaScript as NQP targets suffer? | 17:56 | |
moritz | r: our Str a; | 18:02 | |
p6eval | rakudo f5037e: OUTPUT«===SORRY!===Malformed ourat /tmp/4c9Ntb8a3b:1------> our Str ⏏a; expecting any of: scoped declarator» | ||
pmurias find it impossible to sign in on chromatic's blog to comment | 18:05 | ||
nwc10 | the only thing I feel confident saying is that I think that parrot suffered a *lot* from a lack of dogfood. | 18:08 | |
in that, there was no push to minimise the bootstrap to a working parrot, and then use that to run the rest of the build system | 18:09 | ||
hence Parrot's developers rarely actually end up running ./parrot (or a language atop it) for the tasks they work on the most | |||
I'm not sure if that's directly relevant to Rakudo or any other Perl 6 implementaiton. I don't know enough | 18:10 | ||
18:11
xinming left
|
|||
masak | RC task page created: rosettacode.org/wiki/Average_loop_length | 18:11 | |
moritz | masak++ | ||
masak | I'm proud of what has become of my previous RC task page. please make me proud of this one, too ;) | 18:12 | |
dalek | kudo/nom: cdb0fa6 | (Tobias Leich)++ | src/core/Exception.pm: fixed typos of X::Import::Redeclaration's message The list of symbols at the end only makes sense to print if they were not mentioned before. |
||
masak | nwc10: well, I do believe we dogfood quite a bit here on #perl6. and every time we do, we notice the benefits of it. could always dogfood more, of course. | 18:13 | |
18:13
xinming joined
|
|||
masak | actually, I notice two kinds of dogfooding, even. one is "use Perl 6 as part of developing Perl 6". another is "use Perl 6 in dayjob." | 18:13 | |
18:17
kaleem left
|
|||
masak | even goofing off with a mini-challenge, like I just did, generated a rakudobug. :) | 18:17 | |
18:21
FROGGS_ left,
FROGGS_ joined
|
|||
pmurias | nwc10: I use nqp a lot when working on nqp-js, but I don't use Perl6 besides developing Perl6 at all | 18:24 | |
18:26
SmokeMachine left
|
|||
moritz | std: our Str a | 18:30 | |
p6eval | std a8bc48f: OUTPUT«===SORRY!===Multiple prefix constraints not yet supported at /tmp/wbkt8Q60QJ line 1:------> our Str ⏏aMalformed our at /tmp/wbkt8Q60QJ line 1:------> our Str ⏏a expecting any of: multi_declarator typen… | ||
18:31
fgomez joined
|
|||
masak | pmurias: I find that even when I'm working in other languages, quite often I'm "thinking" in Perl 6. does that happen to you too? | 18:37 | |
pmurias | no | 18:38 | |
dalek | ast: 28a82e8 | moritz++ | S (2 files): RT #75640 |
||
moritz | happens to me | ||
pmurias | masak: "thinking" in NQP is not something I would be particularly fond of ;) | ||
flussence | There's been too much negativity outside today, so: Parrot is a good idea with good intentions, and the language which the majority of its users install it for is one of the nicer ones I've used even though it's incomplete. | ||
masak | pmurias: :) | 18:39 | |
flussence: agreed on both counts. | 18:40 | ||
flussence: though focusing on the positive aspects isn't enough for me in this case. Parrot could be better and Perl 6 could be more complete :) | |||
timotimo | where did this negativity come from? | 18:41 | |
masak | I'm assuming reddit. | 18:43 | |
outside of the echo chamber, there's another chamber, where people tend to vent on Perl 6. | 18:44 | ||
sometimes with factual statements. seldom in a nice way. | |||
[Coke] | and outside of THAT chamber, people say, "Perl? Isn't that dead?" ;) | ||
moritz | rakudo: sub foo ( $f = rand ) { say $f; }; say | 18:46 | |
p6eval | rakudo f5037e: OUTPUT«» | ||
moritz | rakudo: sub foo ( $f = rand ) { say $f; }; say Capture.new() ~~ &foo.signature | ||
p6eval | rakudo f5037e: OUTPUT«True» | ||
18:49
isBEKaml left,
xilo_ joined,
fgomez left,
fgomez joined
18:50
GlitchMr joined
|
|||
dalek | ast: 834d159 | moritz++ | S03-smartmatch/capture-signature.t: RT #77164, smart-matching against a signature with a default value |
18:50 | |
18:51
pmurias left
18:54
adu_ joined,
SmokeMachine joined
18:56
SmokeMac_ joined
18:57
FROGGS_ left,
FROGGS_ joined
|
|||
[Coke] | ETOOMANYCHAMBERS? | 18:58 | |
18:59
SmokeMachine left,
SmokeMachine joined
19:02
SmokeMac_ left,
am0c joined
19:06
SmokeMac_ joined
19:09
SmokeMachine left
|
|||
dalek | ast: 0093451 | moritz++ | S03-operators/range.t: RT #77572, infix .. is not associative |
19:13 | |
19:13
xilo_ left
|
|||
dalek | rl6-roast-data: 8d64c33 | coke++ | / (4 files): today (automated commit) |
19:14 | |
[Coke] | au++ # pugs back on the board with 33.83% of rakudo. | 19:15 | |
dalek | ast: b428149 | moritz++ | S32-exceptions/misc.t: RT #77582, error message when method is not found on a Hash |
19:16 | |
[Coke] | (down from 40.81% on 10/10/12 - mostly just needs fudging) | 19:17 | |
moritz | rakudo: () .= () | ||
p6eval | rakudo cdb0fa: OUTPUT«Method '' not found for invocant of class 'Parcel' in method dispatch:<.=> at src/gen/CORE.setting:949 in block at /tmp/TQZu2eZI53:1» | ||
moritz | std: () .= () | ||
p6eval | std a8bc48f: OUTPUT«Potential difficulties: Unsupported use of .= as append operator; in Perl 6 please use ~= at /tmp/nGVsi7cG8d line 1:------> () .=⏏ ()ok 00:00 43m» | ||
moritz is fine with either error message | 19:18 | ||
19:18
atrodo left
19:21
atrodo joined
|
|||
masak | huh -- Rakudo passed ~1000 new tests on 2012-11-03, taking Niecza down from 90.17% to 86.46%. what was that? | 19:24 | |
masak goes looking in Rakudo's history | |||
ah. heredocs :) | 19:25 | ||
perigrin | .seen dukeleto | 19:26 | |
phenny | perigrin: Sorry, I haven't seen dukeleto around. | ||
masak | apart from that big jump in November, it's just been a gradual slide since Rakudo overtook Niecza in terms of spectests in March. | 19:27 | |
nwc10 | best reaction to chromatic's post (or any of the naysayers) is prove 'em wrong with working code. | 19:28 | |
I hope we're getting there | |||
masak | nwc10: chromatic's post? url? | 19:29 | |
nwc10 | (to be clear, not counting chromatic as a naysayer. He's basing his opinions on experience) | ||
was a reference to him earlier. I assumed that it was this: www.modernperlbooks.com/mt/2012/12/...erl-6.html | |||
which correlated with the reference | |||
masak | I'm still surprised at how badly chromatic's experience seems to have burned him. | ||
nwc10 | I'm not totally. He put a massive amount of effort into doing the unfun debugging of parrot | 19:30 | |
particularly GC bugs | |||
something dedicated a chunk of his life to, he now describes as currently being on life support (as best he can tell) | 19:31 | ||
oh, missed a "he" in there. | |||
masak | "Heroics aren't sustainable." -- :( | 19:32 | |
masak hugs au++ | |||
19:33
supernovus joined,
SmokeMachine joined
|
|||
supernovus | Hi, is there any updates or additional info concerning github.com/perl6/specs/issues/26 as it stands now, SCGI, HTTP::Easy, LWP::Simple, JSON::RPC, and likely many other socket related libraries, are broken. | 19:34 | |
masak | people; www.modernperlbooks.com/mt/2012/12/...erl-6.html is one of the best posts chromatic++ has written. | 19:35 | |
read it. | |||
nwc10 | the bots are excused? :-) | 19:36 | |
masak | bots written in Perl 6 are excused :) | ||
19:37
uvtc joined
|
|||
masak | I agree with basically everything. my main point of disagreement with chromatic is his analysis of the current situation and its degree of hopelessness. | 19:37 | |
19:37
SmokeMac_ left
|
|||
masak | it's easy to miss, but 2012 has been *great*. | 19:37 | |
2013 will be better. | |||
nwc10 | me too | ||
uvtc | Saw the logs. Wanted to chime in, even though my opinion seems pretty orthogonal to what c is talking about. | ||
phenny | uvtc: 20 Dec 05:39Z <PerlJam> tell uvtc ah. Thanks. :-) | ||
uvtc | Regarding any negativity around Perl 6, my 2 cents is that the language seems rather complicated. My (possibly uninformed) impression is that it's probably complicated enough that the design is extremely difficult to get right. I've got no idea (nor opinion on) how "right" it currently is. I'm (mostly) waiting for there to be an official tutorial before spending more time with it. | 19:38 | |
masak | there are some things we don't do exceptionally well as an open-source community. | ||
we'll focus on those things. documentation, books, polish, whatever. | |||
_sri hopes the switch to the jvm will be a huge success | |||
masak | uvtc: "official tutorial" -- could you be more specific? | 19:39 | |
[Coke] | _sri: switch is probably not the right word. | 19:40 | |
_sri | [Coke]: now i'm concerned :S | ||
uvtc | I'm waiting for a Larry (or Damian?) to write a tut. When one of them does, to me that will be the bat-signal that it's time for "the masses" to start using Perl 6. | ||
As it stands, I'm pretty confused by Perl 6. | |||
uvtc shrugs. | 19:41 | ||
masak | the Perl 6 community could benefit a lot from pulling in more people. we're not ready to open the floodgates for everyone yet, but I believe there is a huge demographic out there who would be delighted by what's there already, and who would feed a lot of useful improvements back into the system. | ||
Woodi | uvtc: official book can take a years :) for C it was probably 10 :) | ||
uvtc | I don't need a Camel book. But Larry is (IMO, and others', I assume) a fabulous writer, and Perl 6 is his baby. | 19:43 | |
masak | "I didn't expect it to be perfect by any means, but I thought it'd at least by usable for some simple scripting tasks and some basic text processing. It wasn't usable for these, unfortunately." -- from news.ycombinator.com/item?id=4987396 | ||
I'd just like to say: three years' worth of p6cc contestants disagree. | |||
*I* disagree. | 19:44 | ||
Woodi | uvtc: I vote with two hands for trolling The Two for blogging :) | ||
masak | I've been using Rakudo for exactly that for *four years*. | ||
19:46
JJ_Brain joined
|
|||
uvtc | masak: I see what you mean; you'd love to attract more implementors at this point. | 19:48 | |
Woodi | masak: but: no GUI, no DB, NativeCalls not quite working... maybe start with db stuff, what's is needed for DBIsh to work ? | ||
dalek | osystem: 4a80264 | (Timothy Totten)++ | META.list: WWW::App::Easy is now WWW::App::MVC |
||
p/clang++-gh70: 10263fd | rurban++ | / (6 files): [GH #70] Enable clang++ compilation, proper function ptr casts Also fix a wrong C++ precedence: & has lower precedence than ==; == will be evaluated first [-Wparentheses] |
19:49 | ||
19:49
SmokeMac_ joined
|
|||
masak | Woodi: as far as I know, DBIish is working. | 19:49 | |
people have done GUI stuff, at least in Niecza. | 19:50 | ||
19:50
SamuraiJack left
|
|||
supernovus | I can confirm that DBIish with SQLite3 works just fine. Not that I can run the WWW::App::MVC test using it at the moment since Rakudo broke the IO::Socket.read() method. | 19:51 | |
Woodi | hmm, so I have outdated info.. Woodi-- | ||
uvtc | Woodi: if you mean trolling Larry and/or Damian for blogging, I'd much rather see a github perl6/doc beginner's tut authored by them, but I'm guessing that'll happen when the time is right. | 19:52 | |
19:52
SmokeMachine left
|
|||
Woodi | uvtc: why you want read ONLY tut from them ? it would be nice but someone other can write nice pages too me think... | 19:54 | |
and if you work in Sweden you can learn perl6 in school :) | |||
masak | that is true. | ||
then again, we've always been ahead of the curve here in .se | 19:55 | ||
Woodi | :) | ||
however private schools costs :) | |||
doy | for what it's worth, github.com/doy/p6-bread-board/blob...d/Board.pm is what i was working on the past week or so | ||
and while i did manage to make my way through it | |||
masak | I still remember the morning when taking the hoverboard to work started to feel... tedious. | 19:56 | |
doy | the number of bugs/nyi things i ran into was fairly disheartening | ||
masak | doy: yes, I was surprised too. | ||
doy | just as another data point | ||
masak | doy: I noticed you were running up against things. | ||
doy: I think I submitted O(3) bug reports thanks to your work. | 19:57 | ||
doy | i feel like a lot of the "it's not that buggy!" discussion comes from people who *have* been using it for 4 years now, and so know the parts of the language to avoid | ||
19:57
adu_ left
|
|||
masak | there should be a name for that effect. | 19:57 | |
uvtc | Woodi: it's not always easy collaborating on a cohesive opinionated doc. Anyhow, like I said, given the boundary conditions here, my guess is ... well, what I wrote above. :) | ||
masak | I noticed the same when writing the adventure game. "works here!" -- yeah, because I know which path to take through the game, and seldom try other paths. | 19:58 | |
doy: that's yet another reason to bring in new people. | |||
19:58
hash_table joined
|
|||
masak | doy: we need to sandpaper as many bright new minds against the implementations as possible. | 19:58 | |
some people will burn out as a result, because that's how sandpaper works. | 19:59 | ||
but the implementations will become more polished for it. | |||
supernovus | Yeah, I've rewritten several of my libraries multiple times over the last 4 years. The alpha to ng migration. The ng to nom migration. I'd like not to have to rewrite all the network related stuff to use a less intuitive read() method, but it seems nobody is interested in reverting to the DWIM behaviour. Maybe some new methods should be added to the spec, so we can have a choice between the Berkeley style and the DWIM style. TIMTO | 20:00 | |
WTDI and all that? | |||
masak | supernovus: fwiw, I think I heard pmichaud saying that he doesn't like the current state of .read breakage. | 20:02 | |
20:03
thou left
|
|||
supernovus | I like the idea of supporting both methodologies, a more "raw" version for those who want the closest-to-metal implementation, and a nice DWIM version for those of us who just want to be able to do a $socket.read($header-length); and have it "just work" :-) | 20:04 | |
20:04
SmokeMac_ left
|
|||
supernovus | Even if the DWIM version is just a candy coating for the more basic version, which is always what I assumed it to be anyway. | 20:05 | |
20:06
uvtc left
|
|||
Woodi | I was thinked about Berkeley sockets too... that Berkekeley API is standard and we should have it in Perl6. new gethostbyname (ip[46]) and rest too... universal 'read' and 'write' working in fs and network is good for general usage... but supernovus++ already say that :) | 20:07 | |
POSIX:: modules via NativeCalls ? | 20:08 | ||
20:13
skids_ joined,
JJ_Brain left
|
|||
supernovus | read() for DWIM version, and sread() for raw version? I dunno, I'm not a spec designer. I just know as a library author that the ability to say $header = $socket.read($header-length); and have it "just work" was amazingly brilliant in the previous Rakudo IO implementation, and I'd really like something like that back. | 20:13 | |
If you don't want two methods, you could have a named option to the read() method, say "exact" which would force it to use the DWIM semantics and return a Buf of the exact size (given that much data exists of course.) If omitted, the length becomes a "maximum" as per its current incarnation. | 20:17 | ||
20:17
hash_table left
|
|||
masak | supernovus: it feels to me that what you just said should go into an issue/ticket somewhere. do you know of one? I think I saw one flash by a week or so ago. | 20:20 | |
doy | the trouble with dwim interfaces to reading/writing type things is that you have to be very careful to get error handling correct | 20:21 | |
the reason the berkeley sockets api works the way that it does is that it's trivial to see that it's working correctly | 20:22 | ||
and then you can add whatever amount of error handling you want on top of it | |||
supernovus | masak: I could update github.com/perl6/specs/issues/26 to include at least a couple of my potential suggestions. I don't know what the best approach is, I'm just offering some basic ideas. | 20:23 | |
FROGGS | doy: I had the same experience like you. I wanted to port SDL, then recognized than I need a bit more than NativeCall, so I made Inline::C and then I ran into a bug that prevents merging multis | ||
masak | supernovus: please do. | 20:24 | |
supernovus: a copy-paste of what you've said here would be valuable. | |||
doy | i think that perl 6 probably has a robust enough exception mechanism to make writing a dwim thing doable | ||
FROGGS | doy: but as of today the bug is "fixed" (must be approved and applied), so the stuff I wrote will work in near future | ||
doy | you just have to be careful about it | ||
supernovus | doy: I agree that error handling must be done well. I also think we need to offer the Berkeley socket API, but that Perl 6, being the language to "make hard things easy" needs to have an easier way to do things than that. | 20:25 | |
masak | FROGGS: welcome to my world. :) | ||
doy | (and a low level api where you have to handle more things yourself is preferable to a higher level api where you might just randomly drop data sometimes) | ||
masak | FROGGS: workarounds, it's an art and a science :) | ||
FROGGS finally arrived in masak's world! o/ | 20:27 | ||
supernovus | As to be honest, rewriting all of the libraries to use a "read $*fixed-length number of bytes, until byte count is exactly $desired-length in a loop, then do what you want with the data" done in every single networking related library seems like a lot of unnecessary duplication when we could offer a version in the core that does exactly that in the background, but to the library-author, just returns $desired-bytes up front. No loo | 20:28 | |
p necessary. | |||
moritz | supernovus: I think it was a parrot change that caused rakudo's changed behavior | ||
supernovus: and I can totally see why a user wants the old behavior | 20:29 | ||
so, IMHO that's rakudo bug | |||
is there a ticket for that? | |||
masak | don't think so. | ||
please file. | |||
Woodi | additional problem is parrot - it is Perl5 VM - it have the moust used things built in. so a lot of duplications for implementing std api's. | 20:30 | |
moritz cannot parse that sentence | |||
and my disambiguation attempts hit semantic errors | |||
FROGGS | moritz: there is a github issue and a discussion | 20:31 | |
moritz | rakudo doesn't have github issues enabled | ||
Woodi | parrot is like Perl5 VM - have buffering for providing perl-ish look and feel, have a lot of syscals... | ||
FROGGS | moritz: here, in specs: github.com/perl6/specs/issues/26 | 20:32 | |
supernovus | Maybe, use the DWIM version of read() by default (since it was the default behaviour up until recently), and offer the more raw version under a different method name, or by requesting it via a named parameter. | ||
FROGGS | supernovus: well, it would do what it does right now if you pass 512, right? | 20:33 | |
so this "default chunk size parameter" just must be mentioned somewhere | |||
rurban | nqp seems to be broken: Missing or wrong version of dependency 'src/stage2/NQPCORE.setting' | 20:34 | |
supernovus | FROGGS: In theory it would do what it does not if you pass 512, yeah. | ||
moritz | rurban: what are you doing to get that error message? | ||
supernovus | s:g/not/now/ | ||
rurban | make realclean; perl Configure.PL && make | 20:35 | |
with latest parrot installed | |||
FROGGS | supernovus: so I'd vote for implementation notes in the spec or somewhere else | 20:36 | |
moritz builds now | |||
rurban | about the parrot read issues: we need a parrot ticket for this. and a testcase. | ||
masak | wow, I just assumed that there was a Parret ticket for .read already :/ | 20:39 | |
why did I assume that? | |||
Parrot* | |||
rurban | I cannot even find the perl6 ticket about it... | 20:40 | |
timotimo | how true is the statement that parrot is almost dead? | ||
or did i misunderstand? | |||
moritz | rurban: because there isn't one | ||
rurban | I just forwarded it to whiteknight, but he is busy. So I'll bite into it. | ||
20:40
xinming left
|
|||
masak | rurban: there's just github.com/perl6/specs/issues/26 | 20:40 | |
rurban++ | |||
moritz | timotimo: parrot development seems to happen in bursts these days | ||
rurban | timotimo: I have no idea. The parrot Changelog and branches are even more active than rakudo | 20:41 | |
20:41
Chillance joined
|
|||
moritz | sometimes rurban++ or nine++ or whiteknight++ do some big-ish stuff | 20:41 | |
and other month the changelog reads as if only minor build stuff was fixed | |||
*months | |||
20:42
xinming joined
|
|||
rurban | moritz: github.com/parrot/parrot/issues/909 | 20:44 | |
moritz | rurban: fwiw nqp master built fine for me, on parrot 4.10.0 | ||
rurban | interesting. so maybe I broke it. | ||
clang++ 3.3 -fsanitize=address testing | 20:45 | ||
supernovus | gotta go, be back later | ||
20:45
supernovus left
|
|||
moritz | rurban: you might try git clean -xdf in nqp | 20:45 | |
20:45
[particle] joined
|
|||
moritz | that's usually more thorough than make realclean | 20:45 | |
rurban: thanks for opening the ticket | 20:46 | ||
rurban | but I have a lot of threads patches lying around there :) | ||
moritz | rurban: I'm now trying it again with parrot/master, but this machine is very slow, so might take some time :-) | 20:47 | |
rurban | mine is faster, almost done | ||
nope, so parrot-4.11 is to blame here | 20:48 | ||
same error | |||
I changed the pmc and the ops compiler... | |||
hmm... | 20:49 | ||
Missing or wrong version of dependency 'src/stage2/QRegex.nqp' | |||
FROGGS | forgot to 'make install' ? | 20:52 | |
rurban | Nope, but I cleaned make install also... | ||
There were a lot of changes lately | |||
moritz | erm | ||
Can't locate Parrot/Pmc2c/PCCMETHOD_BITS.pm in @INC | |||
that's what I get while trying to build nqp | |||
rurban | good | ||
That's github.com/parrot/parrot/issues/890 then | |||
20:54
FROGGS_ left
|
|||
rurban | thanks for the catch, my error. will be fixed immediately | 20:55 | |
21:03
GlitchMr left,
Kharec left
|
|||
rurban | cannot reproduce, and could not find a parrot error. I got ./src/stage0/NQP-s0.pir:.annotate 'file', "src/stage2/gen/NQP.pm" but src/stage2/ does not exist yet | 21:03 | |
sorear | o/ | 21:04 | |
FROGGS | hi sorear | ||
masak | sorear! \o/ | ||
[Coke] wonders if one of you has an installed parrot elsewhere that is confusing things. | |||
Woodi | hmm, so nqp-not-on-parrot need to implement all file bufferings ? | 21:05 | |
moritz | rurban: if it helps, my rakudo dir is actually a symlink | 21:06 | |
moritz@lara:~>ls -ld p6/rakudo | |||
lrwxrwxrwx 1 moritz moritz 35 Apr 30 2010 p6/rakudo -> /nocrypt-home/moritz/source/rakudo/ | |||
rurban | I'm building nqp from a clean git clone'd dir | ||
independent form rakudo | |||
from | 21:07 | ||
trying now --gen-parrot (4.10.0) | |||
moritz | well, my nqp and parrot dirs are below the rakudo dir | ||
[Coke] | rurban++ btw, for hanging out in this channel. Thanks. | ||
rurban | well, there is a big change that I broke rakudo :) | 21:08 | |
ok, with --gen-parrot it works fine. | 21:09 | ||
moritz | 4.10.0 worked for me too | 21:10 | |
rurban | I'll bisect it | ||
wanted to say: well, there is a big chance that I broke rakudo | 21:12 | ||
we are doing parrot-5.0 testing now | |||
21:15
att__ left
21:16
tipdbmp joined
21:17
att__ joined
|
|||
moritz | rurban: should I open an issue for Can't locate Parrot/Pmc2c/PCCMETHOD_BITS.pm ? | 21:19 | |
rurban | nqp compiled ok with parrot master if created via --gen-parrot RELEASE_4_11_0-98-g5d697e5 | ||
moritz: that's your problem. you must do a make clean before make install. | 21:20 | ||
moritz | rurban: make clean in parot? | ||
rurban | make install will just install the freshly generated files, and this files was left over | ||
yes | |||
moritz | ok | ||
rurban | make install is driven now from a generated MANIFEST.generated | ||
moritz | will do | 21:21 | |
rurban | previously it was a hardcoded MANIFEST.generated (with a lot of old cruft) | ||
(and some missing entries) | |||
so nqp only has a problem from a globally installed parrot | 21:22 | ||
tipdbmp | How to resolve the "circular dependency": class A { method a(B $b) { ... } } class B { method b(A $a) { ... } } | ||
doy | tipdbmp: class B {...} at the beginning | 21:23 | |
tipdbmp | Nope, same thing. | ||
21:23
kurahaupo joined
|
|||
masak | those ... dots are literal. | 21:23 | |
you literally put them in. | |||
r: class B { ... }; class A { method a(B $b) {} }; class B { method b(A $a) {} }; say "alive!" | 21:24 | ||
p6eval | rakudo cdb0fa: OUTPUT«alive!» | ||
doy | class B {...}; class A { method a(B $b) { ... } }; class B { method b(A $a) { ... } } | ||
tipdbmp | The error is that type methoda a(B $b) # type B is not found / typename not found | ||
masak | tipdbmp: works; see above. | ||
tipdbmp | Oh, I see. | ||
masak | literal dots? :) | 21:25 | |
tadzik | good evening | ||
kurahaupo | Can they be spelt with a unicode elipsis instead? \u2026 | ||
masak | tadzik! \o/ | ||
kurahaupo: not in standard Perl 6, no. | |||
tadzik | good day :) | ||
kurahaupo | masak: there are a bunch of useful extra punctuation in the \u2010 ~ \u205f range; in particular think \u2024 "…" for "..." and \u2047 "⁇" for "??" would be nice to have. | 21:30 | |
masak | kurahaupo: if it were up to me, we would have *less* Unicode in Perl 6, not more. :) | 21:33 | |
doy | say "hi" if defined $foo | 21:34 | |
kurahaupo | Fair point. | ||
diakopter | masak++ | ||
masak | kurahaupo: sorry, I know that's the boring, unadventurous answer. | 21:35 | |
kurahaupo: all is fair if you predeclare, though. | |||
'use More::Unicode;' | |||
rurban | moritz: strange github.com/perl6/nqp/issues/71 | ||
kurahaupo | use Even::More::Unicode :with(punctuation); | 21:36 | |
21:46
MayDaniel left
|
|||
pmichaud | rurban: (nqp #71) did you do a "make clean" or "make realclean" before attempting to build nqp using the globally installed parrot? | 21:48 | |
rurban | even git clean -dxf | ||
I have a little patch to test parrot master with nqp | 21:49 | ||
at #71 | |||
pmichaud | that patch doesn't look right to me | 21:50 | |
masak | phenny: tell grondilu that I think rosettacode.org/mw/index.php?title=...did=149561 made a mathematical-looking expression much less easy to understand :/ | ||
phenny | masak: I'll pass that on when grondilu is around. | ||
21:50
MayDaniel joined
|
|||
rurban | if you tell tools/build/PARROT_REVSION (same for NQP) to force master, then the cmp_rev should always win. | 21:51 | |
pmichaud | PARROT_REVISION should never be set to 'master' | ||
rurban | because there's nothing bigger than master | ||
pmichaud | it's always supposed to be an actual revision number | ||
rurban | I wanted to test master with --gen-parrot, but got an wrong looking error | 21:52 | |
pmichaud | should be --gen-parrot=master | ||
if that doesn't work, it's a bug | |||
rurban | oh, thanks | 21:53 | |
$ perl Configure.pl --gen-parrot=master | |||
Unrecognized revision specifier 'master' | |||
pmichaud | but changing PARROT_REVISION to 'master' isn't really the intent | ||
rurban | I know. | ||
just a hack to test it | |||
masak | phenny: tell grondilu also, I can't reproduce the bug you seem to be compensating for in rosettacode.org/mw/index.php?title=...did=149562 -- old rakudo? | ||
phenny | masak: I'll pass that on when grondilu is around. | ||
pmichaud | pmichaud@kiwi:~/p6/nqp$ perl Configure.pl --gen-parrot=master | 21:54 | |
Cloning into 'parrot'... | |||
...works here. | |||
rurban | It failed because I had master as PARROT_REVISION | 21:55 | |
now it works for me also. | |||
I deleted my hack | |||
pmichaud | one can use --gen-parrot with any (git) revision specifier, including branches. | 21:56 | |
same goes for Rakudo | |||
rurban | I still have the nqp compile problem with a new installed parrot devel version | 22:00 | |
(I deleted the wrong comments about my hack) | |||
pmichaud | master branch? | 22:02 | |
(parrot master?) | |||
rurban | yes | ||
pmichaud | testing locally | ||
rurban | I think it has something to do with -devel | ||
And I don't understand the ModuleLoader logic | 22:03 | ||
pmichaud | I don't understand "-devel" | ||
you mean the fact of building from a git clone version? | 22:04 | ||
rurban | This is Parrot version 4.11.0-devel built for amd64-linux | ||
yes | |||
pmichaud | well, that's what --gen-parrot typically does | ||
rurban | but it works if installed into install/ | ||
pmichaud | it works if parrot master is installed into install/ ? | 22:05 | |
rurban | I'll compare the two trees... | ||
yes | |||
pmichaud | there shouldn't be much of a difference there, then | ||
dalek | p: 8423e0a | pmichaud++ | Configure.pl: Change Configure.pl --help to mention [=branch] option of --gen-parrot. |
||
rurban | thanks | ||
22:05
bluescreen10 left
|
|||
pmichaud | I get | 22:06 | |
Can't locate Parrot/Pmc2c/PCCMETHOD_BITS.pm in @INC (@INC contains: /home/pmichaud/p6/parrot/install/lib/4.11.0-devel/tools/build/../../lib /home/pmichaud/p6/parrot/install/lib/4.11.0-devel/tools/build/../lib /etc/perl /usr/local/lib/perl/5.14.2 /usr/local/share/perl/5.14.2 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.14 /usr/share/perl/5.14 /usr/local/lib/site_perl .) at /home/pmichaud/p6/parrot/install/lib/4.11.0-devel/tools/build/../lib/Parrot/Pmc2 | |||
rurban | same as moritz | ||
pmichaud | from pmc2c | ||
rurban | hmm, this indicates that your parrot was not clean before make install | 22:07 | |
pmichaud | I just did a fresh checkout, git clean -xdf, configure, make, makeinstall | ||
rurban | MANIFEST.generated did not contain all files it should generate | ||
pmichaud | but I can do it again | ||
rurban | hmm... | ||
This was a recent change | 22:08 | ||
22:08
[particle] left
22:09
Chillance left
|
|||
rurban | I see. git clean -dxf does not clean parrot/ | 22:09 | |
this is a leftover | 22:10 | ||
pmichaud | but I'm not ussing parrot/ | ||
since I installed in a different location | |||
still, I'm removing parrot/ explicitly and see if I get the same result. | |||
rurban | manually rm -rf parrot/ solved it for me | ||
diakopter | I had that exact problem a while ago | ||
I suspected it was because parrot was in the .gitignore | 22:11 | ||
rurban | Maybe we should make install more stable. | ||
pmichaud | if it's finding a wrong parrot, that indicates a path problem somewhere with parrot. | ||
rurban | check for Parrot/Pmc2c/PCCMETHOD_BITS | ||
pmichaud | correct, doing rm -rf parrot from the nqp directory seems to have solved the problem for me as well | 22:13 | |
so, something in pmc2c is looking in the wrong place or grabbing the wrong parrot binary/libraries | |||
22:13
nyuszika7h left
22:14
nyuszika7h joined
|
|||
pmichaud | either that or nqp's Makefile is grabbing the wrong pmc2c | 22:14 | |
rurban | I'll fix this: github.com/parrot/parrot/issues/910 | 22:16 | |
22:20
thou joined
22:23
kaare_ left
22:24
grondilu joined
|
|||
rurban | include/parrot/4.11.0-devel vs include/4.11.0-devel | 22:26 | |
parrot_config versiondir is different | 22:27 | ||
parrot_config versiondir vs install/bin/parrot_config versiondir | |||
do you have a special parrot prefix or version dir logic? I don't see any. I'll check parrot | 22:29 | ||
we have one. | 22:31 | ||
moritz | rurban: fvwiw rakudo and nqp build fine for me on parrot RELEASE_4_11_0-98-g5d697e5 | ||
moritz -> sleep | 22:32 | ||
rurban | There is a strange parrot logic which check the buildpath if it includes /parrot | ||
22:32
Chillance joined
|
|||
rurban | mine does | 22:32 | |
22:36
Pleiades` left
22:41
Pleiades` joined
|
|||
pmichaud | ...checks the buildpath or install path? | 22:42 | |
rurban | install path, but with installpath it is under the buildpath | 22:43 | |
but with --gen-parrot the installpath is ... | |||
pmichaud | that checking for /parrot sounds completely bogus to me (more) | 22:44 | |
for example, I often install to a path that includes '/parrot' somewhere in the path, even if it's not part of the build tree | |||
rurban | yes, this logic needs to be a bit stricter. But now I have the catch the real bug caused by this. | 22:45 | |
pmichaud | looking at the pathname for a specific string sounds very fragile to me | ||
rurban | See config/init/install.pm:42 | 22:46 | |
22:47
PacoAir left
|
|||
rurban | hmm, the versiondir logic seems good to me. if under parrot already omit another /parrot/... | 22:50 | |
dalek | rakudo/froggs_mergemulti: 0f0bb50 | jonathan++ | src/binder/bind.c: | 23:03 | |
rakudo/froggs_mergemulti: Teach compile time bind analysis about (|) sig. | |||
rakudo/froggs_mergemulti: | |||
rakudo/froggs_mergemulti: It now recognizes such a signature as accepting anything, and thus | |||
rakudo/froggs_mergemulti: certain to be a successful match. | |||
23:03
dalek left
|
|||
FROGGS | uhh | 23:03 | |
23:03
dalek joined,
ChanServ sets mode: +v dalek
|
|||
dalek | ast/froggs_mergemulti: f579a22 | (Tobias Leich)++ | S11-modules/import-multi.t: new tests for multi symbol merging |
23:07 | |
23:13
bbkr joined
|
|||
masak | ♞y-♞, #perl6 | 23:18 | |
FROGGS | aloa | 23:20 | |
bbkr | github.com/parrot/parrot/issues/909 - looks like Rakudo socket issue goes deeper. fix was marked as milestone for parrot 5.0. will there be any workaround till then on Rakudo/NQP level? | 23:21 | |
23:25
MikeFair_ left
23:34
stopbit left
23:36
fgomez left
|
|||
rurban | bbkr: yes, I marked it as milestone for the next release. At least we need some decisions, change spec or force changing user code. | 23:43 | |
bbkr | rurban: thanks! | ||
FROGGS | bbrk: a workaround in rakudo might be pretty simple when looking at this: github.com/rakudo/rakudo/blob/nom/...pm#L26-L34 | 23:46 | |
rindolf | Hi all. | 23:47 | |
FROGGS, rurban , masak , pmichaud : meow. | 23:48 | ||
rindolf wrote the most ad-hoc XML grammar ever. | |||
FROGGS | hi rindolf | ||
rindolf | But it only has an RNG and a sample XML file - not an XSLT yet. | ||
I can try converting it to DocBook instead of XHTML directly. | 23:49 | ||
23:50
MikeFair_ joined
|
|||
bbkr | FROGGS: should it be reported as rakudobug then? from user point of view - it is rakudobug because current behavior does not match spec, right? | 23:50 | |
FROGGS | bbkr: I think so too, but I'm still a n00b here, so not 100% sure | 23:51 | |
bbkr: I'd love to fix it though | 23:54 | ||
bbkr | FROGGS: I'm preparing simple code to demonstrate differences between 2012.11 and 2012.12. Then I will create ticket so change will be documented. Rest is up to you because I'm a total nqp/pir noob :) | 23:59 |