| 2017-09-08 |
| ← itaipu left | 00:01 |
| ← mack[m] left | 00:02 |
| → cpage_ joined | 00:04 |
| → mack[m] joined | 00:14 |
| → audiatorix joined | 00:22 |
|
audiatorix
| Hey dudes. I'm still adjusting to 6's new regex system. Any idea why the following is producing this error?: No such method 'Letter' for invocant of type 'Match' | 00:23 |
|
| my regex arg { <Letter>+ } | 00:24 |
|
| my regex call { <arg>[\,\s*<arg>]* } | 00:24 |
|
| 'aa' ~~ /<call>/ # error produced here | 00:24 |
|
raschipi
| Where is letter defined? | 00:25 |
|
audiatorix
| It's one of the defaults, no? | 00:25 |
|
| Or does it need to be L? | 00:25 |
|
| Same error with L | 00:25 |
| → mr_ron joined | 00:27 |
|
mr_ron
| rakudo: my regex arg { <:Letter>+ }; say so "abc" ~~ /<arg>/ | 00:28 |
|
camelia
| rakudo-moar 347da8: OUTPUT: «True» | 00:28 |
|
audiatorix
| Ah, needs the colon | 00:28 |
|
raschipi
| Yeah, it's missing the : to be a chaachter class. | 00:28 |
|
audiatorix
| Right, so char classes need colons and other regexes do not | 00:29 |
|
| Thanks | 00:29 |
|
raschipi
| There's <alpha> without the colon too. | 00:30 |
| → armin_ joined | 00:30 |
|
raschipi
| as a predefined subrule as you asked for | 00:30 |
|
audiatorix
| Yeah just saw that | 00:30 |
|
| I was just testing out my knowledge before writing something more complicated to parse basically function calls | 00:31 |
|
| making a templater | 00:31 |
| ← mr_ron left | 00:31 |
| → BenGoldberg joined | 00:33 |
| ← armin left | 00:34 |
| → dj_goku joined | 00:37 |
| → RID_1984 joined | 00:40 |
| ← RID_1984 left | 00:41 |
| → kyan joined | 00:41 |
|
AlexDaniel
| switching to another laptop is harder than moving to another place :-S | 00:41 |
| ← dj_goku left | 00:43 |
| ← margeas left | 00:49 |
|
raschipi
| audiatorix: remember to call a predefined regex with a dot in front to supress capture: | 00:54 |
|
| m: say 'abc' ~~ /<alpha>+/; say 'def' ~~ /<.alpha>+/ | 00:54 |
|
camelia
| rakudo-moar 347da8: OUTPUT: «「abc」 alpha => 「a」 alpha => 「b」 alpha => 「c」「def」» | 00:54 |
| ← konsolebox left | 00:56 |
| → konsolebox joined | 01:01 |
|
b2gills
| AlexDaniel: I was locked out of my password manager once, because I was using a laptop that I hadn't used recently. (I eventually found a way to get in) | 01:02 |
|
AlexDaniel
| b2gills: :O | 01:03 |
|
b2gills
| It required using the /info cmd on IRC to get an IP address to SSH into | 01:03 |
|
AlexDaniel
| being locked out of your password manager sounds really horrible | 01:05 |
|
| I do have backups of my passwords *somewhere*… maybe I should practice the emergency situation :-/ | 01:06 |
|
raschipi
| AlexDaniel: Make sure you can restore from your backups, it's important. | 01:07 |
|
AlexDaniel
| well, my passwords is the only thing I have to backup. All code I write is in git repos (so also pushed somewhere), everything else I really don't care about | 01:09 |
|
| not that I wouldn't be sad for a minute or two if I lose it, but I am not spending my time trying to create backups for it :) | 01:09 |
|
raschipi
| Buy a strong box and store your passwords there. | 01:11 |
| ← dogbert2 left | 01:11 |
|
AlexDaniel
| alternatively, just upload it to github… then I only have to backup my private key :D | 01:12 |
|
raschipi
| How to you want to use your private key to access github without it's password? | 01:13 |
|
AlexDaniel
| it can be a public repo | 01:14 |
|
raschipi
| Instead make it passwordless, then. Then just keep it safe. | 01:16 |
| ← Skarsnik left | 01:29 |
|
audiatorix
| Any idea why this regex is invalid?: -<[ \$ \, ]>+ | 01:34 |
|
| What I'm trying to achieve is "anything but literal $ or literal , one or more times" | 01:34 |
|
geekosaur
| shouldn't that start with <-[ instead of -<[ ? | 01:35 |
|
audiatorix
| Ah, so it should | 01:36 |
|
| What's the logic behind that? | 01:36 |
|
| [] on their own simply group | 01:37 |
|
geekosaur
| same reason an older regex does something different with [-... vs. -[... | 01:37 |
|
| <> is a meta-operation of some kind, - prefix means invert, [] is char class. vs. without the <>, [ ] is non-capturing group | 01:38 |
|
audiatorix
| Ah okay, that's what I was thinking once I saw the answer | 01:38 |
|
geekosaur
| the first character after a < in a < > is special, - inverts the metaop, . prevents capturing (used with named rules like <ws> or <digit>) etc. | 01:38 |
|
| (this is oversimplifying a bit) | 01:39 |
|
audiatorix
| Cool | 01:40 |
|
| So, different question: in a grammar, how do I specify that, in a given place, either token A or token B may appear? | 01:40 |
|
geekosaur
| A | B | 01:42 |
|
audiatorix
| <A> | <B> ? | 01:42 |
|
AlexDaniel
| yea | 01:42 |
|
geekosaur
| with brackets around if it's part of a larger thing e.g. <foo> [ <bar> | <baz> ] <quux> | 01:43 |
|
AlexDaniel
| or maybe || if you care about order and not about longest token matching | 01:43 |
|
audiatorix
| And if I needed to use that more than once, would throwing it in a sub-regex make sense (so that a new token doesn't need to be created for it) | 01:45 |
| ← ilbot3 left | 01:45 |
|
AlexDaniel
| “sub-regex”? | 01:46 |
|
| I guess there's no problem with creating another token for it. But I don't know what would be the best practice | 01:46 |
|
audiatorix
| named regex | 01:46 |
|
| I'm thinking if I make another token, it will make the structure more complex where it doesn't need to be | 01:47 |
|
geekosaur
| um, they all add the same complexity | 01:47 |
|
| they just have different default behaviors | 01:47 |
|
| (i.e. different default flags on the things they create, like :sigspace or :ratchet etc.) | 01:48 |
|
audiatorix
| Ah | 01:48 |
|
| dang, I was thinking for some reason that `regex` didn't become part of the resulting structure when parsing | 01:48 |
|
geekosaur
| they're all just specialized variants of methods | 01:49 |
| → cuonglm joined | 01:49 |
| ← char_var[buffer] left | 01:50 |
|
geekosaur
| the closest you get to not adding more structure is an interpolating variable that isn't treated as a literal <$foo> and that has other issues, including performance and potential security concerns | 01:51 |
|
[Coke]
| n | 01:51 |
|
| ~>OA | 01:51 |
|
audiatorix
| Okay, I'll just have it twice in the TOP token | 01:52 |
|
[Coke]
| ... weird. | 01:52 |
|
audiatorix
| not a huge deal | 01:52 |
|
| Thanks a ton | 01:52 |
| → francesco_ joined | 01:52 |
| → ilbot3 joined | 01:54 |
| ChanServ set mode: +v | 01:54 |
| ← geekosaur left | 01:54 |
|
raschipi
| audiatorix: I gave you the answer above, put them into another method but call it with a dot to avoid making the capture more complex. | 01:55 |
|
| m: say 'abc' ~~ /<alpha>+/; say 'def' ~~ /<.alpha>+/ | 01:56 |
|
camelia
| rakudo-moar 347da8: OUTPUT: «「abc」 alpha => 「a」 alpha => 「b」 alpha => 「c」「def」» | 01:56 |
| ← Franciman left | 01:56 |
| → geekosaur joined | 01:57 |
|
audiatorix
| Oh, so you did. My bad | 01:59 |
| ← pilne left | 02:02 |
| → noganex_ joined | 02:17 |
| → dj_goku joined | 02:17 |
| ← dj_goku left | 02:17 |
| → dj_goku joined | 02:17 |
| ← noganex left | 02:20 |
| ← wamba left | 02:23 |
| → llfourn joined | 02:39 |
| ← geekosaur left | 02:42 |
| → geekosaur joined | 02:45 |
| ← Cabanossi left | 02:55 |
| ← eliasr left | 02:55 |
| → Cabanossi joined | 02:57 |
| ← Actualeyes left | 03:08 |
| → snarkyboojum joined | 03:13 |
| ← Cabanossi left | 03:40 |
| → Cabanossi joined | 03:42 |
| ← Cabanossi left | 03:54 |
| → Cabanossi joined | 03:56 |
| ← AlexDaniel left | 04:09 |
| ← dj_goku left | 04:14 |
| ← cuonglm left | 04:14 |
| → dj_goku joined | 04:15 |
|
raschipi
| audiatorix: Did my suggestion work? | 04:18 |
| ← cpage_ left | 04:21 |
| → kaare_ joined | 04:36 |
| → Actualeyes joined | 04:43 |
| → cpage_ joined | 04:58 |
| → xtreak joined | 04:58 |
| ← skids left | 05:09 |
| ← audiatorix left | 05:12 |
| ← BenGoldberg left | 05:19 |
| ← khw left | 05:19 |
| → audiatorix joined | 05:19 |
| → khw joined | 05:23 |
| ← Cabanossi left | 05:25 |
| → Cabanossi joined | 05:26 |
| ← kyan left | 05:33 |
| → ufobat joined | 05:45 |
| ← snarkyboojum left | 05:45 |
| → lowbro_ joined | 05:58 |
| ← lowbro left | 06:00 |
| → ash_gti joined | 06:07 |
| ← xtreak left | 06:14 |
| → zakame joined | 06:25 |
| ← xiaoyafeng left | 06:26 |
| → leont joined | 06:26 |
| → ChoHag joined | 06:32 |
| ← leont left | 06:42 |
| → gigavinyl joined | 06:44 |
| ← gigavinyl left | 06:45 |
| → jonas1 joined | 07:01 |
| ← raschipi left | 07:02 |
| ← ash_gti left | 07:08 |
| ← Cabanossi left | 07:08 |
| → Cabanossi joined | 07:11 |
| → nattefrost joined | 07:12 |
| → darutoko joined | 07:17 |
|
Geth
| ¦ doc/split-and-rephrase-lines-in-footer: c108ce774f | (Zak B. Elep)++ | 2 files | 07:24 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: Split and rephrase lines in the footer | 07:24 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: | 07:24 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: The first paragraph/line was getting too long, so split it a bit and | 07:24 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: rephrase to emphasize source location and actions to either report | 07:24 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: issues and/or edit/fork. | 07:24 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: | 07:24 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: Fixes #1535. | 07:24 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: review: https://github.com/perl6/doc/commit/c108ce774f | 07:25 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: 4cff7ee700 | (Zak B. Elep)++ | lib/Pod/Htmlify.pm6 | 07:25 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: :lipstick: phrasing for "from POD6 at perl6/doc"... | 07:25 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: | 07:25 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: "From POD6 from perl6/doc" sounds odd... | 07:25 |
|
| ¦ doc/split-and-rephrase-lines-in-footer: review: https://github.com/perl6/doc/commit/4cff7ee700 | 07:25 |
| ← Sgeo left | 07:26 |
| → leont joined | 07:35 |
| → piojo joined | 07:39 |
|
piojo
| Have others gotten this error when trying to build?: "Unhandled exception: Unable to allocate an array of 8 elements" | 07:40 |
|
| The first instance of the error is: | 07:42 |
|
| perl.exe -MExtUtils::Command -e cp 3rdparty\dyncall\dyncallback\\*.h .rakudobrew\moar-blead-nom\install\include\dyncall Unhandled exception: Unable to allocate an array of 8 elements at <unknown>:1 (src/vm/moar/stage0/ModuleLoader.moarvm:) from <unknown>:1 (src/vm/moar/stage0/ModuleLoader.moarvm:<dependencies+deserialize>) from <unknown>:1 (src/vm/moar/stage0/nqp.moarvm:<dependencies+deserialize>) | 07:42 |
|
| building on windows, and it worked last time I tried. | 07:42 |
| → raschipi joined | 07:45 |
| → travis-ci joined | 07:45 |
|
travis-ci
| Doc build passed. Zak B. Elep ':lipstick: phrasing for "from POD6 at perl6/doc"... | 07:45 |
|
| https://travis-ci.org/perl6/doc/builds/273197377 https://github.com/perl6/doc/compare/c108ce774f43^...4cff7ee700c1 | 07:45 |
| ← travis-ci left | 07:45 |
| → wamba joined | 07:48 |
| → piojo_ joined | 07:51 |
| ← piojo left | 07:52 |
|
piojo_
| lemme ask a different question: the *best* way to build, if I'm not lazy, is to set up different directories for each repository and build/install each one separately? | 08:01 |
| ← francesco_ left | 08:02 |
|
piojo_
| Or do developers also use rakudobrew? It can't tell whether it's versatile enough to find the commit that breaks the build, for example | 08:02 |
|
raschipi
| I don't think anyone that builds on windows hangs around on IRC... | 08:04 |
| → domidumont joined | 08:05 |
| → zakharyas joined | 08:06 |
|
raschipi
| piojo_: I think you're the closest thing to a windows expert as there is in Perl6. | 08:07 |
|
El_Che
| stmuk_builds star on windows as well, so he probably knows more about the win build process | 08:11 |
| ← llfourn left | 08:15 |
|
piojo_
| raschipi: haha. Someone must have made perl6 run on windows! | 08:16 |
|
| raschipi: oh, I see. is stackoverflow a better place to go for windows-specific questions? | 08:17 |
| → dogbert2 joined | 08:18 |
|
raschipi
| I have no idea where you'll fing perl6-on-windows users to help you, sorry. | 08:18 |
|
piojo_
| thanks. forget windows, then | 08:19 |
|
| Is the right way to build perl6 to build nqp, moar, and rakudo one at a time? | 08:19 |
|
| and to consider them separate projects which should be debugged (and git-bisected) totally separately? | 08:20 |
|
| El_Che: is stumuk_ the person who makes star releases for win? | 08:22 |
|
| *stmuk_, I mean | 08:22 |
|
tyil
| is there a zef command I can use to make it install all deps from a given META6.json? | 08:29 |
|
zakame
| cd to where the META6.json is then `zef install --deps-only .` | 08:30 |
|
tyil
| thanks :> | 08:30 |
| ← ufobat left | 08:30 |
| ← zakharyas left | 08:33 |
|
Geth
| ¦ doc: c108ce774f | (Zak B. Elep)++ | 2 files | 08:34 |
|
| ¦ doc: Split and rephrase lines in the footer | 08:34 |
|
| ¦ doc: | 08:34 |
|
| ¦ doc: The first paragraph/line was getting too long, so split it a bit and | 08:34 |
|
| ¦ doc: rephrase to emphasize source location and actions to either report | 08:34 |
|
| ¦ doc: issues and/or edit/fork. | 08:34 |
|
| ¦ doc: | 08:34 |
|
| ¦ doc: Fixes #1535. | 08:34 |
|
| ¦ doc: review: https://github.com/perl6/doc/commit/c108ce774f | 08:34 |
|
| ¦ doc: 4cff7ee700 | (Zak B. Elep)++ | lib/Pod/Htmlify.pm6 | 08:34 |
|
| ¦ doc: :lipstick: phrasing for "from POD6 at perl6/doc"... | 08:34 |
|
| ¦ doc: | 08:34 |
|
| ¦ doc: "From POD6 from perl6/doc" sounds odd... | 08:34 |
|
| ¦ doc: review: https://github.com/perl6/doc/commit/4cff7ee700 | 08:34 |
|
| ¦ doc: 3444fe4033 | (Rafael Schipiura)++ (committed using GitHub Web editor) | 2 files | 08:34 |
|
| ¦ doc: Merge pull request #1541 from zakame/split-and-rephrase-lines-in-footer | 08:34 |
|
| ¦ doc: | 08:34 |
|
| ¦ doc: Split and rephrase lines in the footer | 08:34 |
|
| ¦ doc: review: https://github.com/perl6/doc/commit/3444fe4033 | 08:34 |
| ← leont left | 08:36 |
| ← Cabanossi left | 08:38 |
| → Cabanossi joined | 08:41 |
|
stmuk_
| piojo_: yes I build star on Windows every three months, although it's not my main platform of choice | 08:46 |
|
piojo_
| stmuk_: by the way, thank you for that service! | 08:47 |
|
| stmuk_: so if I want to debug build problems, I should work with 3 separate repositories for nqp, moar, and rakudo? | 08:47 |
|
stmuk_
| yes and that applies to all platforms | 08:48 |
| → sumdoc joined | 08:48 |
|
sumdoc
| how to enabe autocompletion in Perl 6 REPL? Any idea? | 08:48 |
|
| Autocompletion | 08:49 |
|
piojo_
| stmuk_: thanks. I assume the READMEs in the code are enough, without a lot of custom setup needed? (I'm not thinking modules, just the core perl6) | 08:50 |
|
stmuk_
| yes | 08:50 |
|
| I use mingw gcc as shipped with strawberry perl or MSVC should also work | 08:51 |
|
raschipi
| sumdoc: You need linenoise. | 08:51 |
|
stmuk_
| at least for 64 bit (I don't think anyone has done a 32 bit build for a while) | 08:51 |
|
raschipi
| https://github.com/hoelzro/p6-linenoise/#tab-completion | 08:51 |
|
piojo_
| stmuk_: thanks, that's what I'm using too. I'll try to get it working, or at least find the bad commit soon | 08:52 |
|
stmuk_
| https://ci.appveyor.com/project/rakudo/rakudo/branch/nom/job/m7e6fwo5hwnug90w suggests the windows build is fine | 08:52 |
|
| piojo_: I'll also try a build very shortly | 08:52 |
|
piojo_
| stmuk_: I think moar is the problem, not rakudo | 08:52 |
| → xtreak joined | 08:53 |
|
sumdoc
| raschipi linenoise or readline !! Which one better? | 08:53 |
|
stmuk_
| yes that's usually the issue | 08:53 |
| ← mr-foobar left | 08:53 |
|
raschipi
| sumdoc: readline doesn't have tab completion. | 08:54 |
|
sumdoc
| raschipi OK lemme build with linenoise | 08:54 |
|
| raschipi what do you say about rlwrap? | 08:55 |
| → mr-foobar joined | 08:55 |
|
raschipi
| I use rlwrap, but it also doesn't have tab completion. | 08:56 |
| ← xtreak left | 08:57 |
|
piojo_
| raschipi: does rlwrap interfere with tab completion, if you use rlwrap+linenoise? | 08:57 |
|
raschipi
| I never tried it. | 08:58 |
|
piojo_
| and can linenoise be configured for <esc><backspace> to delete a whole word like it does with readline? | 08:58 |
|
| eh, I should just read the docs. I'm sure it's answered somewhere | 08:58 |
|
raschipi
| zakame: your code is in effect now, go have a look. | 08:59 |
|
zakame
| thanks raschipi ! | 08:59 |
| → zakharyas joined | 09:01 |
|
sumdoc
| raschipi OK I am going with Linenoise. But what was good about rlwrap than linenoise u r using rlwrap. Just a curiosity!! | 09:06 |
|
raschipi
| I don't install modules. | 09:07 |
| → AlexDaniel joined | 09:07 |
|
sumdoc
| raschipi Thanks | 09:07 |
| armin_ → armin | 09:10 |
| → rindolf joined | 09:12 |
|
raschipi
| Oh oh... | 09:18 |
|
| https://docs.perl6.org/routine.html has a ton of 404 links... | 09:19 |
|
| https://docs.perl6.org/routine/.= for example | 09:20 |
| ← telex left | 09:21 |
| ← Actualeyes left | 09:21 |
| → telex joined | 09:21 |
| ← raschipi left | 09:23 |
| → xtreak joined | 09:26 |
| ← ggoebel left | 09:29 |
|
tyil
| I'm trying to run perl6 on FreeBSD, but I got the error "Missing serialize REPR function for REPR VMException (BOOTException)" | 09:29 |
|
| it runs fine on Funtoo | 09:29 |
| → zakharyas1 joined | 09:31 |
| ← zakharyas left | 09:32 |
| → ggoebel joined | 09:42 |
|
tyil
| also, how would I go about running a perl 6 program as a daemon? | 09:48 |
| ← zakharyas1 left | 09:48 |
| → zakharyas joined | 09:49 |
| → xtreak_ joined | 09:50 |
| → Skarsnik joined | 09:51 |
| ← xtreak left | 09:52 |
| → eroux joined | 09:53 |
|
stmuk_
| tyil: I just built using rakudobrew on FreeBSD 11.1 and it worked fine for me | 09:53 |
| ← mr-foobar left | 09:54 |
|
tyil
| hmm | 09:54 |
|
stmuk_
| maybe you have stuff hanging around from a older build? | 09:54 |
|
tyil
| the program I'm trying to run is https://github.com/scriptkitties/musashi, the command Im using to run it is perl6 -I/home/musashi/musashi/lib /home/musashi/musashi/bin/musashi.pl6 | 09:55 |
|
sumdoc
| Linenoise build is failing in rakudo Any help? | 09:55 |
|
| https://github.com/hoelzro/p6-linenoise/issues/22 | 09:55 |
| ← xtreak_ left | 09:55 |
|
tyil
| no, its a new vm with perl 6 built for the first time last night | 09:55 |
| → mr-foobar joined | 09:55 |
|
tyil
| if it matters, I did not use rakudobrew, but just cloned https://github.com/rakudo/rakudo and ran perl Configure.pl --gen-moar --gen-nqp --backends=moar | 09:56 |
|
sumdoc
| Are there any dependencies for Linenoise? | 09:57 |
|
stmuk_
| sumdoc: just a C compiler | 09:59 |
|
tyil
| stmuk_: if I run the program as a service (https://github.com/scriptkitties/musashi/blob/master/files/musashi.rc), it starts correctly | 10:02 |
|
| but it doesnt run as a background service yet, so that would be my next issue | 10:02 |
| ← rindolf left | 10:04 |
| ← zakharyas left | 10:08 |
| → rindolf joined | 10:09 |
| → dogbert17_ joined | 10:11 |
| ← dogbert17 left | 10:12 |
| ← Voldenet left | 10:12 |
| → margeas joined | 10:12 |
| ← mattp__ left | 10:13 |
| → mattp__ joined | 10:15 |
| → Voldenet joined | 10:17 |
| ← Voldenet left | 10:17 |
| → Voldenet joined | 10:17 |
| ← Cabanossi left | 10:25 |
| → ShalokShalom_ joined | 10:26 |
| → Cabanossi joined | 10:26 |
|
stmuk_
| piojo_: yes I can reproduce the windows build failure "Unhandled exception: Unable to allocate an array of 8 elements" | 10:27 |
| ← ShalokShalom left | 10:29 |
| → NewOne joined | 10:35 |
| ← zakame left | 10:40 |
| ShalokShalom_ → ShalokShalom | 10:41 |
| ← Aaronepower left | 10:42 |
| → HoboWithAShotgun joined | 10:43 |
|
HoboWithAShotgun
| good day you wonderful people. what's the perl 6 way of constraining a class' attribute? | 10:44 |
|
Skarsnik
| has Int $.attribute ? | 10:45 |
|
HoboWithAShotgun
| like i want a "has $.radians" that will only accept values between -pi and + pi | 10:45 |
|
timotimo
| if you want extra constraints, define a subset type and use that there | 10:45 |
|
| m: subset Radians of Real where -pi < * < pi; class A { has Radians $.r }; say try A.new(r => 1); say try A.new(r => 4) | 10:45 |
|
camelia
| rakudo-moar 347da8: OUTPUT: «A.new(r => 1)Nil» | 10:45 |
|
Skarsnik
| fun | 10:46 |
| ← TEttinger left | 10:47 |
|
Juerd
| -pi to +pi? Why not 0 to tau? | 10:47 |
|
timotimo
| actually, any value between -Inf and Inf is a value in radians :P | 10:48 |
| ← sumdoc left | 10:48 |
|
Juerd
| Sure, but if you're limiting, wouldn't it make sense to limit that to 0 <= r < tau? | 10:49 |
|
timotimo
| m: say tau | 10:49 |
|
camelia
| rakudo-moar 347da8: OUTPUT: «6.28318530717959» | 10:49 |
|
piojo_
| stmuk_: thanks. I intend to do a git rebase, but I won't be able to until monday | 10:50 |
| → xtreak joined | 10:51 |
| ← xtreak left | 10:52 |
| ← mr-foobar left | 10:54 |
| ← notbenh left | 10:55 |
| → notbenh joined | 10:56 |
|
HoboWithAShotgun
| ah, my code involves triangles, so only values between 0 and 90° make sense | 10:58 |
|
| 180° sorry | 10:58 |
| → mr-foobar joined | 11:00 |
|
HoboWithAShotgun
| but it works, thanks. at first tests failed, but then i realized <= instead of < | 11:00 |
|
| + i need | 11:00 |
| ← Cabanossi left | 11:09 |
| ← ilbelkyr left | 11:09 |
| → Cabanossi joined | 11:09 |
| → ilbelkyr joined | 11:11 |
| ← mr-foobar left | 11:11 |
| → cog_ joined | 11:15 |
|
HoboWithAShotgun
| allright, i now have this class: https://hastebin.com/kinucobije.pl which allows values between -360 and 360 degrees | 11:16 |
|
| how do i now derive Angle::Triangle from that wich is identical only so it limits between 180 and -180 | 11:17 |
| → mr-foobar joined | 11:18 |
| ← cognominal left | 11:18 |
|
HoboWithAShotgun
| also, can i override the error message that i get when i assign an ivalid value to my subtype? | 11:20 |
|
Skarsnik
| probably with subset again ? | 11:20 |
|
| HoboWithAShotgun goes rtfm | 11:21 |
|
Skarsnik
| m: class A { has $.x}; subset B of A where $.x < 20; say try A.new( a => 30; say try B.new( B => 30); | 11:21 |
|
camelia
| rakudo-moar 347da8: OUTPUT: «=== SORRY!=== Error while compiling <tmp>Variable $.x used where no 'self' is availableat <tmp>:1------> ss A { has $.x}; subset B of A where $.x ⏏ < 20; say try A.new( a => 30; say try B  expecting any of: term» | 11:21 |
|
Skarsnik
| m: class A { has $.x}; subset B of A where $.x < 20; say try A.new( x => 30; say try B.new( x => 30); | 11:21 |
|
camelia
| rakudo-moar 347da8: OUTPUT: «=== SORRY!=== Error while compiling <tmp>Variable $.x used where no 'self' is availableat <tmp>:1------> ss A { has $.x}; subset B of A where $.x ⏏ < 20; say try A.new( x => 30; say try B  expecting any of: term» | 11:21 |
|
timotimo
| https://github.com/zoffixznet/perl6-Subset-Helper | 11:26 |
| ← NewOne left | 11:37 |
| ← Cabanossi left | 11:39 |
| → Cabanossi joined | 11:41 |
|
timotimo
| stmuk_: did you see what i wrote in #moarvm? | 11:48 |
| → mr-fooba_ joined | 11:54 |
| ← mr-foobar left | 11:56 |
|
stmuk_
| timotimo: I have now! | 12:03 |
|
| I have to go out shortly but can quickly look now and slowly look later | 12:04 |
|
timotimo
| OK! | 12:04 |
|
| i hope it'll be enlightening | 12:04 |
| ← AlexDaniel left | 12:05 |
|
[Coke]
| (windows) I have a build I run occasionally. | 12:08 |
|
| updated rakudo, rebuilding... | 12:11 |
|
| (also if you're having a windows build issue, msvc or gcc?) | 12:12 |
| ← eroux left | 12:13 |
| → galx joined | 12:17 |
| ← esh left | 12:19 |
| → esh joined | 12:19 |
| → sumdoc joined | 12:23 |
| ← Cabanossi left | 12:23 |
|
sumdoc
| I have updated the blog. Added about mounting the folder. https://sumdoc.wordpress.com/2017/09/06/how-to-run-perl-6-notebook/ | 12:24 |
|
[Coke]
| I can't duplicate a win64 failure with strawberry perl, msvc, and nom/master/master | 12:25 |
| → Cabanossi joined | 12:26 |
|
galx
| how can I use perl6 on WinXP | 12:27 |
|
| ? | 12:27 |
|
timotimo
| oh, huh, i don't know if anybody has tried that before | 12:28 |
|
| have you tried just building it and seeing where it fails? | 12:29 |
|
galx
| no, but I can try | 12:29 |
|
[Coke]
| ... xp? | 12:29 |
|
galx
| I have an old laptop with winxp installed | 12:30 |
|
| i know it's crazy yeah :) | 12:30 |
|
timotimo
| building rakudo will need more than 1gb of ram | 12:30 |
|
jnthn
| If it's 64-bit then can always try one of the MSIs | 12:30 |
|
timotimo
| huh, i wasn't actually aware that windows xp already came in 64bit variants | 12:31 |
|
| but i guess 64bit processors are not new at all | 12:31 |
|
galx
| it's 32 | 12:32 |
|
[Coke]
| https://github.com/rakudo/rakudo/blob/nom/docs/windows.md might help | 12:32 |
|
galx
| thank you! | 12:32 |
|
[Coke]
| ... you may not have a version of VS2017 you can install; it is possible to build just using strawberry perl's toolchain. | 12:33 |
| ← cgfbee left | 12:33 |
|
jast
| windows xp x64 is fairly rare | 12:33 |
|
timotimo
| we don't require a very new visual studio | 12:33 |
|
[Coke]
| (ugh, also my MD formatting is wonky there, if anyone wants to try to clean that, I'd appreciate it. :| | 12:33 |
|
| timotimo: right, 2017 was just the one available in the demo copy of windows I grabbed. | 12:34 |
| → cgfbee joined | 12:41 |
| ← astj left | 12:50 |
| → astj joined | 12:51 |
| ← astj left | 12:55 |
| → cdg_ joined | 13:01 |
| → okl joined | 13:02 |
| → astj joined | 13:02 |
| ← astj left | 13:07 |
| ← Cabanossi left | 13:09 |
| → Ptolemarch joined | 13:11 |
| → Cabanossi joined | 13:11 |
| ← galx left | 13:12 |
| → AlexDaniel joined | 13:12 |
| → itaipu joined | 13:14 |
| ← okl left | 13:18 |
| → eliasr joined | 13:19 |
| ← AlexDaniel left | 13:26 |
|
sumdoc
| -- | 13:38 |
| → mr-foobar joined | 13:40 |
| ← mr-fooba_ left | 13:41 |
| → radvendii joined | 13:42 |
| ← radvendii left | 14:04 |
| ← Cabanossi left | 14:09 |
| → Cabanossi joined | 14:11 |
| ← wamba left | 14:18 |
| → Kyo91_ joined | 14:22 |
|
sumdoc
| Is there a perl 6 package to work with web API? | 14:35 |
|
moritz
| HTTP::UserAgent | 14:39 |
| ← Cabanossi left | 14:40 |
| → Cabanossi joined | 14:41 |
|
| moritz back from vacation | 14:42 |
| ← lowbro_ left | 14:48 |
| ← cdg_ left | 14:52 |
| → cdg joined | 14:52 |
| ← cdg left | 14:57 |
| → cdg_ joined | 14:57 |
| → itaipu_ joined | 15:01 |
|
timotimo
| also WWW and the curl bindings | 15:02 |
| ← itaipu left | 15:04 |
|
b2gills
| .ask TimToady I would like your input on a document for implementors of Perl 6 dialects since there are currently 2 that I know of https://gist.github.com/b2gills/7e2781dfd781368b63337c59bd751115 | 15:05 |
|
yoleaux
| b2gills: I'll pass your message to TimToady. | 15:05 |
| → setty1 joined | 15:05 |
| → donaldh joined | 15:05 |
| ← domidumont left | 15:06 |
| ← itaipu_ left | 15:08 |
| → itaipu joined | 15:08 |
| ← donaldh left | 15:09 |
| ← Cabanossi left | 15:09 |
| kubrat_ → kubrat | 15:10 |
| → Cabanossi joined | 15:11 |
| → itaipu_ joined | 15:22 |
| ← geekosaur left | 15:23 |
| ← itaipu left | 15:25 |
| → geekosaur joined | 15:31 |
| ← cdg_ left | 15:32 |
| → cdg joined | 15:33 |
| ← cdg left | 15:37 |
| → mr-fooba_ joined | 15:40 |
| ← Cabanossi left | 15:40 |
|
HoboWithAShotgun
| I managed to create a Num variable that contains 10 which is not equal to 10 | 15:40 |
| → Cabanossi joined | 15:41 |
| ← jeek left | 15:41 |
|
timotimo
| cool, what's your num - 10? | 15:41 |
| ← mr-foobar left | 15:42 |
|
HoboWithAShotgun
| 1.77635683940025e-15 | 15:47 |
|
| but then why does it print as 10? | 15:47 |
|
| p6: my $l = sqrt(2) * 10; my $d = 45; my $r = $d / 360 * tau; my $y = sin( $r ) * $l; my $x = sqrt( $l**2 - $y**2 ); say $x == $y; | 15:48 |
|
camelia
| rakudo-moar e5a600: OUTPUT: «False» | 15:48 |
|
HoboWithAShotgun
| the trig functions and tau probably produce rounding errors | 15:49 |
|
| p6: my $l = sqrt(2) * 10; my $d = 45; my $r = $d / 360 * tau; my $y = sin( $r ) * $l; my $x = sqrt( $l**2 - $y**2 ); say $x; say $y; | 15:53 |
|
camelia
| rakudo-moar e5a600: OUTPUT: «1010» | 15:53 |
|
tbrowder
| .tell nine I just filed issue #101 with Inline::Perl5; failure using Expect::Simple | 15:53 |
|
yoleaux
| tbrowder: I'll pass your message to nine. | 15:53 |
|
HoboWithAShotgun
| see? outputs as 10 even though x is 10.00000000...whatver | 15:53 |
|
| half an hour wasted | 15:54 |
| → pyrimidine joined | 15:55 |
| → cdg joined | 15:57 |
| ← cdg left | 15:58 |
| → cdg joined | 15:58 |
|
HoboWithAShotgun
| .tell mum I gonna be late for dinner | 15:58 |
|
yoleaux
| HoboWithAShotgun: I'll pass your message to mum. | 15:58 |
| → piojo2 joined | 16:00 |
| ← cdg left | 16:02 |
| → mr-foobar joined | 16:04 |
| → skids joined | 16:07 |
| ← kaare_ left | 16:08 |
| ← mr-fooba_ left | 16:08 |
| → kaare_ joined | 16:08 |
| ← Cabanossi left | 16:10 |
| → Cabanossi joined | 16:11 |
| ← HoboWithAShotgun left | 16:13 |
| ← kaare_ left | 16:16 |
| → cdg joined | 16:16 |
| → cdg_ joined | 16:18 |
| ← cdg left | 16:18 |
| ← cdg_ left | 16:18 |
| → cdg joined | 16:18 |
| ← sumdoc left | 16:20 |
| ← cdg left | 16:20 |
| → astj joined | 16:27 |
| ← itaipu_ left | 16:28 |
| ← astj left | 16:32 |
|
ilmari
| tbrowder: works for me | 16:33 |
|
| This is Rakudo version 2017.08-79-g4b02b8aad built on MoarVM version 2017.08.1-110-gab28683b2 | 16:34 |
| → kerframil joined | 16:34 |
| → cdg joined | 16:36 |
|
ilmari
| how do you get the version of a loaded module in perl6? like perl5's Foo->VERSION or $Foo::VERSION? | 16:38 |
|
ugexe
| in perl6 its just $*REPO.need(CompUnit::DependencySpecification.new(:short-name<Foo>)).distribution.meta<ver> | 16:39 |
|
Skarsnik
| 'just' | 16:41 |
|
ilmari
| ah, so intuitive | 16:41 |
|
| very discoverable | 16:41 |
|
moritz
| we might want a shortcut for that :-) | 16:41 |
|
ugexe
| also it only works for ::Installable repos, ::FileSystem ones dont set a CompUnit.distribution | 16:42 |
|
| https://github.com/rakudo/rakudo/pull/1132 would allow it to work with ::FileSystem however. | 16:43 |
|
| the short-cut would be to somehow hook up META6.json info to ::Foo.^ver | 16:44 |
|
ilmari
| huh, doesn't perl6's -M take an import list? | 16:46 |
|
ugexe
| i dont think our -M does anything but take the short name | 16:47 |
|
| e.g. `-M "Test:ver<6.c>"` does not work while `-e 'use Test:ver<6.c>` does | 16:49 |
|
| ilmari wanted to write a V module like perl5 has | 16:49 |
|
ilmari
| perl5 -MV=Foo # shows all versions of Foo in @INC | 16:49 |
|
ugexe
| all versions of Foo in @INC doesn't mean the same thing as in perl6 though | 16:51 |
|
ilmari
| all versions in $*REPO.repo-chain? | 16:53 |
|
ugexe
| let me rephrase: it wouldnt suffice for determining which version of something will get used | 16:54 |
|
| i guess thats the same as @INC though with use lib, so nm | 16:55 |
| → zakharyas joined | 16:56 |
|
ingy
| I just noticed that: perl6 -e 'say "ok" while True' | head | 16:57 |
|
| doesn't terminate like perl5 does | 16:58 |
|
ilmari
| Unhandled exception: Failed to write bytes to filehandle: Broken pipe | 16:58 |
|
| but exit status zero?! | 17:00 |
|
ingy
| that's bash | 17:00 |
|
| the exit code of head | 17:00 |
|
ilmari
| doh | 17:00 |
|
ugexe
| m: say $*REPO.repo-chain.map(*.?installed()).grep(*.defined).map(*.Slip).grep({ .meta<name> eq "Test" || (.meta<provides>{"Test"}:exists) }).map(*.meta<ver version>.first); # this is the logic part anyway | 17:00 |
|
camelia
| rakudo-moar e5a600: OUTPUT: «(v6.c)» | 17:00 |
|
ingy
| I don't get the broken pipe | 17:01 |
|
| it just hangs | 17:01 |
|
ilmari
| yes, with set -o pipefail (not popefail, as I first typed) it shows exit status 1 from perl6 | 17:01 |
|
| which version? | 17:01 |
|
| This is Rakudo version 2017.08-79-g4b02b8aad built on MoarVM version 2017.08.1-110-gab28683b2 | 17:01 |
|
ingy
| python -c 'while True:print("ok")' | head # gives a broken pipe | 17:01 |
|
| yes | head # seems like nice behaviour | 17:02 |
|
| This is Rakudo version 2017.04.3 built on MoarVM version 2017.04-53-g66c6dda | 17:02 |
|
| on mac | 17:02 |
|
ilmari
| perl5 exits with status 141 but no message | 17:02 |
|
ingy
| so does `yes` ! | 17:03 |
|
| 141 | 17:03 |
|
| that's a 13 | 17:03 |
|
| 141 - 128 | 17:03 |
|
ilmari
| which is SIGPIPE | 17:04 |
|
| but now, pubtime! | 17:04 |
| ← pyrimidine left | 17:04 |
| ← TimToady left | 17:05 |
|
ingy
| so that's probably what perl6 should do | 17:05 |
|
| if anyone cares | 17:05 |
| → pyrimidine joined | 17:05 |
| → TimToady joined | 17:07 |
| ← Cabanossi left | 17:08 |
| → Cabanossi joined | 17:11 |
| → domidumont joined | 17:18 |
| → bdmatatu joined | 17:35 |
| → espadrine joined | 17:36 |
| ← Cabanossi left | 17:38 |
| → Cabanossi joined | 17:41 |
| ← piojo2 left | 17:44 |
| ← jonas1 left | 17:48 |
| ← pyrimidine left | 17:51 |
| → pyrimidine joined | 17:55 |
| → pmurias joined | 17:58 |
| ← zakharyas left | 17:58 |
| → pyrimidi_ joined | 17:59 |
| ← pyrimidine left | 17:59 |
| ← pyrimidi_ left | 18:03 |
| → pyrimidine joined | 18:04 |
| ← pyrimidine left | 18:08 |
| ← Cabanossi left | 18:10 |
| → Cabanossi joined | 18:11 |
| → pyrimidine joined | 18:12 |
| → astj joined | 18:12 |
| ← mr-foobar left | 18:16 |
| ← pyrimidine left | 18:16 |
| ← astj left | 18:17 |
| → mr-foobar joined | 18:20 |
| → pyrimidine joined | 18:20 |
| ← pyrimidine left | 18:25 |
|
BooK
| I'm testing radical changes to Bool by taking all concerned lines from src/Perl6/Metamodel/BOOTSTRAP.nqp and in src/core/Bool.pm and s/Bool/Foo/ to test them faster, and in isolation, without needing to recompile between attempts | 18:25 |
|
| is that something that could work? | 18:25 |
|
| Right now, I get: Type 'stub' is not declared. Did you mean 'Sub'? | 18:26 |
|
| so I assume I need to load some definition for stub | 18:26 |
|
jnthn
| For code in CORE.setting it's often a fine approach | 18:26 |
|
| For something that is so bootstrap-sensitive, there's a very high chance of things not working when put back later | 18:26 |
|
| `stub` is actually a non-standard language extension only in NQP, for the sake of the bootstrap. It doesn't exist in real Perl 6. | 18:27 |
|
| So that bit can't really be copied out, but you could simulate it with a stub class in full Perl 6 | 18:27 |
|
| my class Foo { ... } | 18:27 |
| → cdg_ joined | 18:27 |
|
BooK
| ok | 18:28 |
|
| the line I was replacing was: my stub Bool metaclass Perl6::Metamodel::EnumHOW { ... }; | 18:29 |
|
| so just dropping the stub would do it | 18:30 |
| ← cdg left | 18:31 |
| ← cdg_ left | 18:32 |
| ← notbenh left | 18:32 |
|
cono
| is there any way to define alternation in regexp with backtracking ? | 18:36 |
|
yoleaux
| 6 Sep 2017 12:43Z <Zoffix> cono: the latest and greatest Rakudo has a fix for your issue. You should be getting your Any again: https://github.com/rakudo/rakudo/commit/d0d105b8b6 | 18:36 |
|
cono
| already seen this, thanks :) | 18:37 |
| ← pecastro left | 18:37 |
|
cono
| https://gist.github.com/cono/30bd6392856626771c747ddaa29471b0 so, I want if <number> fails it backtrack and tries <tree-op> token | 18:38 |
|
| | - longest, || - left associated, I want some "\\" which going to be left associated but with backtracking, so if first token in alternation fails, it tries next one | 18:41 |
| → kaare_ joined | 18:42 |
|
cono
| in this case: 1 + 2 + 3, will be something like expr( tree-op(tree-op(number(1), op('+'), number(2)), op('+'), number(3)) ) | 18:44 |
| → ash_gti joined | 18:48 |
| → andrzejku joined | 18:49 |
| → pecastro joined | 18:50 |
|
jnthn
| cono: Are you writing this in a token/rule? | 18:51 |
|
| ah, you linked code and I missed it :) | 18:51 |
|
Geth
| ¦ doc/molecules-patch-2: 65cf7b1d1b | (Christopher Bottoms)++ (committed using GitHub Web editor) | doc/Type/IO/Socket/Async.pod6 | 18:51 |
|
| ¦ doc/molecules-patch-2: Fixed three space indent | 18:51 |
|
| ¦ doc/molecules-patch-2: review: https://github.com/perl6/doc/commit/65cf7b1d1b | 18:51 |
|
BooK
| how can I initialize a sigilless version of Bool to do the equivalent of the stub in npq? I think my \Bool2 := ...; and then I can call the stuff found in bootstrap on that new name, the first of which would be Bool2.HOW.set_base_type(BooK, Int); | 18:53 |
| → Aaronepower joined | 18:53 |
| ← kaare_ left | 18:54 |
|
BooK
| etc | 18:54 |
| → kaare_ joined | 18:54 |
|
BooK
| I want to first build a Bool2 identical to the regular Bool, and then tweak it so that it can do the Enumeration role, and we can remove the duplication | 18:54 |
|
jnthn
| BooK: Probably something like Metamodel::EnumHOW.new_type(:name('Bool2')) | 18:55 |
|
| cono: The thing is that token (and rule) mean that backtracking state should *not* be retained | 18:55 |
|
| cono: || if a regex will indeed backtrack | 18:55 |
|
| cono: If you replace token with regex in the first 3 rules it seems to work out | 18:55 |
|
moritz
| or maybe my \Bool2 = Bool but Enumeration; | 18:56 |
|
Geth
| ¦ doc: d15be280c7 | (Christopher Bottoms)++ (committed using GitHub Web editor) | doc/Type/IO/Socket/Async.pod6 | 18:56 |
|
| ¦ doc: Does this resolve #1538? | 18:56 |
|
| ¦ doc: | 18:56 |
|
| ¦ doc: Does simply removing the `if` statement resolve #1538? | 18:56 |
|
| ¦ doc: review: https://github.com/perl6/doc/commit/d15be280c7 | 18:56 |
|
| ¦ doc: 65cf7b1d1b | (Christopher Bottoms)++ (committed using GitHub Web editor) | doc/Type/IO/Socket/Async.pod6 | 18:56 |
|
| ¦ doc: Fixed three space indent | 18:56 |
|
| ¦ doc: review: https://github.com/perl6/doc/commit/65cf7b1d1b | 18:56 |
|
| ¦ doc: c0596fe916 | (Jonathan Worthington)++ (committed using GitHub Web editor) | doc/Type/IO/Socket/Async.pod6 | 18:56 |
|
| ¦ doc: Merge pull request #1540 from perl6/molecules-patch-2 | 18:56 |
|
| ¦ doc: | 18:57 |
|
| ¦ doc: Does this resolve #1538? | 18:57 |
|
| ¦ doc: review: https://github.com/perl6/doc/commit/c0596fe916 | 18:57 |
|
BooK
| moritz: the plan is to test writing a different implementation of Bool, without having to recompile every time I change a thing | 18:57 |
|
| so writing Bool2 without depending on Bool explicitely, just copy-pasting | 18:57 |
|
| jnthn bbl | 18:58 |
| ← skids left | 19:00 |
|
BooK
| m: BEGIN { use nqp; my \Bool2 := Metamodel::EnumHOW.new_type(:name<Bool2>, :base_type(Int)); Bool2.HOW.set_base_type(Bool2, Int); } | 19:00 |
|
camelia
| rakudo-moar e5a600: OUTPUT: «=== SORRY!=== Error while compiling <tmp>An exception occurred while evaluating a BEGINat <tmp>:1Exception details: === SORRY!=== Error while compiling  Base type has already been set for Bool2 at :» | 19:00 |
|
cono
| jnthn: thanks! :) | 19:01 |
|
BooK
| m: BEGIN { use nqp; my \Bool2 := Metamodel::EnumHOW.new_type(:name<Bool2>); Bool2.HOW.set_base_type(Bool2, Int); } | 19:02 |
|
camelia
| rakudo-moar e5a600: ( no output ) | 19:02 |
|
BooK
| mmm | 19:02 |
|
| I think that failed later | 19:03 |
| → astj joined | 19:04 |
| → Actualeyes joined | 19:05 |
| ← domidumont left | 19:05 |
| → smls joined | 19:06 |
| ← darutoko left | 19:06 |
| ← astj left | 19:08 |
|
BooK
| right, it gave me: getstaticcode requires a static coderef | 19:09 |
| → grqung joined | 19:09 |
|
BooK
| I guess I'm now deep in the guts, and my only operation tool knowledge relates to a spoon | 19:10 |
| ← perlpilot left | 19:10 |
| → skids joined | 19:11 |
|
moritz
| if you install methods with add_method or so, you might needs to wrap the code in nqp::getstaticcode() | 19:11 |
| → pmurias_ joined | 19:13 |
| → lancew joined | 19:15 |
|
BooK
| moritz: the error comes from this line: Bool2.HOW.add_method(Bool2, 'key', nqp::getstaticcode(sub ($self) { nqp::getattr_s(nqp::decont($self), Bool2, '$!key'); })); | 19:19 |
|
tbrowder
| ilmari: my bad, my Inline::Perl5 was too old--an upgrade fixed it. I think I'll add a cron job to upgrade all modules every week or so... | 19:19 |
|
BooK
| so I guess the question is "how do I make that sub a static coderef? | 19:19 |
|
tbrowder
| .tell nine my version was too old, closing issue 101 | 19:19 |
|
yoleaux
| tbrowder: I'll pass your message to nine. | 19:19 |
|
BooK
| (going to lose network soon, the plane is about to take off) | 19:21 |
|
moritz
| BooK: looks good to me, assuming that $!key is set up correctly first | 19:24 |
| ← lancew left | 19:27 |
| → lancew joined | 19:27 |
| → notbenh joined | 19:29 |
| → pyrimidine joined | 19:31 |
| → zakharyas joined | 19:31 |
| ← Cabanossi left | 19:38 |
| ← pyrimidine left | 19:38 |
| ← jcallen left | 19:38 |
| → pyrimidine joined | 19:39 |
| ← lancew left | 19:40 |
| → Cabanossi joined | 19:41 |
| → jcallen joined | 19:41 |
| ← Cabanossi left | 19:47 |
| → Cabanossi joined | 19:48 |
| ← eliasr left | 19:49 |
| ← ash_gti left | 19:49 |
| ← zakharyas left | 19:50 |
| → domidumont joined | 19:50 |
| → astj joined | 19:55 |
| ← nightfrog left | 19:58 |
| ← astj left | 19:59 |
| ← kerframil left | 20:03 |
|
moritz
| how do I access the actions object inside a grammar? | 20:03 |
| → Semp__ joined | 20:05 |
| → itaipu joined | 20:06 |
| ← domidumont left | 20:09 |
| ← Semp__ left | 20:11 |
| ← Kyo91_ left | 20:12 |
| → perlpilot joined | 20:13 |
|
moritz
| ah, self.actions | 20:13 |
|
Geth
| ¦ doc: 9826038dd1 | (Moritz Lenz)++ | doc/Type/Cursor.pod6 | 20:17 |
|
| ¦ doc: Document Cursor.actions | 20:17 |
|
| ¦ doc: review: https://github.com/perl6/doc/commit/9826038dd1 | 20:17 |
| ← andrzejku left | 20:21 |
| → kerframil joined | 20:22 |
|
Geth
| ¦ doc: c65e01f3a8 | (Moritz Lenz)++ | doc/Type/Match.pod6 | 20:24 |
|
| ¦ doc: Document Match.actions | 20:24 |
|
| ¦ doc: review: https://github.com/perl6/doc/commit/c65e01f3a8 | 20:24 |
|
moritz
| book-driven development | 20:24 |
| ← Cabanossi left | 20:24 |
| → TEttinger joined | 20:25 |
| → Cabanossi joined | 20:26 |
| ← itaipu left | 20:35 |
| ← ShalokShalom left | 20:44 |
| ← bdmatatu left | 20:44 |
| ← smls left | 20:45 |
| → astj joined | 20:46 |
| ← Cabanossi left | 20:48 |
| → Cabanossi joined | 20:49 |
| ← astj left | 20:50 |
| ← kerframil left | 20:52 |
|
BooK
| while in the plane I played around with IO::Socket::INET, and got this strange behaviour | 20:55 |
|
| This code: say "Accepted {IO::Socket::INET.new(:localhost<localhost>, :localport(4444), :listen).accept}"; | 20:55 |
|
| does what's expected when running `telnet localhost 4444`, but hangs with `nc localhost 4444` | 20:56 |
|
Skarsnik
| does localhost is ipv6? | 20:56 |
|
BooK
| more importantly, nc dies this: localhost [127.0.0.1] 4444 (?) : Connection refused | 20:56 |
|
| the default for INET is ipv4 | 20:57 |
|
Skarsnik
| connect does not pass the Inet family for example | 20:57 |
|
| I would not be surprised listen does not the then xD | 20:58 |
| ← setty1 left | 20:59 |
|
Skarsnik
| yep it's ignored | 21:00 |
|
ugexe
| :localhost<127.0.0.1> | 21:01 |
|
BooK
| Skarsnik: so telnet is doing ipv6 and nc ipv4 ? and perl6 defaults to ipv6 ? | 21:01 |
|
Skarsnik
| moar does not use the sa-family from Rakudo at all | 21:01 |
|
| BooK, moar will get what is the first sa family the system return for localhost | 21:02 |
| → itaipu joined | 21:02 |
|
geekosaur
| actually that would be a bit odd because telnet6 is not quite the same protocol | 21:02 |
|
Skarsnik
| for me it's ipv6 | 21:02 |
|
geekosaur
| hm, looks like linux's does merge them these days though | 21:03 |
|
| so you'd want to verify with: telnet -4 ... | 21:03 |
| ← skids left | 21:04 |
|
Skarsnik
| not sure if that should be fixed or just documented x) | 21:04 |
|
BooK
| you're saying that the socket new gets the famiky from the name rsolution? | 21:06 |
|
Skarsnik
| yes | 21:06 |
|
| https://github.com/MoarVM/MoarVM/blob/master/src/io/syncsocket.c#L302 and https://github.com/MoarVM/MoarVM/blob/master/src/io/syncsocket.c#L270 | 21:07 |
|
BooK
| so even if I passed an explicit family it would overriden by the one from the resolution | 21:07 |
|
Skarsnik
| yes, since it's never used | 21:08 |
| → Kyo91_ joined | 21:08 |
|
BooK
| well if name resolution returns several candidates, it could look at the family and pick | 21:08 |
|
Skarsnik
| I think IO::Socket::INET is not really the focus but more IO::Socket::Async | 21:08 |
|
BooK
| I think it should be vonsidered a bug and will try to write it up | 21:10 |
|
Skarsnik
| I could patch up since I already added stuff in that (to add source address and source port in connect) | 21:11 |
| → galx joined | 21:12 |
| ← Kyo91_ left | 21:14 |
| ← rindolf left | 21:15 |
|
galx
| m: | 21:23 |
|
| I have a problem | 21:25 |
|
| https://pastebin.com/vMvRFr8M | 21:25 |
|
| I want `a` token to match "abc def" and `b` token to match "etc." | 21:26 |
|
| but it fails anyway | 21:26 |
|
| how to do that correctly? | 21:26 |
| ← itaipu left | 21:31 |
| ← dogbert2 left | 21:37 |
| → Danishman joined | 21:41 |
| ← Cabanossi left | 21:42 |
| → AlexDaniel joined | 21:43 |
|
BooK
| Skarsnik: reading your links now | 21:44 |
|
| oh so it's in MoarVM? | 21:45 |
| → Cabanossi joined | 21:45 |
| → okl joined | 21:46 |
|
BooK
| where is the link between rakudo and moarvm done? nqp? | 21:46 |
|
Skarsnik
| probably rakudo/core/io/Socket/INET.pm6 ? | 21:48 |
|
| there is no nqp side for connect | 21:48 |
|
MasterDuke
| BooK: generally yes, nqp:: ops are implemented by moarvm | 21:49 |
|
cono
| m: grammar Grammar { regex TOP { ^^ <a> <ws> <b> $$ }; regex a { <word>+ % <ws> }; token word { <alpha>+ }; regex b { <alpha>+ "." }; }; Grammar.parse("abc def etc.").say | 21:49 |
|
camelia
| rakudo-moar 591b93: OUTPUT: «「abc def etc.」 a => 「abc def」 word => 「abc」 alpha => 「a」 alpha => 「b」 alpha => 「c」 ws => 「 」 word => 「def」 alpha => 「d」 alpha => 「e」 alpha => 「f」 ws => 「 」…» | 21:49 |
|
cono
| galx: ^^ | 21:49 |
|
Skarsnik
| buggable, find listen | 21:50 |
|
cono
| by doing <alpha>+ % "something> you are asking to make <alpha> "something" <alpha> "something" up to infinity | 21:50 |
|
Skarsnik
| don't remember wich bot allow to grep in the code x) | 21:50 |
|
BooK
| right, https://github.com/rakudo/rakudo/blob/nom/src/core/IO/Socket/INET.pm#L122 and https://github.com/rakudo/rakudo/blob/nom/src/core/IO/Socket/INET.pm#L132 | 21:50 |
|
| so in there, there is a default of PIO::PF_INET i.e. IPv4 | 21:52 |
|
cono
| and rule also should be changed to regex, to make backtracking mechanism possible | 21:52 |
|
MasterDuke
| Skarsnik: greppable6 searches all the ecosystem modules | 21:52 |
|
BooK
| but the name resolution is not done there | 21:52 |
|
Skarsnik
| yeah and moar does not get this info | 21:52 |
|
BooK
| note sure what $PIO is here: https://github.com/rakudo/rakudo/blob/nom/src/core/IO/Socket/INET.pm#L117 | 21:52 |
|
MasterDuke
| s: IO::Socket::INET.new, 'listen' | 21:52 |
|
SourceBaby
| MasterDuke, Something's wrong: ERR: Type check failed in binding to parameter '&code'; expected Callable but got Nil (Nil) in sub do-sourcery at /home/zoffix/services/lib/CoreHackers-Sourcery/lib/CoreHackers/Sourcery.pm6 (CoreHackers::Sourcery) line 42 in sub sourcery at /home/zoffix/services/lib/CoreHackers-Sourcery/lib/CoreHackers/Sourcery.pm6 (CoreHackers::Sourcery) line 33 in block <unit> at -e line 6 | 21:52 |
|
BooK
| s: IO::Socket::INET.new, :listen # I think | 21:53 |
|
SourceBaby
| BooK, Something's wrong: ERR: ===SORRY!=== Error while compiling -eUnable to parse expression in argument list; couldn't find final ')'at -e:7------> <BOL><HERE><EOL> | 21:53 |
|
BooK
| s: IO::Socket::INET.new( :listen ) # better | 21:53 |
|
SourceBaby
| BooK, Something's wrong: ERR: ===SORRY!=== Error while compiling -eUnable to parse expression in argument list; couldn't find final ')'at -e:7------> <BOL><HERE><EOL> | 21:54 |
|
MasterDuke
| s: IO::Socket::INET.new, \(:listen) | 21:54 |
|
SourceBaby
| MasterDuke, Something's wrong: ERR: Earlier failures: Nothing given for new socket to connect or bind to. Invalid arguments to .new? in block <unit> at -e line 6Final error: Cannot resolve caller sourcery(Failure, Capture); none of these signatures match: ($thing, Str:D $method, Capture $c) ($thing, Str:D $method) (&code) (&code, Capture $c) in block <unit> at -e line 6 | 21:54 |
|
BooK
| anyways | 21:54 |
| → Kyo91_ joined | 21:54 |
| ← galx left | 21:56 |
|
BooK
| https://github.com/perl6/nqp/blob/master/src/vm/moar/QAST/QASTOperationsMAST.nqp#L2047 # this is where the link is made, right? | 21:58 |
| ← Exodist left | 21:58 |
| ← Cabanossi left | 21:58 |
| → Exodist joined | 21:59 |
| → Cabanossi joined | 21:59 |
| ← Kyo91_ left | 21:59 |
|
BooK
| Skarsnik: https://github.com/MoarVM/MoarVM/blob/master/src/io/syncsocket.c#L231-L233 # this look interesting | 22:01 |
|
perlpilot
| cono: I dunno ... using token like that is a good habit to get into. It's only the `a` rule that really needs backtracking. | 22:01 |
|
cono
| BooK: you can look to my series of ticket to add get_port op: https://github.com/MoarVM/MoarVM/pull/602, there is a cross links between moar nqp and rakudo | 22:01 |
|
| perlpilot: a and TOP | 22:02 |
|
| b should token, agree | 22:03 |
|
| should be* | 22:03 |
|
Skarsnik
| BooK, na it's just to tell you the returned type for this function is not good if you get a ipv6 stuff, but it kinda work since the 2 struct for ipv4/ip6 start the same | 22:04 |
|
| anyways, time for bed ^^ | 22:05 |
|
perlpilot
| m: grammar G { rule TOP { <a> <b> }; regex a { <word>+ % <.ws> }; token b { <word> \. }; token word { <.alpha>+ }; }; say G.parse("abc def etc."); | 22:05 |
|
camelia
| rakudo-moar 591b93: OUTPUT: «「abc def etc.」 a => 「abc def」 word => 「abc」 word => 「def」 b => 「etc.」 word => 「etc」» | 22:05 |
| ← pyrimidine left | 22:05 |
| ← Skarsnik left | 22:05 |
|
BooK
| cono: well, I'm not wanting to add a new op, just fix this one | 22:06 |
| → pyrimidine joined | 22:06 |
|
cono
| perlpilot: heh, thanks. works indeed | 22:07 |
|
BooK
| well, I disagree with Skarsnik: MVM_io_resolve_host_name is what returns the socket to be used, and if the Perl6 IO::Socket::INET gave a family, that should be a hint on which to pick when there's a choice | 22:08 |
|
| https://github.com/MoarVM/MoarVM/blob/master/src/io/syncsocket.c#L242 # result here is a linked list | 22:09 |
|
| but moar just picks the first item in the list | 22:09 |
| ← espadrine left | 22:09 |
|
BooK
| I'd say that family should be passed, and the first item in the list that match the family spec is return | 22:10 |
|
| and still the first is no family is given | 22:10 |
| → cdg joined | 22:10 |
|
BooK
| do I make sense ? | 22:10 |
|
| struct addrinfo has this as its last item: struct addrinfo *ai_next; | 22:12 |
|
| "The items in the linked list are linked by the ai_next field." | 22:12 |
|
| luckily, MVM_io_resolve_host_name is not used it too many places | 22:13 |
| ← cdg left | 22:15 |
| ← pmurias_ left | 22:15 |
| ← pmurias left | 22:15 |
| ← shadowpaste left | 22:19 |
| ← okl left | 22:19 |
| → dogbert2 joined | 22:22 |
| → shadowpaste joined | 22:24 |
| → wamba joined | 22:40 |
| → astj joined | 22:44 |
| ← astj left | 22:49 |
| → Sgeo joined | 22:59 |
| ← Danishman left | 23:04 |
| → cdg joined | 23:10 |
| → raschipi joined | 23:13 |
| ← cdg left | 23:15 |
| → BenGoldberg joined | 23:15 |
|
BooK
| writing a moarvm bug report for the issue | 23:18 |
|
| the problem is that it requires a signature change, I think | 23:18 |
|
| https://github.com/MoarVM/MoarVM/issues/683 # I hope this makes sense | 23:24 |
|
raschipi
| BooK: Makes sense, but can't it be solved by having a multi? If one uses the old call, and if they send the list they would ge the new one? | 23:28 |
| → cdg joined | 23:28 |
|
BooK
| raschipi: in which language? nqp? | 23:29 |
|
| rakudo should definitely use the new call, because it's supposed to ask for a specific family | 23:30 |
|
| I understand changing the signature of MVM_io_resolve_host_name creates some compatibility problems, but I'm not versed enough in C or MoarVM to propose a good solution to that | 23:31 |
| ← cdg left | 23:33 |
|
BooK
| https://design.perl6.org/S32/IO.html#IO%3A%3ASocket%3A%3AINET # I see this was not the most fleshed out part of the design docs | 23:37 |
|
raschipi
| I have to mention there's a RIGTH THING™ to do when picking an AF_INET family to communicate: happy eyebals, RFC 6555 | 23:41 |
| ← geekosaur left | 23:49 |
| → Lac joined | 23:56 |
| ← grqung left | 23:57 |
| → geekosaur joined | 23:59 |