»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_log/perl6 | UTF-8 is our friend! 🦋 Set by Zoffix on 25 July 2018. |
|||
00:00
p6bannerbot sets mode: +v w_richard_w
00:01
nadim left
|
|||
timotimo | ohai jmaslak | 00:04 | |
00:08
theorbtwo7 joined,
theorbtwo7 left
|
|||
ryn1x | jmaslak: That worked! It was so easy... all I did was wrap the whole section of function in .cpp and .h with: extern "C" { } | 00:09 | |
nm now shows the name are not mangled too: 0000000000002d10 T TinyTIFFReader_open | 00:10 | ||
and the perl6 test passes with the unmangled symbol =) | |||
00:12
w_richard_w left
00:14
sno joined
00:15
p6bannerbot sets mode: +v sno
00:17
dct left
|
|||
jmaslak | Awesome, glad to help! | 00:17 | |
00:20
sno left
|
|||
ryn1x | hmm... not working for overloaded functions though... might just need to rename those | 00:25 | |
jmaslak | Yes, overloads will be one of the limitations - you might make an extern C version of those that calls the overloaded ones. That should work. | 00:26 | |
timotimo | overloads are at least one part of the reason that name mangling exists; that's how i think of it anyway | 00:32 | |
00:33
mowcat left
00:34
thundergnat left,
mowcat joined
00:35
p6bannerbot sets mode: +v mowcat
00:37
mowcat left,
mowcat joined
00:38
mowcat left
00:41
mowcat joined
00:42
p6bannerbot sets mode: +v mowcat
00:47
graphene left
00:49
graphene joined
00:50
p6bannerbot sets mode: +v graphene
00:51
mahdouch87 joined
00:52
p6bannerbot sets mode: +v mahdouch87
00:53
mahdouch87 left
00:58
sno joined,
p6bannerbot sets mode: +v sno
01:03
sno left,
molaf left
01:20
daotoad left
01:22
kktt joined
01:23
p6bannerbot sets mode: +v kktt
|
|||
kktt | Is there any IDE could be use on linux | 01:23 | |
01:23
JackFly26 joined,
p6bannerbot sets mode: +v JackFly26
|
|||
JackFly26 | hi | 01:24 | |
kktt | hi | ||
JackFly26 | im trying to make a language parser with grammars | ||
not working out | 01:25 | ||
kktt | oh , i couldn't help u. i am a newbie. I am finding a IDE here. | 01:26 | |
lookatme_q | kktt, maybe try ATOM/VSCODE | 01:27 | |
JackFly26 | oh | ||
i use vs code | |||
lookatme_q | or Emacs/Vim | ||
kktt | linux? | ||
JackFly26 | i apologize in advance | ||
kktt | ok. i will try vim. | ||
JackFly26 | my cat is near my pc | ||
01:27
lizmat left
|
|||
lookatme_q | It's all have plugin for Perl 6 | 01:27 | |
:) | 01:28 | ||
kktt | ok. thank u .dear lookatme_q | ||
lookatme_q | welcome | ||
JackFly26 | how would i share code | ||
kktt | do you use vim? | ||
JackFly26 | | ||
^W | 01:29 | ||
oops | |||
kktt | you cat... | 01:30 | |
JackFly26 | no that was me | 01:31 | |
round with unicode | |||
01:33
lucasb left
|
|||
JackFly26 | how should i send code on this | 01:34 | |
kktt | on irc? | 01:35 | |
JackFly26 | yes | 01:39 | |
kktt | I think you could use the <pastebin.com/> | ||
JackFly26 | ok | ||
01:40
JackFly26 left
01:41
jackfly26__ joined,
p6bannerbot sets mode: +v jackfly26__
01:42
JackFy26 joined,
p6bannerbot sets mode: +v JackFy26
01:43
JackFy26 left
01:44
jackfly26__ left,
jackfly26 joined
01:45
jackfly26 left,
jackfly26 joined
|
|||
ryn1x | What do I do for a c signature like this: (TinyTIFFFile* tiff, double* data) Is it: ( Pointer, num64 is rw ) ? | 01:51 | |
01:52
JackFly26_ joined,
p6bannerbot sets mode: +v JackFly26_,
JackFly26_ left,
jackfly26 left
01:53
jackfly26 joined,
p6bannerbot sets mode: +v jackfly26
|
|||
ryn1x | or maybe (Pointer, CArray[num64) is rw) | 02:01 | |
timotimo | just num64 is rw | 02:02 | |
ryn1x | And I would be able to pass it some type of array of doubles for the image data? | 02:04 | |
timotimo | oh | ||
in that case it'd have to be CArray[num64] or Pointer[num64] or num64 @foo | |||
or Buf[num64] $data | |||
ryn1x | ok | 02:05 | |
jackfly26 | i think the official thing says CArray | ||
timotimo | i think all of them are compatible with what you want | 02:07 | |
ryn1x | thanks | 02:08 | |
timotimo | "num64 is rw" will only give you a single spot of data for nums | ||
hm | |||
actually, if you want the function to be able to change your array, maybe it has to actually be a CArray | 02:09 | ||
not sure about that | |||
02:10
AlexDani` joined
|
|||
jackfly26 | hi | 02:11 | |
02:11
p6bannerbot sets mode: +v AlexDani`
|
|||
timotimo | greetings jackfly26 | 02:11 | |
jackfly26 | i was saying hi to alexdani but ok | 02:12 | |
02:15
AlexDaniel left
|
|||
timotimo | oh, sorry | 02:18 | |
my irc client hides joins and parts until the user in question says something so that my screen isn't filled with 50% status messages | |||
so i didn't notice | |||
02:19
sno joined
|
|||
timotimo | jackfly26: you still looking for help with the grammar parsing thing? | 02:19 | |
02:20
p6bannerbot sets mode: +v sno
|
|||
timotimo | if you want something to share code with that also runs the code for you, try tio.run/ | 02:20 | |
buggable: browser | |||
huggable: browser | |||
huggable | timotimo, Run Perl 6 in your browser: tio.run/nexus/perl6 or glot.io | ||
jackfly26 | yes i am | 02:21 | |
timotimo | ah, yes, glot.io is the other one | ||
jackfly26 | but i gotta do homework | ||
be right back | |||
timotimo | OK | ||
i need a late night snack or my tummy growling will wake all the neighbors | |||
02:25
sno left,
daotoad joined
02:26
p6bannerbot sets mode: +v daotoad
|
|||
jackfly26 | its at glot.io/snippets/f7ntga1650 | 02:26 | |
i modified it to work with stdin | 02:27 | ||
no-n | what's a synonym for @a.push: $_ for @b? | 02:38 | |
jackfly26 | maybe use map? | 02:39 | |
timotimo | @a.append(@b) | ||
no-n | ty | ||
timotimo | glot.io/snippets/f7ntga1650 | 02:42 | |
does that give you my modifications? | |||
oh | 02:43 | ||
that's just your snippet again | 02:44 | ||
hold on | |||
glot.io/snippets/f7ntxvmzx2 | |||
there try that | |||
this will give you a trace of the grammar | 02:45 | ||
02:46
Xliff left
|
|||
timotimo | oh, hehe | 02:47 | |
02:47
Cabanoss- left
|
|||
timotimo | jackfly26: replacing "{" with '{' makes it get a bit further already | 02:47 | |
jackfly26 | i used the tracer | 02:48 | |
why does that do anything | |||
02:48
AlexDani` is now known as AlexDaniel,
Cabanossi joined
|
|||
timotimo | because a { inside "" will start an interpolation :) | 02:48 | |
m: say "hello { 1 + 2 } is good" | |||
camelia | hello 3 is good | ||
timotimo | m: say "hello {"foo bar"} is good" | ||
camelia | hello foo bar is good | ||
jackfly26 | oh' | 02:49 | |
timotimo | m: say "{"foo bar"}" | ||
camelia | foo bar | ||
AlexDaniel | jackfly26: hi :) | ||
02:49
p6bannerbot sets mode: +v Cabanossi
|
|||
timotimo | i think your token statement wants to be different, what you got there isn't a character class | 02:49 | |
jackfly26 | it isnt | ||
timotimo | m: say "hello world" ~~ / <-[\s(){}\[\]]>+ / | ||
camelia | 「hello」 | ||
jackfly26 | how would i do that then | ||
timotimo | like that | 02:50 | |
jackfly26 | ok | ||
the minus means not i assume | |||
timotimo | that's right | ||
it's for "arithmetic" on stuff | |||
so you can also do something like | |||
m: say "foo!! bar! baz?" ~~ m:g/ <[a..z]-[aeiou]>+ / | |||
camelia | (「f」 「b」 「r」 「b」 「z」) | ||
timotimo | <-[bar]> is just that without the first class | 02:51 | |
jackfly26 | alright thats as far as i expected it | ||
thanks | |||
im gonna go do math now | |||
timotimo | good luck! | ||
jackfly26 | im probably gonna come back when I do the actions class | 02:52 | |
thats gonna be fun | |||
timotimo | i'll probably be asleep by then | ||
jackfly26 | i mean not today | ||
timotimo | ah, OK | ||
action classes can be tricky to figure out at first, but then they are somewhat simple | |||
jackfly26 | ok | 02:55 | |
thanks for all your help | |||
timotimo | whenever any of your tokens/rules/whatever gets parsed successfully, it'll try to call a method of the same name on your action class (or instance if you used .new or something) and it will pass the match object as the first parameter | ||
you're welcome :) | |||
03:01
jackfly26 left
03:08
Xliff joined,
p6bannerbot sets mode: +v Xliff
03:17
ufobat_ joined
03:18
p6bannerbot sets mode: +v ufobat_
03:21
ufobat___ left
03:30
lookatme_q left
03:31
sno joined
03:32
p6bannerbot sets mode: +v sno
03:36
sno left
03:40
Xliff left
|
|||
ryn1x | So my module using nativecall was along smoothly, but I am stuck on probably the most important function! Any ideas for this one: int TinyTIFFReader_getSampleData(TinyTIFFReaderFile* tiff, void* buffer, uint16_t sample); | 03:55 | |
I dont know what to put as a parameter for "void* buffer" so that I can access the image data. | |||
04:05
mowcat left
04:06
mowcat joined
04:07
p6bannerbot sets mode: +v mowcat,
mowcat left
04:08
mowcat joined
04:09
p6bannerbot sets mode: +v mowcat
04:10
sno joined
|
|||
jmaslak | Declare it similar to: | 04:10 | |
ub inet_ntop(int32, Pointer, Blob, int32 --> Str) is native {*} | |||
sub inet_ntop(int32, Pointer, Blob, int32 --> Str) is native {*} | |||
04:10
Cabanoss- joined,
Cabanossi left,
p6bannerbot sets mode: +v sno
|
|||
jmaslak | (The blob paramter is a char*, but close enough here - use Blob) | 04:10 | |
04:11
p6bannerbot sets mode: +v Cabanoss-
|
|||
jmaslak | Then you can use buf8.allocate($length) to create a buf, and you just pass it as that parameter (in the Blob spot) | 04:11 | |
04:15
sno left
|
|||
ryn1x | hmm... I keep getting | 04:16 | |
Non-zero wait status: 11 | |||
Parse errors: Bad plan. | |||
my sub is: | 04:17 | ||
sub TinyTIFFReader_getSampleData( TinyTIFFReaderFile is rw, Blob is rw, uint16 ) | |||
returns int32 is native('tinytiff') is export { * } | |||
and the test is: | 04:19 | ||
sub TinyTIFFReader_getSampleData( TinyTIFFReaderFile is rw, Blob is rw, uint16 ) | |||
returns int32 is native('tinytiff') is export { * } | |||
oops | |||
my $sample-data = buf8.allocate(191*159); | |||
lives-ok { TinyTIFFReader_getSampleData($tiff, $sample-data, 0) }; | |||
04:20
`presiden joined,
p6bannerbot sets mode: +v `presiden
|
|||
ryn1x | hmm... I wonder it is my CStructs... something that this function is using that the others so far have not... | 04:25 | |
04:32
lookatme_q joined
04:33
p6bannerbot sets mode: +v lookatme_q
|
|||
loops | ryn1x: if my google-fu is okay, that error means your code is generating a SEGV fault from a bad memory access. | 04:38 | |
ryn1x | Is this correct for a struct ? C++: uint32_t* stripoffsets; Perl6: has CArray[uint32] $.stripoffsets; | ||
04:39
leont left
|
|||
ryn1x | loops: thanks... i think it is probably my struct then... | 04:39 | |
04:45
zacts joined,
p6bannerbot sets mode: +v zacts
04:58
jmerelo joined
04:59
p6bannerbot sets mode: +v jmerelo
05:05
autoprime19 joined
05:06
p6bannerbot sets mode: +v autoprime19
05:10
autoprime19 left
05:12
daotoad left
|
|||
ryn1x | I put the commented out c++ structs next to my perl6 CStructs if someone can have a peek and see if there is anything obviously wrong? github.com/ryn1x/Graphics-TinyTIFF...m6#L6:L103 | 05:13 | |
loops | ryn1x: I didn't look at your code sorry.. but I was playing around with Nativecall a bit here pastebin.com/vP2gXcE1 | 05:17 | |
ryn1x: If you omit the BUILD method of the struct, you get a SEGV.. | 05:18 | ||
ryn1x: (really don't know if it's related to what you're seeing tho.. just a stab in the dark) | |||
ryn1x | loops: Cool thanks! It looks like I'm not doing `method BUILD() { $!val := CArray[uint8].new }` ... is that required? | 05:20 | |
05:20
sno joined
|
|||
loops | ryn1x: you do need to initialize that field with an actual CArray it seems, declaring the type is not enough.. | 05:21 | |
05:21
p6bannerbot sets mode: +v sno
|
|||
loops | ryn1x: i'm just casting about in the dark here.. i am learning too. | 05:22 | |
ryn1x: if you look at docs.perl6.org/language/nativecall...management it shows that you can initialize those fields in C rather than the way I did it. | 05:23 | ||
But one way or the another they need to be created at runtime | |||
ryn1x | Hmm... I see here that they are doing somthing similar in TWEAK too... docs.perl6.org/language/nativecall#Structs | 05:25 | |
not sure if that is similar... I dont know what TWEAK is yet | |||
loops | ryn1x: I think that when you declare that struct field as a CArray you're essentially declaring a pointer | 05:26 | |
ryn1x: so it makes sense that at runtime you have to arrange for it to point at some memory.. either in C or inside a BUILD method | 05:27 | ||
05:27
sno left
|
|||
ryn1x | loops: that does make sense if you think of it that way | 05:27 | |
loops | that's what that $!val := CArray[uint8].new is doing... and notice it is binding with := not assigning with = | 05:28 | |
`presiden | so, I'm reading design.perl6.org/S01.html | 05:33 | |
> Larry's First Law of Language Redesign: Everyone wants the colon. | 05:34 | ||
question: what's the colon? | |||
loops | presiden: It literally means the colon... he's saying that everyone wants the short easy syntax to signify their favorite language feature | 05:35 | |
so you have to be really careful when deciding how to use the most desirable characters etc. | 05:36 | ||
`presiden | ah, the literal : character >_< | ||
ryn1x | loops: I am still getting the wait status 11 thing... I'm not good ar reading c, but it looks like you created a CArray[uint8] and passed it to the c func... and then the c func printed the value at index 0? | 05:39 | |
loops | ryn1x: yes | 05:42 | |
ryn1x | loop: I need to go the other way... pass a CArray pointer to the c function for it to populate | 05:43 | |
loops* | |||
loops | ryn1x: does the c function malloc the memory for you, or are you expected to pass in enough memory? | 05:44 | |
lol.. i just search for Tiny Tiff to take a look... and ended up in a porn site named Tiny Tiff heh | 05:46 | ||
ryn1x | I'm trying to read through the source. Here is a link right to the function that is giving me trouble: github.com/ryn1x/TinyTIFF/blob/88e...r.cpp#L590 | 05:47 | |
Tiny Tiff 😂 | 05:48 | ||
loops | I just cloned github.com/jkriege2/TinyTIFF hope it's the same cuz i have it built here | 05:49 | |
Oh, I see it's the same as the one you're using | 05:50 | ||
ryn1x | No its not... I had to midify some stuff like extern "C" to get it to work... | ||
loops | ah K.. i'll grab yours | ||
ryn1x | cool. thanks a lot for looking. | 05:51 | |
The Perl6 code/tests I have written so far are here too github.com/ryn1x/Graphics-TinyTIFF | |||
05:53
sno joined
05:54
p6bannerbot sets mode: +v sno
|
|||
loops | ryn1x: okay, if you look in the README example, the _caller_ is expected to pass in enough memory for the function to fill with the image data | 05:56 | |
ryn1x: that means that likely the CArray.new is likley the way to go. Although not the only option | 05:57 | ||
05:58
sno left
|
|||
ryn1x | loops: let me try that real quick... I was doing CArray[uintxx].new not just CArray.new ... | 05:59 | |
05:59
moony joined,
p6bannerbot sets mode: +v moony
|
|||
ryn1x | and then in my test file I pass it a: my $sample-data = buf8.allocate(191*159); | 05:59 | |
nope... same error... I guess it could be something else causing the null pointer... | 06:01 | ||
loops | ryn1x: use $sample-data := | 06:02 | |
not = | |||
ryn1x | oh shoot... good catch... | ||
loops | and if you're doing it that way, I don't think you need the BUILD stuff. | ||
ryn1x | ok.. took away the build stuff and changed to := but same issue | 06:04 | |
the other thing I am not super sure about it `HANDLE hFile;` and `HANDLE hFile;` in the TIFFReaderFile struct | 06:05 | ||
I just used has Pointer $.xxxx for both of those... | |||
06:07
lookatme_q left
06:08
lookatme_q joined,
p6bannerbot sets mode: +v lookatme_q
|
|||
buggable | New CPAN upload: Pod-Load-0.2.0.tar.gz by JMERELO modules.perl6.org/dist/Pod::Load:cpan:JMERELO | 06:14 | |
06:15
sno joined,
p6bannerbot sets mode: +v sno
|
|||
masak | I know I promised to have an excellent use for adverbs in the advent post, but I didn't end up using that | 06:24 | |
partly because I didn't find a way to do what I wanted in Rakudo | |||
loops | ryn1x: okay, I think i have it working here in a fashion | 06:25 | |
but my first try i get the error "only planar TIFF files are supported by this library | |||
ryn1x: I need a test tiff to try it out | 06:26 | ||
ryn1x | loops: oooh | ||
masak | m: sub infix:<≅>($l, $r, :$mod) { "$l ≅ $r (mod $mod)" }; say 3 ≅ 13 :mod(10) | ||
camelia | 5===SORRY!5=== Error while compiling <tmp> You can't adverb &infix:<≅> at <tmp>:1 ------> 3 ≅ $r (mod $mod)" }; say 3 ≅ 13 :mod(10)7⏏5<EOL> |
||
loops | ryn1x: I don't know what a planar tiff is heh | ||
masak | ...this seems to hit operators that were already defined in CORE. | 06:27 | |
ryn1x | loops: I dont know that either... there are some tiffs in here: github.com/ryn1x/TinyTIFF/tree/mas...eader_test | ||
masak | I don't know why I shouldn't be allowed to override an operator in a local scope and put an adverb on it | ||
m: sub infix:<floomp>($l, $r, :$mod) { "$l ≅ $r (mod $mod)" }; say 3 floomp 13 :mod(10) | 06:28 | ||
camelia | 3 ≅ 13 (mod 10) | ||
masak | m: sub infix:<≅≅>($l, $r, :$mod) { "$l ≅ $r (mod $mod)" }; say 3 ≅≅ 13 :mod(10) | 06:29 | |
camelia | 3 ≅ 13 (mod 10) | ||
loops | ryn1x: okay test16m_imagej.tif worked... and your library works with just a small change | ||
ryn1x | loops: cool! | 06:30 | |
loops | ryn1x: actually i cheated.. but i'll show you how i did it, and you can go from there.. | ||
ryn1x | ok | ||
loops | What's a good pastebin for P6? | 06:32 | |
ryn1x | I usually use gist.github.com | 06:33 | |
loops | ryn1x: okay : is.gd/nBfTK9 | 06:34 | |
ryn1x: So I cheated by importing NativeCall and doing my own thing.. but hopefully that is easy to incoporate in your module | 06:35 | ||
ryn1x: (actually, i just realized that's not exactly the struct issue you were working on, I just got excited that I read the .tif heh) | 06:37 | ||
you may have already gotten that far before. | 06:38 | ||
06:43
abraxxa left
|
|||
ryn1x | loops: if you got getSampleData working that is exactly my problem... trying to modify my code to be like yours now... not quite there yet ... | 06:44 | |
loops | ryn1x: yeah, it is working okay. Although all the tiff's i had locally weren't planar for some reason. but it printed out a nice error message saying so at least. | 06:45 | |
jmerelo | masak++ | 06:48 | |
06:54
reportable6 left
06:55
reportable6 joined,
ChanServ sets mode: +v reportable6
06:56
p6bannerbot sets mode: +v reportable6
|
|||
ryn1x | loops: So I ran you script and it worked perfectly! I still get the same error in my .t file though. maybe somethig with lives-ok.. | 06:57 | |
loops: thanks for all your help! | |||
loops | ryn1x: no worries, good luck with it | 06:58 | |
07:05
domidumont joined,
ToddAndMargo joined,
p6bannerbot sets mode: +v ToddAndMargo
|
|||
ToddAndMargo | Is there sometig wrong with the perl6 mailing list? [Status: Error, Address: [email@hidden.address] ResponseCode 421, Host not reachable.] | 07:05 | |
07:05
p6bannerbot sets mode: +v domidumont
|
|||
ryn1x | loops: wow.... found the seg fault. it is with the getImageDescription sub. weird cause it only crashed when getImageData is called after it.... use Test made me think it was the last test causing the error. | 07:07 | |
loops | ryn1x: oh yeah, I should have mentioned that.. I saw that and ignored it. | 07:08 | |
ryn1x | loops: it works with Buf now too... that way I don't need to hardcode the bit-depth in the library =) | 07:10 | |
man... use Test really sent me in the wrong direction on that one... | 07:11 | ||
07:12
kktt__ joined,
p6bannerbot sets mode: +v kktt__
07:14
kktt left
07:21
rindolf joined
07:22
p6bannerbot sets mode: +v rindolf
07:24
sno left
07:25
zacts left,
kktt__ left,
kktt joined
07:26
p6bannerbot sets mode: +v kktt
07:28
nadim joined
07:29
p6bannerbot sets mode: +v nadim
|
|||
jmerelo | Has everyone checked today's | 07:33 | |
AC? | |||
perl6advent.wordpress.com/2018/12/...happiness/ | 07:34 | ||
by masak | |||
07:34
ToddAndMargo left
07:35
jmerelo left
07:58
dct joined,
p6bannerbot sets mode: +v dct
08:03
nadim left
08:04
domidumont left
08:10
dct left
08:12
`presiden left
08:14
coet joined,
p6bannerbot sets mode: +v coet
08:19
domidumont joined
08:20
p6bannerbot sets mode: +v domidumont
08:22
zakharyas joined
08:23
p6bannerbot sets mode: +v zakharyas
|
|||
moritz | masak++ # very nice advent post | 08:23 | |
masak: it seems the "S E N D" line is mis-aligned with the other lines by one space. Intentional? | 08:25 | ||
08:27
kurahaupo left
08:31
kurahaupo joined
08:32
p6bannerbot sets mode: +v kurahaupo
08:36
kensanata joined,
p6bannerbot sets mode: +v kensanata
08:37
zacts joined,
p6bannerbot sets mode: +v zacts
|
|||
masak | moritz: no, not intentional. I noticed it too. will try to fix. | 08:48 | |
I like how the post turned out, but I'd like to make it a *lot* less vaporware-y | |||
maybe that's a good topic of discussion for here on #perl6, though | 08:49 | ||
I deeply believe this is the part we should steal from Lisp and Smalltalk: the notion that the language/grammar is not only not fixed, but subject to re-interpretation and mutation | |||
and that "raising up the language" to meet the problem often is a sensible thing to do | |||
mis-alignment fixed now. moritz++ | 08:53 | ||
08:57
lizmat joined,
p6bannerbot sets mode: +v lizmat,
finanalyst joined
08:58
p6bannerbot sets mode: +v finanalyst
|
|||
finanalyst | p6: class A {has @!xx; method v{ @!xx=Nil; say @!xx}};my A $q.=new; $q.v | 08:58 | |
camelia | [(Any)] | ||
08:58
kktt left
|
|||
finanalyst | Is setting @!variable = Nil expected to generate [(Nil)] ? That means @!variable.elems = 1 | 09:00 | |
p6: class A {has @.xx; method v{ @xx=Nil; say @!xx}};my A $q.=new; $q.v; say $q.xx.elems | 09:01 | ||
camelia | 5===SORRY!5=== Error while compiling <tmp> Variable '@xx' is not declared. Did you mean '@!xx'? at <tmp>:1 ------> 3class A {has @.xx; method v{ 7⏏5@xx=Nil; say @!xx}};my A $q.=new; $q.v; |
||
finanalyst | p6: class A {has @.xx; method v{ @.xx=Nil; say @!xx}};my A $q.=new; $q.v; say $q.xx.elems | ||
camelia | [(Any)] 1 |
||
SyrupThinker | finanalyst: docs.perl6.org/type/Nil#index-entr...assignment | 09:03 | |
finanalyst | p6: class A {has @.xx default (); method v{ @.xx=Nil; say @!xx}};my A $q.=new; $q.v; say $q.xx.elems | 09:04 | |
camelia | 5===SORRY!5=== Error while compiling <tmp> Two terms in a row at <tmp>:1 ------> 3class A {has @.xx7⏏5 default (); method v{ @.xx=Nil; say @!x expecting any of: infix infix stopper statement end … |
||
finanalyst | p6: class A {has @.xx is default (); method v{ @.xx=Nil; say @!xx}};my A $q.=new; $q.v; say $q.xx.elems | 09:05 | |
camelia | 5===SORRY!5=== Error while compiling <tmp> Signatures as constraints on variables not yet implemented. Sorry. at <tmp>:1 ------> 3class A {has @.xx is default ()7⏏5; method v{ @.xx=Nil; say @!xx}};my A $q |
||
finanalyst | SyrupThinker: Thanks. | 09:06 | |
09:07
holyghost joined,
p6bannerbot sets mode: +v holyghost
09:17
finanalyst left
|
|||
no-n | is it ok to export variables? (I read it is bad for perl 5) | 09:19 | |
09:31
dakkar joined
09:32
p6bannerbot sets mode: +v dakkar
09:43
zacts left
|
|||
masak | anyone interested in talking about "slang compilation"? we could also take the discussion on #perl6-macros | 09:55 | |
jnthn | masak: hmm, maybe :) | ||
masak | no-n: I'd say it's OK to export variables. not sure about the risk in Perl 5. | ||
jnthn: did you read my advent post? :) perl6advent.wordpress.com/2018/12/...happiness/ | 09:56 | ||
masak is shameless in his self-promotion | |||
jnthn | No :) | ||
masak | tl;dr: even a puzzle problem like "SEND + MORE = MONEY" boils down to a compilation task | 09:58 | |
Perl 6 will shine and be fully realized to the extent we can do what I do in that post but *inside the compiler pipeline* | |||
this requires slangs, and the ability to write rules that translate and modify Qtrees | 09:59 | ||
jnthn | Nice post :) | 10:00 | |
masak | \o/ | ||
10:01
brrt joined
|
|||
masak | maybe I should be consistent and refer to those as "langs", not "slangs": github.com/masak/007/issues/378 | 10:01 | |
10:02
brrt left
|
|||
masak | I guess my question is: what can we do (aside from landing macros from 007) to make this a reality in Perl 6? | 10:03 | |
jnthn | Well, it's the QTrees part of 007 that's key here, I think? | 10:04 | |
Question is to what degree QTrees are a good compilation target... | 10:05 | ||
masak | aye, and I guess that'd be the biggest "adoption pain point" for the Rakudo stack, too | ||
it's pretty targeted towards nqp's ASTs right now | 10:06 | ||
hm, maybe something could be done there, though: some kind of spike or exploration wherein we try to "slide Qtrees in" in a layer between | |||
maybe not even with the express goal of building the Final Thing, just harvesting feedback and seeing it work in *some* way | 10:07 | ||
jnthn | QAST is quite language agnostic, and that's its strength and its weakness. Qtrees are quite tied to Perl 6, which I guess will also turn out to be their strength and weakness :) | 10:08 | |
masak | the provided-from-the-start Qtrees are quite tied to 007^WPerl 6 | 10:09 | |
but the hierarchy is built to be extensible, and an open set | |||
I wish I had more hard data there :) haven't actually extended it so much yet | 10:10 | ||
jnthn | But what would an extension look like in terms of compilation? | 10:12 | |
Would one just need to desugar into other existing Qtrees? | |||
masak | aye | 10:13 | |
I still don't have all the answers, but it seems that there are different types of desugaring | |||
there's "I fully expect to be replaced by my desugar", as in macro expansion -- the original only sticks around when tooling wants it | |||
there's also "I want to present as first-class, but here's my implementation desugar" -- like when you create a repeat-while loop but it's implemented in terms of a while loop | 10:14 | ||
in the latter case, tooling that traverses the program structure is likely to see the unexpanded form, whereas tooling that wants to reason about data flow is likely to see the expanded form | 10:15 | ||
in a sense, the staged compilation that the blog post is talking about looks a lot like a slang-centered orchestrated macro expansion | 10:16 | ||
jnthn | Where the expanded form is effectively a subset of the Qtree language that is a closed set? | 10:19 | |
masak | aye | ||
it must bottom out in something that the compiler can attach to runtime semantics | 10:20 | ||
jnthn | Right | ||
masak | (in 007, I'm currently toying around with "subatomic" semantics for this; in that case even built-in `if` and `while` can be described in terms of these. but same end result.) | ||
jnthn | I guess there's the declaration side of it too (the actions/world split) | ||
masak | I confess to still not understanding world so well :/ | 10:21 | |
it's where declarations go, that much I know | |||
can it be summarized as a "static description" of program declarations? | |||
amusingly, *declarations* have come into focus in 007 in the past few months as something that the compiler needs to treat as first-class | 10:22 | ||
for two reasons: the new hygiene/lexical model hinges on them, and operator prec/assoc information hangs on that peg | 10:23 | ||
timotimo | masak: "represents a digits"? :) | 10:24 | |
masak | aie. | 10:25 | |
fixing. | |||
masak made a typos | |||
fix'd | 10:26 | ||
timotimo++ | |||
10:27
leont joined
|
|||
jnthn | masak: Well, static description in what sense? | 10:27 | |
10:28
p6bannerbot sets mode: +v leont
|
|||
masak | my understanding of World is that when you write `my` in your program, the parser finds that and something is added to World | 10:28 | |
but I'm not at all sure my understanding is correct :) | |||
jnthn | Yes, that's about right | ||
It's the declarations | |||
masak | and it makes a lot of sense to have that "on its own level" | 10:29 | |
I distinctly remember the pain of *not* having that on its own level | |||
jnthn | Me too :) | ||
masak | furthermore, I think Perl 6 is relatively unique in even having a level for that | ||
(but I might be wrong) | |||
I'm also proud of having named World :> | 10:30 | ||
but if I were to do it again, I would've gone with the German Veldt :P | |||
masak Second Naming Syndrome | |||
masak .oO( ^^ ) | 10:31 | ||
10:42
dogbert2_ left
10:48
zacts joined,
p6bannerbot sets mode: +v zacts
11:03
domidumont left
11:06
nadim joined
11:07
p6bannerbot sets mode: +v nadim
11:23
sena_kun joined
|
|||
buggable | New CPAN upload: Math-FFT-Libfftw3-0.1.3.tar.gz by FRITH modules.perl6.org/dist/Math::FFT::L...cpan:FRITH | 11:24 | |
11:24
p6bannerbot sets mode: +v sena_kun
11:45
nadim left
11:54
dogbert2_ joined
|
|||
tbrowder | jmerelo: just checked my advent post more closely and see another chunk wp ate! hope i can fix it, but not holding my breath... | 11:54 | |
11:55
p6bannerbot sets mode: +v dogbert2_
11:58
lucasb joined,
p6bannerbot sets mode: +v lucasb
12:18
lichtkind joined,
p6bannerbot sets mode: +v lichtkind
|
|||
lichtkind | is there a reason why rakudo .11 is not mentioned on this rakudo.org | 12:21 | |
lucasb | the links show here: rakudo.org/files/rakudo | 12:24 | |
the rakudo and nqp 2018.11 tarball releases | 12:25 | ||
lichtkind | yes but not there rakudo.org/files | 12:27 | |
lucasb | maybe because it only shows rakudo star releases, and there wasn't a Star release for the 2018.11 monthly | 12:28 | |
12:30
zacts left
|
|||
lucasb | Why rakudo.org is kept around? I agree it's very pretty and nicely designed. :) But IMO, I think I would prefer its content merged into perl6.org and rakudo.org become just a redirect to perl6.org. | 12:34 | |
12:35
nadim joined,
p6bannerbot sets mode: +v nadim
12:39
zakharyas left,
kurahaupo left
12:40
kurahaupo joined,
p6bannerbot sets mode: +v kurahaupo
12:51
Xliff joined,
p6bannerbot sets mode: +v Xliff
12:52
domidumont joined
12:53
p6bannerbot sets mode: +v domidumont
13:19
yqt joined
13:20
p6bannerbot sets mode: +v yqt
13:30
Trestto joined,
p6bannerbot sets mode: +v Trestto
|
|||
tyil | I wouldn't remove the rakudo site tbh | 13:31 | |
it's a very slick design, and is the site to get R* releases | |||
13:40
Trestto left
|
|||
moritz | lucasb: we still hope that, one day, there will be more than one major implementation of Perl 6 | 13:41 | |
tyil | afaiui, Perl 6 is "just" a spec, with rakudo being an implementation of it | 13:42 | |
lucasb | agreed, that's the way the story is being told for years :) | 13:43 | |
an alternative way of telling the story is saying that rakudo is *not* just one of the implementations, but rather, is the *reference implementation*, and for now, the only implementation avaiable | 13:44 | ||
moritz | but that we don't want to do, because it discourages other implementations | ||
tyil | that doesn't strike me as a good reason to undo all the work people have put into the rakudo.org site | ||
jnthn | lucasb: It's an alternative, but it's the story we're telling. | 13:45 | |
opos | |||
it's *not* the story we're telling | |||
We should keep the door open to alternative implementations. | 13:46 | ||
That's served us very well in the past. | |||
lucasb | I don't see how "reference implementation" is associated with discouraging/shutting the door for other implementations | 13:48 | |
the name says "implementation", it's just one, for it's the "reference" one :) | |||
*but it's the... | |||
moritz | it gives one implementation a special place that a newcomer cannot claim | ||
jnthn | Reference implementation suggests that Rakudo is what another implementation has to match up with to call itself a Perl 6 compiler, while in reality we want that to be the spectest suite. | 13:49 | |
For example, there's no reason for another implementation to provide any of the nqp::ops | 13:50 | ||
masak | I'm reminded of something pmichaud said | 13:52 | |
the answer to "what's the [official]...?" is "no" | |||
:) | 13:53 | ||
lucasb | seems the word "reference" or "official" is the problem :) | ||
masak | it seems to rub Perl people the wrong way a little | 13:54 | |
well, I guess Perl 5 has an official implementation :) | |||
jnthn | Well, I think we'd tend to agree the test suite is official, but not much else :) | ||
lucasb | if I start refering to Rakudo as the *de facto* or *most well-established* implementation, would you agree? | ||
13:55
reach_satori left
|
|||
masak | it'd take blindness to reality not to agree with those two labels ;) | 13:58 | |
but I'd be wary of throwing around even "de facto", since the way we use words tends to affect reality | |||
lucasb | yeah, subtleties in synonyms :) | 13:59 | |
14:13
yqt left
14:20
graphene left
14:22
graphene joined,
p6bannerbot sets mode: +v graphene
14:23
reach_satori joined
14:24
p6bannerbot sets mode: +v reach_satori
14:27
zakharyas joined
14:28
p6bannerbot sets mode: +v zakharyas
14:42
graphene left
14:44
graphene joined,
p6bannerbot sets mode: +v graphene
|
|||
Geth | doc: f0d6bb84d5 | (Elizabeth Mattijsen)++ | doc/Type/Buf.pod6 Document buf8.write-int/uint/num methods |
14:55 | |
synopsebot | Link: doc.perl6.org/type/Buf | ||
Geth | doc: 3660283c66 | (Elizabeth Mattijsen)++ | doc/Type/Blob.pod6 Some types in signature refinements |
14:59 | |
synopsebot | Link: doc.perl6.org/type/Blob | ||
15:13
nadim left
|
|||
lucasb | "In my view we have only one Perl community and it can’t be divisible." <-- I liked this response in the awards post :) | 15:21 | |
lizmat hopes her opinion on this subject is clear and will therefore refrain from commenting publicly as not to draw fire | 15:24 | ||
lucasb | I wouldn't mind leaving the Perl 5 folks alone and the P6 community start their own Camelia awards | ||
15:24
nadim joined
|
|||
lucasb | in fact, I think I even prefer a separate event :) | 15:25 | |
El_Che | lizmat: write a blog post :P | ||
lizmat: in the open letter format :) | |||
15:25
p6bannerbot sets mode: +v nadim
|
|||
lizmat | ferry vunny | 15:25 | |
El_Che | I am hilarious! | 15:26 | |
lizmat | El_Che: are you allowed to play with matches? :-) | 15:28 | |
lucasb | but maybe P6 community is too small to keep awarding 3 folks yearly | ||
Geth | doc: 7ffe0d1f3c | Coke++ | doc/Type/Blob.pod6 whitespace |
||
doc: 622183d6ab | Coke++ | doc/Type/Buf.pod6 fix typo in sig |
|||
synopsebot | Link: doc.perl6.org/type/Blob | ||
Link: doc.perl6.org/type/Buf | |||
El_Che | lucasb: "and the yearly Liz White Camelia goes this year to lizmat!" | 15:29 | |
lizmat | [Coke]++ # well caught! | ||
El_Che | yeah, bdoy's response was weird coming from a Perl 6 book author | 15:30 | |
lizmat | El_Che: one is enough :) | ||
El_Che | lizmat: it's not a "Liz White Camelia", though | 15:31 | |
lizmat: your award is outdated :) | |||
[Coke] | lizmat: I just run the tests. :) | 15:32 | |
lizmat | also for whitespace ?? | ||
[Coke] | yes. | 15:33 | |
that was the "we prefer spaces after our commas" test. | |||
the method sig was the compile test. | 15:34 | ||
lizmat | wow | ||
lucasb | is there a "after periods, prefer a single space instead of two" test? | ||
(or the other way around) | |||
[Coke] | I have a utility script that updates the git repo, then runs the extended tests only on those files so i can get things good locally and then just test the small things that have changed since (util/update-and-test) | 15:35 | |
lucasb: no, but it would be fairly easy to add if someone was excited about it. | |||
lucasb | hehe, I'm not. :) | 15:36 | |
[Coke] would start with github.com/perl6/doc/blob/master/x...er-comma.t | |||
15:36
smlck joined
15:37
p6bannerbot sets mode: +v smlck
|
|||
lucasb | I prefer if authors would avoid gratuitous "paragraph reflows" commits | 15:38 | |
15:40
smlck left
15:42
uzl joined
15:43
p6bannerbot sets mode: +v uzl
15:46
reach_satori left
15:49
reach_satori joined,
p6bannerbot sets mode: +v reach_satori
16:02
nadim left
16:09
zakharyas left
16:11
graphene left
|
|||
uzl | Hello everyone! So I'm trying to convert this .pod6 to .html and getting the following message: ===DEBUG: final cell layout for table 0. === cell contents are enclosed in single quotes ... | 16:12 | |
yoleaux | 12 Dec 2018 16:48Z <jmerelo> uzl: thanks! | ||
16:12
graphene joined
|
|||
Altreus | m: 'asdfdf <#506956345119866881> dasd as <#506956332247678986>' ~~ m:g/ '<#' (\d+) '>' /; say $/.list | 16:12 | |
camelia | (「<#506956345119866881>」 0 => 「506956345119866881」 「<#506956332247678986>」 0 => 「506956332247678986」) |
||
Altreus | help | ||
I thought I would only get the numbers when I did this | |||
uzl | Pod: snippi.com/raw/gvaart3 . I'm using the perl6 command with RAKUDO_POD_TABLE_DEBUG | ||
Altreus | what have I not understood? | 16:13 | |
16:13
p6bannerbot sets mode: +v graphene
|
|||
uzl | No problem, jmerelo! | 16:13 | |
Altreus | the regex docs implies I'll get just the numbers but as usual matching 'abc' against /(a) b (c)/ doesn't explain very much :P | ||
jnthn | Maybe you want <( \d+ )> instead | 16:15 | |
uzl | could you probably access each Match object's first element? | 16:16 | |
m: 'asdfdf <#506956345119866881> dasd as <#506956332247678986>' ~~ m:g/ '<#' (\d+) '>' /; say $/.list[0][0] | 16:17 | ||
camelia | 「506956345119866881」 | ||
Altreus | I understand | ||
kind of | |||
m: 'abc' ~~ /(a) b (c)/; say $/.list | 16:18 | ||
camelia | (「a」 「c」) | ||
Altreus | hmm | ||
but those are at the ends | |||
I think I get it | |||
jnthn | m:g does multiple matches, and <( )> set the limits of the matching | 16:21 | |
evalable6 | (exit code 1) 04===SORRY!04=== Error while compiling /tmp/O2Rtjzi3To Two ter… |
||
jnthn, Full output: gist.github.com/eea772e80efd46824c...cf7403a759 | |||
jnthn | Oh, be quiet, evalable6 | ||
16:28
jmerelo joined
16:29
p6bannerbot sets mode: +v jmerelo
16:30
smallick joined
16:31
p6bannerbot sets mode: +v smallick
|
|||
smallick | m: say 'Hello!'; | 16:31 | |
camelia | Hello! | ||
jmerelo | .seen tobs | ||
yoleaux | I saw tobs 16 Dec 2018 19:01Z in #perl6: <tobs> heh, I expect great things from the next three years | ||
tobs | jmerelo: o/ | ||
jmerelo | tobs: Ready for your Advent Calendar article? | ||
hi :-) | 16:32 | ||
smallick | m: (2..999).grep({ $_ %% 3 || $_ %% 5 }).reduce({ $^a + $^b }) | 16:33 | |
camelia | ( no output ) | ||
tobs | no, and in fact I might have to shuffle to the 20th because the final part of my code is not ready. I have today and tomorrow almost exclusively for the article though and could also lower my bar to meet the 19th. | 16:34 | |
sorry to say :/ | 16:35 | ||
jmerelo | tobs: I can ask scimon if he could move it up. I've seen it's already up there... No problem, I just wanted to check. | ||
uzl | Anybody has any idea if Pod formatting code(B<>, etc.) are rendered inside tables? | 16:36 | |
tobs | The last week before Christmas always feels like a marathon | ||
jmerelo | uzl: it's not | ||
tobs: let me check with scimon | 16:37 | ||
tobs | jmerelo: thanks | 16:38 | |
and good job keeping an eye on everyone | |||
uzl | jmerelo: Any way around it? In code blocks they're not by default but can be rendered if :allow is used. | ||
jmerelo | tobs: no problem :-) | ||
uzl: I'm afraid not. I think it happens at the parsing level, so no way to get it back when rendering it to something else. | 16:39 | ||
uzl | jmerelo: oh, OK. Thanks! | ||
'til later! | 16:40 | ||
16:40
uzl left
|
|||
jmerelo | see you! | 16:41 | |
16:42
tobs` joined,
p6bannerbot sets mode: +v tobs`
16:43
smallick left
|
|||
jmerelo | .seen SmokeMachine | 16:45 | |
yoleaux | I saw SmokeMachine 16 Dec 2018 00:31Z in #perl6: <SmokeMachine> like -MO=Deparser?! would be great! | ||
SmokeMachine | jmerelo: hi! | ||
16:46
molaf joined
|
|||
lizmat | and another Perl 6 Weekly hits the Net: p6weekly.wordpress.com/2018/12/17/...-designed/ | 16:46 | |
jmerelo | SmokeMachine: hi! | ||
16:46
p6bannerbot sets mode: +v molaf
|
|||
jmerelo | SmokeMachine: this is just a maybe, and a big one. Your article has been ready for a long time, up there in the site. I don't preview anything going amiss in the next few days, but if it happens, might I use it? | 16:47 | |
SmokeMachine | Sure! | 16:49 | |
Geth | advent: 458275ce3a | (Juan Julián Merelo Guervós)++ (committed using GitHub Web editor) | perl6advent-2018/schedule Changing schedule Changing @taboege and @Scimon |
16:50 | |
SmokeMachine | I’ve been doing some small changes on the post as I’m writing new stuff on Red... but it’s read every time I save :) | ||
Ready | 16:51 | ||
16:52
kensanata left
16:57
domidumont left
16:58
CaptHindsight joined,
graphene left
16:59
p6bannerbot sets mode: +v CaptHindsight
17:00
graphene joined,
p6bannerbot sets mode: +v graphene
|
|||
jmerelo | SmokeMachine: thanks! I don't think it's going to be needed after the last reshuffle, but just in case :-) | 17:01 | |
17:03
CaptHindsight left
17:04
graphene left
17:06
graphene joined,
p6bannerbot sets mode: +v graphene
17:24
graphene left
17:25
graphene joined
17:26
p6bannerbot sets mode: +v graphene
17:27
domidumont joined
17:28
p6bannerbot sets mode: +v domidumont
17:32
dakkar left
17:35
reach_satori left
17:37
nadim joined
17:38
p6bannerbot sets mode: +v nadim
17:40
zakharyas joined
17:41
p6bannerbot sets mode: +v zakharyas
17:43
tobs`` joined,
tobs` left
17:44
p6bannerbot sets mode: +v tobs``
17:53
itimmer joined
17:54
p6bannerbot sets mode: +v itimmer
17:58
itimmer left
18:01
yqt joined,
p6bannerbot sets mode: +v yqt
18:02
canr joined,
p6bannerbot sets mode: +v canr
|
|||
canr | I have code using native call that work fine on unix, but on windows it cannot find the ".dll". I have the directory with the dll in PATH and also LD_LIBRARY_PATH. Does anyone have experience with this? | 18:04 | |
18:14
reach_satori joined
18:15
p6bannerbot sets mode: +v reach_satori
|
|||
Elronnd | is there any type corresponding to an 80-bit float, lond double in c? | 18:16 | |
timotimo | we don't have that natively yet | ||
Elronnd | ok | 18:18 | |
18:22
random_yanek left
|
|||
buggable | New CPAN upload: Tomtit-0.0.5.tar.gz by MELEZHIK modules.perl6.org/dist/Tomtit:cpan:MELEZHIK | 18:34 | |
18:34
random_yanek joined
|
|||
leont | long double's semantics aren't well standardized, that doesn't help | 18:34 | |
18:35
p6bannerbot sets mode: +v random_yanek
|
|||
lizmat | at least we can read / write 128bit ints now :-) | 18:35 | |
canr | Also with like DBIish, sqlite3.dll cannot be found even though it is my windows path variable... on unix it works just fine... I don't know what I am doing wrong in windows... | 18:37 | |
18:37
sno joined
|
|||
lizmat | canr: if nobody answers you here, maybe asking on StackOverflow might help | 18:37 | |
stackoverflow.com/questions/tagged/perl6 | 18:38 | ||
18:38
p6bannerbot sets mode: +v sno
|
|||
timotimo | are dlls actually looked up in path? huh. | 18:41 | |
i haven't windowsed in so long, i've forgotten almost everything :o | 18:44 | ||
18:48
tobs`` left
|
|||
loops | Is there a way to mark a bunch of functions as "is export" as a group rather than adding that to each one? | 18:53 | |
18:53
zakharyas left
|
|||
timotimo | yeah, you can directly call trait_mod:<is>($the-routine, :export) on the objects, and you can find the function objects in MY::, so you can loop over them :D | 18:55 | |
18:55
tobs`` joined
|
|||
timotimo | though you'll find everything else in MY:: as well | 18:55 | |
18:56
p6bannerbot sets mode: +v tobs``
|
|||
loops | timotimo: ah okay, it's just as easy to manually edit them then.. was hoping to just say "export everything in this scope" | 18:57 | |
timotimo | dunno, i'd call using a little for loop easier | 18:58 | |
oh, should be at BEGIN time, though | |||
loops | timotimo: the other one that is a bit wordy, is having to say "is native('./mylib.so') { * };" for a big bunch of funcs too | 18:59 | |
timotimo | m: sub foo { }; sub bar { }; sub quux { }; BEGIN for MY::.grep(*.name.startswith('&')).map({ trait_mod:<is>($_, :export) }) | ||
camelia | 5===SORRY!5=== Expression needs parens to avoid gobbling block at <tmp>:1 ------> 3&')).map({ trait_mod:<is>($_, :export) }7⏏5) Missing block (apparently claimed by expression) at <tmp>:1 ------> 3')).map({ trait_mod:<is>($_, :e… |
||
Geth | doc: MorayJ++ created pull request #2512: Fix typo in example |
||
timotimo | m: sub foo { }; sub bar { }; sub quux { }; BEGIN do for MY::.grep(*.name.startswith('&')).map({ trait_mod:<is>($_, :export) }) | ||
camelia | 5===SORRY!5=== Expression needs parens to avoid gobbling block at <tmp>:1 ------> 3&')).map({ trait_mod:<is>($_, :export) }7⏏5) Missing block (apparently claimed by expression) at <tmp>:1 ------> 3')).map({ trait_mod:<is>($_, :e… |
||
timotimo | whoops | ||
loops | timotimo: yeah, i suppose i could do that, but it means a runtime task then, and can't be pre-compiled into the module. | ||
timotimo | m: sub foo { }; sub bar { }; sub quux { }; BEGIN MY::.grep(*.name.startswith('&')).map({ trait_mod:<is>($_, :export) }) | 19:00 | |
camelia | ( no output ) | ||
timotimo | no it totally gets pre-compiled | ||
canr | timotimo: The Docs say "...will be searched for in the paths in the LD_LIBRARY_PATH (PATH on Windows)" docs.perl6.org/language/nativecall..._and_names | ||
loops | timotimo: really? that is surprising | ||
timotimo | everything done and made in BEGIN will be precomped, for better or for worse | ||
canr | i assumed that implied windows looked up dlls in path, but i don't know windows... | ||
timotimo | e: my $foo = BEGIN open("/tmp/test.txt"); say $foo | 19:01 | |
evalable6 | Cannot test e96b7ffed44d13e25cce942b233c61fb1975d760 (Commit exists, but a perl6 executable could not be built for it) | ||
timotimo | e: 2018.10 my $foo = BEGIN open("/tmp/test.txt"); say $foo | ||
evalable6 | Cannot test e96b7ffed44d13e25cce942b233c61fb1975d760 (Commit exists, but a perl6 executable could not be built for it) | ||
timotimo | er | ||
e: 2018.09 my $foo = BEGIN open("/tmp/test.txt"); say $foo | |||
evalable6 | Cannot test e96b7ffed44d13e25cce942b233c61fb1975d760 (Commit exists, but a perl6 executable could not be built for it) | ||
timotimo | AlexDaniel: are the whateverables sick? | ||
AlexDaniel | o_o | 19:02 | |
ah no | |||
timeless: c: not e: | |||
oops | |||
timotimo: ↑ | |||
timeless looks up | |||
timotimo | oh | ||
AlexDaniel | timeless: sorry wrong nickname! :) | ||
timotimo | c: 2018.10 my $foo = BEGIN open("/tmp/test.txt"); say $foo | ||
committable6 | timotimo, ¦2018.10: «===SORRY!===Failed to open file /tmp/test.txt: No such file or directory «exit code = 1»» | ||
timotimo | c: 2018.10 my $foo = BEGIN open("/tmp/test.txt", :w); say $foo | ||
committable6 | timotimo, ¦2018.10: «IO::Handle<"/tmp/test.txt".IO>(opened)» | ||
timotimo | oh, handles survive that now? | ||
timeless | no worries | ||
timotimo | but probably not for full module precome | 19:03 | |
gotta go AFK now, though! | |||
loops: you can do "is native" the same way as "is export", you'll give the export named parameter the string value, then | |||
like trait_mod:<is>($theroutine, native => './mylib.so') | 19:04 | ||
19:06
pecastro joined
|
|||
loops | timotimo: you're right, that is pretty handy, esp since its included in the precompile | 19:06 | |
19:06
p6bannerbot sets mode: +v pecastro
|
|||
Xliff | (π/180).sin.cos | 19:09 | |
m: (π/180).sin.cos | |||
camelia | ( no output ) | ||
Xliff | m: (π/180).sin.cos.say | ||
camelia | 0.9998477106202734 | ||
Xliff | m: π/180.sin.cos.say | 19:10 | |
camelia | WARNINGS for <tmp>: 0.6958793964545379 Useless use of "/" in expression "π/180.sin.cos.say" in sink context (line 1) |
||
Xliff | m: π * 180.sin.cos.say | 19:11 | |
camelia | WARNINGS for <tmp>: 0.6958793964545379 Useless use of "*" in expression "π * 180.sin.cos.say" in sink context (line 1) |
||
Xliff | m: (π * 180.sin.cos).say | ||
camelia | 2.1861695996860755 | ||
Geth | doc: 1be949fcf5 | MorayJ++ | doc/Type/Signature.pod6 Fix typo in example |
19:13 | |
doc: 60048bcbb0 | Altai-man++ (committed using GitHub Web editor) | doc/Type/Signature.pod6 Merge pull request #2512 from MorayJ/fix-type Fix typo in example |
|||
synopsebot | Link: doc.perl6.org/type/Signature | ||
canr | So if windows has no standard lib dir, and .lib's are not auto found in path, do you need to check %*ENV for some predefined location when writing for windows? | 19:20 | |
19:20
random_yanek left
19:21
random_yanek joined,
random_yanek left
19:22
random_yanek joined
19:23
p6bannerbot sets mode: +v random_yanek
19:26
tobs`` left,
coet left
|
|||
timotimo | m: say Π | 19:27 | |
camelia | 5===SORRY!5=== Error while compiling <tmp> Undeclared routine: Π used at line 1 |
||
timotimo | m: π/180 andthen .sin.cos.say | 19:28 | |
camelia | 0.9998477106202734 | ||
timotimo | ^- fun way to drop precedence if you know the value isn't falsey | ||
19:43
domidumont left
19:56
canr left
19:57
gnustavo joined,
p6bannerbot sets mode: +v gnustavo
20:00
gnustavo left
20:07
graphene left
20:08
graphene joined
20:09
p6bannerbot sets mode: +v graphene
20:12
kensanata joined,
p6bannerbot sets mode: +v kensanata
20:21
graphene left
20:22
jmerelo left
20:23
graphene joined
20:24
p6bannerbot sets mode: +v graphene
20:32
melezhik joined,
p6bannerbot sets mode: +v melezhik
20:39
pmurias joined,
p6bannerbot sets mode: +v pmurias,
yqt left
20:42
pmurias left
20:46
graphene left
20:47
graphene joined
20:48
p6bannerbot sets mode: +v graphene
20:50
melezhik left
21:05
graphene left
21:07
graphene joined
21:08
p6bannerbot sets mode: +v graphene
21:09
graphene left
21:10
graphene joined
21:11
p6bannerbot sets mode: +v graphene
21:16
graphene left
21:18
graphene joined
21:19
p6bannerbot sets mode: +v graphene
21:25
ufobat_ left
21:26
ufobat_ joined,
p6bannerbot sets mode: +v ufobat_
21:28
lucasb left
21:33
ufobat_ left
21:38
kensanata left
21:52
dct joined,
p6bannerbot sets mode: +v dct
22:05
koto joined,
koto left
22:07
sena_kun left
22:26
rindolf left
|
|||
Geth | ecosystem: 155afa22b0 | thundergnat++ (committed using GitHub Web editor) | META.list Add X11-Xdo to the ecosystem Add bindings to libxdo X11 automation library. See github.com/thundergnat/X11-Xdo |
22:26 | |
22:31
coet joined,
p6bannerbot sets mode: +v coet
23:07
go|dfish left
23:09
nadim left
23:12
go|dfish joined,
p6bannerbot sets mode: +v go|dfish
23:16
aindilis left
23:20
dct left
23:30
irolaya joined,
p6bannerbot sets mode: +v irolaya
23:31
irolaya left
23:58
w_richard_w joined,
pecastro left
23:59
p6bannerbot sets mode: +v w_richard_w,
w_richard_w left
|