»ö« 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 ufobat left
Xliff m: $_ = 1; when 1 | 2 { say 'A'; } 00:06
camelia A
Xliff m: my enum blah <aa bb cc>; $_ = blah(1); when aa | bb { say 'A'; } 00:07
camelia A
Xliff m: my enum blah <aa bb cc>; $_ = blah(3); when aa | bb { say 'A'; }
camelia ( no output )
sena_kun Xliff, ping? 00:10
Xliff Yes?
sena_kun can you please check advent site? is 12th day shows up? 00:11
Xliff Yes.
It's up.
sena_kun \o/ 00:12
Xliff "Day 12 – Building a flexible grammar"
sena_kun now I need to get some sleep...
yes, I guess that's what it should be. the article was posted in drafts, so I was kinda forced to fix markup & publish. I hope I did everything okay. :S 00:13
Xliff One issue. 00:15
00:15 kolibrie joined, w_richard_w joined, zacts joined, p6bannerbot sets mode: +v zacts
Xliff I don't know if it can be solved. 00:15
It's fine as is, but it looks like the intention of the original author was to have some words in BOLD in the code markup.
00:16 p6bannerbot sets mode: +v kolibrie, p6bannerbot sets mode: +v w_richard_w
sena_kun well, you either have syntax highlighting or bold, I think. 00:16
Xliff Yes. 00:17
El Gato Negro 1 Gato Street, South Texas *Bueno*
Victor Mancho 3 Mancho Street, New York City *Malo*
*Bueno* and *Malo* should be bold, IIRC
sena_kun let me check it...
00:18 zacts left
Xliff If it can't be bold, I think it still works, though. 00:18
sena_kun updated to have bold text. 00:19
I wish people would discuss such things beforehand. :S anyway, I'm going to bed already. I hope I won't be fired for this. :) 00:20
00:22 sena_kun left 00:31 lucasb left 00:39 w_richard_w left, captain-adequate left 00:49 DarthGandalf left 01:11 lichtkind left 01:15 MasterDuke joined, p6bannerbot sets mode: +v MasterDuke 01:16 MasterDuke left, MasterDuke joined, herbert.freenode.net sets mode: +v MasterDuke, p6bannerbot sets mode: +v MasterDuke 01:20 MasterDuke left 01:35 daotoad joined, p6bannerbot sets mode: +v daotoad
Xliff Why was the rotor method named that way? 01:54
My zen question for the day.
02:12 kst joined 02:13 p6bannerbot sets mode: +v kst 02:23 molaf left 02:35 molaf joined 02:36 p6bannerbot sets mode: +v molaf 03:12 nelsonhb joined 03:13 p6bannerbot sets mode: +v nelsonhb 03:15 uzl joined, p6bannerbot sets mode: +v uzl
uzl .seen jmerelo 03:15
yoleaux I saw jmerelo 11 Dec 2018 19:58Z in #perl6: <jmerelo> lizmat, lucasb please do that.
03:15 jkramer joined 03:16 p6bannerbot sets mode: +v jkramer
Xliff What's the best way to see the signatures for a given method? 03:23
uzl .tell jmerelo Hi, JJ! I just saw your note for scheduling. I think my article is ready. However, if someone could look at it before posting it would be great.
yoleaux uzl: I'll pass your message to jmerelo.
uzl .tell jmerelo I already have the wordpress username but I'd appreciate if someone with more experience 03:24
yoleaux uzl: I'll pass your message to jmerelo.
uzl could do the posting. Or at least walk me through it.
.tell jmerelo BTW I was debating on changing the article's title since it might give the wrong impression. I'm fine with it but if you've a better title I'd go with it.
yoleaux uzl: I'll pass your message to jmerelo.
uzl .tell jmerelo Article: gist.github.com/uzluisf/268a95ffec...254a3971d1
yoleaux uzl: I'll pass your message to jmerelo.
uzl Hello, I'm looking for someone to proofread my article( gist.github.com/uzluisf/268a95ffec...254a3971d1 ). Any correction/suggestion is welcome. I'll probably be back tomorrow! 03:28
03:28 uzl left 03:40 Sgeo left 03:56 graphene left 03:57 graphene joined 03:58 p6bannerbot sets mode: +v graphene 03:59 esh joined 04:00 p6bannerbot sets mode: +v esh 04:03 llfourn joined, p6bannerbot sets mode: +v llfourn 04:04 Sgeo joined 04:05 p6bannerbot sets mode: +v Sgeo 04:06 epony left
Xliff .tell uzl In your first example, the second comparison has a comment that should read "True, 220 and 284 are though." -- you had "28" rather than "284". 04:07
yoleaux Xliff: I'll pass your message to uzl.
04:07 nine joined 04:08 p6bannerbot sets mode: +v nine, camelia joined 04:09 p6bannerbot sets mode: +v camelia 04:12 epony joined, p6bannerbot sets mode: +v epony 04:13 epony left 04:14 epony joined, p6bannerbot sets mode: +v epony 04:15 Cabanoss- joined 04:16 p6bannerbot sets mode: +v Cabanoss- 04:17 Cabanossi left
nelsonhb Hiranyagarbha (the cosmic egg).He is more prominently mentioned in the post-Vedic Hindu epics and the mythologies in the Puranas. In the epics, he is conflated with Purusha. 04:30
04:46 sauvin joined, p6bannerbot sets mode: +v sauvin, molaf left
Xliff source: NativeCall::Types 04:52
holyghost bron == source :-) 05:02
nelsonhb The succession of these flame emperors, from Shennong, the first Yan Emperor, until the time of the last Yan Emperor's defeat by the Yellow 05:04
Emperor, may have been some 500 years.
05:08 kst` joined, p6bannerbot sets mode: +v kst`, kktt joined, p6bannerbot sets mode: +v kktt 05:10 kst left 05:17 Xliff left, Xliff joined 05:18 mattp_ left, llfourn left, p6bannerbot sets mode: +v Xliff, llfourn joined, mattp_ joined 05:19 nelsonhb left, Actualey` joined, nightfrog left, p6bannerbot sets mode: +v llfourn, p6bannerbot sets mode: +v mattp_, nightfrog joined 05:20 p6bannerbot sets mode: +v Actualey`, p6bannerbot sets mode: +v nightfrog 05:21 MilkmanDan left, nelsonhb joined, nelsonhb left, MilkmanDan joined, p6bannerbot sets mode: +v MilkmanDan 05:23 kktt left, Actualeyes left 05:28 nelsonhb joined, nelsonhb left, nelsonhb joined, nelsonhb left 05:33 nelsonhb joined, nelsonhb left 05:35 w_richard_w joined 05:36 p6bannerbot sets mode: +v w_richard_w 05:37 nelsonhb joined, nelsonhb left, nelsonhb joined, nelsonhb left 05:39 nelsonhb joined, nelsonhb left 05:47 Sgeo left, Sgeo joined 05:48 p6bannerbot sets mode: +v Sgeo 05:51 curan joined, p6bannerbot sets mode: +v curan 05:52 Sgeo_ joined 05:53 p6bannerbot sets mode: +v Sgeo_ 05:55 Sgeo left 05:58 w_richard_w left 06:00 jmerelo joined 06:01 p6bannerbot sets mode: +v jmerelo 06:16 nelsonhb joined, nelsonhb left 06:17 nelsonhb joined, nelsonhb left
jmerelo Today, MorayJ tells us how to build a flexible grammar perl6advent.wordpress.com/2018/12/...e-grammar/ 06:26
yoleaux 03:23Z <uzl> jmerelo: Hi, JJ! I just saw your note for scheduling. I think my article is ready. However, if someone could look at it before posting it would be great.
03:24Z <uzl> jmerelo: I already have the wordpress username but I'd appreciate if someone with more experience
03:24Z <uzl> jmerelo: BTW I was debating on changing the article's title since it might give the wrong impression. I'm fine with it but if you've a better title I'd go with it.
03:24Z <uzl> jmerelo: Article: gist.github.com/uzluisf/268a95ffec...254a3971d1
jmerelo .tell uzluisf It's mostly OK, but did you read the comments by Xliff? The title is OK. I might have used something like "Calling numbers names" "Or numbers by any other name" or something like that, but it's OK. 06:28
yoleaux jmerelo: I'll pass your message to uzluisf.
jmerelo .tell uzl (just in case) It's mostly OK, but did you read the comments by Xliff? The title is OK. I might have used something like "Calling numbers names" "Or numbers by any other name" or something like that, but it's OK.
yoleaux jmerelo: I'll pass your message to uzl.
06:29 kurahaupo joined 06:30 p6bannerbot sets mode: +v kurahaupo 06:32 abraxxa joined
Geth doc: d49329e9c3 | (JJ Merelo)++ | doc/Type/Signature.pod6
Adjust line length
06:32
06:32 abraxxa left 06:33 abraxxa joined 06:34 p6bannerbot sets mode: +v abraxxa 06:35 aindilis left, aindilis joined, aindilis left
Geth doc: b9dce77293 | (JJ Merelo)++ | doc/Type/Signature.pod6
Changes =item to =head4 sections

This refs #2483
I leave the issue open just in case some other similar pages are found
06:35
06:36 DarthGandalf joined, p6bannerbot sets mode: +v DarthGandalf 06:37 abraxxa left
jmerelo From StackOverflow: stackoverflow.com/questions/537361...ationstore Can anyone help? 06:38
06:52 abraxxa joined 06:53 p6bannerbot sets mode: +v abraxxa 06:54 aindilis joined 06:55 p6bannerbot sets mode: +v aindilis
tyil I'm sure perl 6 has an operator to compare 2 arrays for being equal 07:00
(ie, both contain the same values)
07:02 domidumont joined, kensanata joined, p6bannerbot sets mode: +v kensanata
holyghost if there's not maybe @l.eq(@l2) should be made 07:02
07:03 p6bannerbot sets mode: +v domidumont
holyghost without regarding pointers to lists 07:04
jmerelo tyil: ===, I think. That's object equality. Or >=<
Geth doc: 5063159650 | (JJ Merelo)++ | 2 files
Quirks of do when added.

Closes #2506
07:05
doc: c8066ff988 | (JJ Merelo)++ | doc/Language/pod.pod6
Checking changes, closes #2507
07:07
07:09 abraxxa left 07:10 jmerelo left 07:12 graphene left 07:14 graphene joined, p6bannerbot sets mode: +v graphene 07:32 andrzejku_ joined, andrzejku left, andrzejku_ is now known as andrzejku 07:33 p6bannerbot sets mode: +v andrzejku 07:34 kurahaupo left 07:35 kurahaupo joined 07:36 p6bannerbot sets mode: +v kurahaupo, andrzejku left, andrzejku joined 07:37 p6bannerbot sets mode: +v andrzejku
moritz if you want to compare arrays by their contents, use eqv 07:41
07:43 Manifest0 left, Manifest0 joined 07:44 p6bannerbot sets mode: +v Manifest0, ufobat joined 07:45 p6bannerbot sets mode: +v ufobat 07:46 kurahaupo_ joined 07:47 p6bannerbot sets mode: +v kurahaupo_ 07:50 kurahaupo left 07:53 nebuchadnezzar joined 07:54 p6bannerbot sets mode: +v nebuchadnezzar 07:56 kensanata left 08:01 xlat joined 08:02 p6bannerbot sets mode: +v xlat 08:09 kurahaupo_ is now known as kurahaupo 08:12 robertle joined, ufobat left 08:13 p6bannerbot sets mode: +v robertle 08:17 kurahaupo is now known as Dave_________ 08:18 Dave_________ is now known as kurahaupo 08:19 lookatme_q left 08:20 lookatme_q joined 08:21 p6bannerbot sets mode: +v lookatme_q 08:23 rindolf joined
Xliff \o 08:23
Anyone awake? I am having some weird issues with CArrays 08:24
08:24 p6bannerbot sets mode: +v rindolf
Xliff (Yes. AGAIN) 08:24
Long story short, what would cause this error message: Unknown element type in CArray 08:25
lizmat m: my @a = 1,2,3; my @b = 3,2,1; dd @a eqv @b # tyil 08:26
camelia Bool::False
lizmat m: my @a = 1,2,3; my @b = 1,2,3; dd @a eqv @b # tyil
camelia Bool::True
Xliff \o lizmat
Is this early or late for you? :)
lizmat early actually, 9:30 am 08:27
Xliff: and I'm afraid I don't have an answer for your questionn
Xliff lizmat: That's OK. I'm afraid this might be another jnthn or timotimo question. 08:28
(am I missing someone?) 08:29
At any rate: Good morning!
It's 3:30am here.
m: my @a = <a b c d e f>; say $a.iterator.pull-one;
camelia 5===SORRY!5=== Error while compiling <tmp>
Variable '$a' is not declared. Did you mean '@a'?
at <tmp>:1
------> 3my @a = <a b c d e f>; say 7⏏5$a.iterator.pull-one;
Xliff m: my @a = <a b c d e f>; say @a.iterator.pull-one;
camelia a
Xliff m: use v6.c; class A { has @!a = <1 2 3>; method iterator { say 'Iterator'; my @a := @!a; class :: does Iterator { has $.index is rw = 0; method pull-one { @a.elems > $.index ?? @a[$.index++] !! IterationEnd; } }.new; }; }; .say for A.new; 08:30
camelia Iterator
1
2
3
Xliff m: use v6.c; class A { has @!a = <1 2 3>; method iterator { say 'Iterator'; my @a := @!a; class :: does Iterator { has $.index is rw = 0; method pull-one { @a.elems > $.index ?? @a[$.index++] !! IterationEnd; } }.new; }; }; A.new.iterator.pull-one.say 08:31
camelia Iterator
1
Xliff goes for a cig
08:32 abraxxa joined 08:33 p6bannerbot sets mode: +v abraxxa
Xliff OK. Write up here: gist.github.com/Xliff/cba831252504...205437bd0b -- I will ping back later to see if an issue should be created. 08:46
G'night!
08:51 kensanata joined, p6bannerbot sets mode: +v kensanata 09:05 nelsonhb joined, p6bannerbot sets mode: +v nelsonhb 09:06 zakharyas joined 09:07 p6bannerbot sets mode: +v zakharyas 09:09 dakkar joined 09:10 p6bannerbot sets mode: +v dakkar 09:11 scimon joined 09:12 p6bannerbot sets mode: +v scimon 09:17 titsuki left, rindolf left
tyil lizmat: interesting 09:22
lizmat tyil: it's what is-deeply uses under the hood 09:23
tyil if I sort the lists, and then use eqv, it should work for my usecase
09:23 ufobat joined
tyil I dont care about the order, just whether they have the same entries 09:23
lizmat and the same number of entries ? 09:24
I mean <a a> eqv <a> or not ?
tyil yes, but that's a check I can do before even considering eqv
09:24 p6bannerbot sets mode: +v ufobat
tyil if the number of elements differ, they're clearly not the same 09:24
lizmat right 09:25
tyil if the number of elements is equal, I want to know whether they have the same entries, in no particular order
lizmat hmmm... wonder if there is some set op that you could use...
tyil that's what I was wondering too :) 09:26
but I can do with @a.sort eqv @b.sort
lizmat are the lists big ? 09:28
09:31 rindolf joined 09:32 p6bannerbot sets mode: +v rindolf
moritz or possibly set(@a) eqv set(@b) 09:32
lizmat m: my @a = 1,2,3; my @b = 3,2,1; dd @a == @b && @a (<=) @b 09:34
camelia Bool::True
lizmat that probably uses set semantics, which is ok if you're sure each value only occurs once in every list
m: my @a = 1,2,3; my @b = 3,2,1; dd @a == @b && @a (<=) @b.Bag # force Bag semantics otherwise 09:35
camelia Bool::True
lizmat I wonder if a (==) op would make sense
09:53 gregf_ joined, p6bannerbot sets mode: +v gregf_ 10:03 scimon left, scimon joined
tyil lizmat: they may become big I guess 10:04
10:04 p6bannerbot sets mode: +v scimon
tyil for now I'm not expecting lists larger than 50 entries 10:04
lizmat then sorting should be quick an dirty 10:08
10:24 rindolf left
tobs There's also symmetric difference (^) which is empty precisely when the sets/bags are the same 10:29
lizmat tobs++ 10:30
m: my @a = 1,2,3; my @b = 3,2,1; dd @a == @b && @a (^) @b
camelia Set.new()
lizmat m: my @a = 1,2,3; my @b = 3,2,1; dd @a == @b && @a (^) @b.Bag 10:31
camelia ().Bag
10:31 rindolf joined
lizmat slight problem with that is that it doesn't shortcut as soon as it sees a difference 10:31
which (==) could 10:32
10:32 p6bannerbot sets mode: +v rindolf 10:35 lucasb joined, p6bannerbot sets mode: +v lucasb
tyil tobs: unrelated to my earlier question, but can I use symmetric difference to show me all the entries that appear in the RHS that *dont* appear in the LHS? 10:39
and vice-versa, give me all entries that appear in the LHS but not in the RHS
lizmat m: my @a = 1,2,3,5; my @b = 1,2,3,4; dd @a (-) @b # ones on the left not on the right 10:44
camelia Set.new(5)
lizmat m: my @a = 1,2,3,5; my @b = 1,2,3,4; dd @a R(-) @b # ones on the right not on the left
camelia Set.new(4)
lucasb tyil: are you doing AoC? :)
tyil AoC? 10:45
(that's probably a no)
I'm making a program in Perl 6 to configure nginx and request new certs through certbot anytime I add a new host 10:46
lucasb ah, sorry. I thought perhaps was practicing Advent of Code :)
tyil it is to be the frontend service for my kubernetes cluster
once this is done I have two other (fun) projects to do in Perl 6 :>
apart from rewriting all sorts of stuff at work into perl 6, that is
if I can get stackoverflow.com/questions/536925...-ircclient answered with a "yes", I'll have three other projects :D 10:48
lizmat tyil: that's above my paygrade :-(
tyil w-what is? :o
lizmat using certfp 10:49
tyil ah
lizmat well, I would have to spend a relative large amount of time on that, that hopefully someone else has already done
tyil I'm willing to offer you one of my cherished cans of cider at the next amsterdam.pm :>
lizmat ok :-) it's not 8 Jan yet :-) 10:50
tyil I'm not in a hurry
the other projects will take me quite some time
and at the end of the month I wont have much time 10:51
and then next month I wont have much time either, as I may or may not be moving to amsterdam :p
lizmat ah.. the joys of living together :-) 10:54
mornfall is there a (simple-ish) way to inject a method into an existing class instance?
i'm using .&foo but it's a bit hacking for the downstream
hackish*
lizmat m: 'my $a = 42 but role { method foo { "foo" } }; say $a.foo 10:55
camelia 5===SORRY!5=== Error while compiling <tmp>
Unable to parse expression in single quotes; couldn't find final "'" (corresponding starter was at line 1)
at <tmp>:1
------> 3ole { method foo { "foo" } }; say $a.foo7⏏5<EOL>
expecting …
10:55 scimon left
lizmat m: my $a = 42 but role { method foo { "foo" } }; say $a.foo 10:55
camelia foo
10:55 scimon joined
lizmat mornfall ^^ 10:55
10:56 p6bannerbot sets mode: +v scimon
mornfall lizmat: thanks, cool 10:58
11:01 domidumont left
mornfall is there a case-insensitive version of eq? 11:08
lucasb maybe $foo.fc eq $bar.fc
mornfall oh okay, .fc works (i tried .to-lower without much success :p) 11:09
tyil .lc is for lowercasing 11:12
yoleaux CalculatorParseError: Unknown syntax at position 0
tyil docs.perl6.org/routine/lc
but I'd suggest using fc as lucasb recommended 11:13
lizmat m: sub infix:<fceq>($a,$b) { $a.fc eq $b.fc }; dd "foo" fceq "fOo" 11:18
camelia Bool::True
11:31 kurahaupo left 11:34 kurahaupo joined 11:35 p6bannerbot sets mode: +v kurahaupo 11:40 tobs` joined, p6bannerbot sets mode: +v tobs` 11:47 zakharyas left
Ulti jnthn: whatever happened to github.com/jnthn/grammar-generative ? >:3 feels like a super nice idea in general, is it essentially impossible in reality? 11:50
mornfall WARNING: unhandled Failure detected in DESTROY. If you meant to ignore it, you can mark it as handled by calling .Bool, .so, .not, or .defined methods. The Failure was: [snip]
how would this happen? it's like a regular throw in a with block in a sub?
(the backtrace it gives, that is) 11:51
11:58 nige_ joined 11:59 p6bannerbot sets mode: +v nige_ 12:00 nige left
lucasb do you see the place the failure was created? 12:00
mornfall reviews exception docs 12:04
turns out i should not be using 'fail' at all, i want a die/.throw 12:07
lizmat m: for ^280 { my $a := Failure.new }
camelia ( no output )
lizmat m: for ^280 { my $a := Failure.new }
camelia WARNING: unhandled Failure detected in DESTROY. If you meant to ignore it, you can mark it as handled by calling .Bool, .so, .not, or .defined methods. The Failure was:
Failed

WARNING: unhandled Failure detected in DESTROY. If you meant to igno…
lizmat this code created a lot of unhandled Failure objects, as soon as the GC kicks in, the warnings appear 12:08
jnthn Ulti: Never really found time to continue working on it. I don't think it's impossible, but I only got it working for one sort-of-interesting example case. 12:09
yoleaux 11 Dec 2018 11:04Z <lizmat> jnthn: are dynamic variable lookups cached and if so, OOC how?
12:09 Actualey` left
jnthn Ulti: And that's before we even begin to consider performance :) 12:09
But as an idea, yeah, it's quite neat :) 12:10
I guess you already found the slides of the talk I gave about it too?
lizmat: MoarVM caches successful dynvar lookups that are resolved on the call stack. We currently don't cache failure to find one, nor any that are resolved in, say, PROCESS
lizmat I was thinking that looking for uninitialized dynvars may be a source of slowdown 12:12
jnthn Yeah, that will try all the places
Well, non-existing anyway
lizmat so I was thinking, what if a *mentioning* a dynvar in a scope would automatically create a slot in its MY::
jnthn lunch &
lizmat: Rebinding 12:13
lizmat ? 12:14
12:15 pmurias joined, p6bannerbot sets mode: +v pmurias
pmurias what should $*DISTRO.name return when running in a browser (say Chrome) 12:16
?
lizmat depends on the OS it's running on ?
m: $*DISTRO.name 12:18
camelia ( no output )
lizmat m: say $*DISTRO.name
camelia opensuse
12:19 fvox`away is now known as fvox
pmurias lizmat: hmm, I don't have access to the precise distro information 12:28
lizmat: also I'm not sure if returning say linux when running in Chrome on linux wouldn't be misleading 12:29
lizmat: as it's not quite a different thing then running in linux natively
lizmat can you access the browser ID string? maybe that's a good replacement, and may contain the OS it runs on anyway 12:30
12:30 pmurias left 12:31 pmurias joined, p6bannerbot sets mode: +v pmurias
pmurias lizmat: yes I can 12:33
lizmat hmmm.... thinking about that more 12:41
maybe we should introduce a $*BROWSER ?
so that a. you could check *if* you're running in a browser 12:42
and b. provide all sorts of introspectoin
on the jvm / moarvm / js bare backend, that would be Nil 12:43
and have $*DISTRO remain the same
pmurias we do have a bunch of data available from window.navigator (developer.mozilla.org/en-US/docs/W...Navigator) so adding a $*BROWSER to access it would make sense 12:46
12:47 domidumont joined 12:48 p6bannerbot sets mode: +v domidumont, domidumont left
lizmat sounds like a plan to me 12:49
12:51 pmurias left 12:59 graphene left 13:00 pmurias joined, p6bannerbot sets mode: +v pmurias, graphene joined 13:01 p6bannerbot sets mode: +v graphene 13:02 |oLa| joined, pmurias left 13:03 p6bannerbot sets mode: +v |oLa| 13:05 yqt joined, pmurias joined, p6bannerbot sets mode: +v pmurias 13:06 p6bannerbot sets mode: +v yqt
pmurias lizmat: I used grep.cpanauthors.org (btw. which I found in the weekly) and it seems $*DISTRO.name is mostly used for detecting os to special case their differences 13:17
especially we don't want to use the .is-win special handling
lizmat so $*BROWSER seems like a good idea ? 13:18
pmurias lizmat: $*BROWSER definitely seems like a good idea 13:19
lucasb well, it opens precedent for $*FUTURISTIC-DEVICE :)
$*ANDROID ? 13:20
lizmat I think *$BROWSER atm for this is better
but perhaps a more genenic $*EMBEDDED 13:21
?
in any case, the term "browser" becomes more and more general, so I think we're going to be safe in that respect for a while
pmurias lizmat: just that setting $*DISTRO.name to 'browser' might be better than returning the host os and confusing 13:22
os checks
tbrowder o/
lucasb yeah, $*BROWSER is much more convenient to type :)
tbrowder: o/ 13:23
lizmat pmurias: not sure... feels to me $*DISTRO should stay doing what it does even in a browser
even if it may be confusing in a browser setting 13:24
tbrowder question: can a cro service be deployed on apache2 or nginx in the same manner as Bailador (using a reverse proxy)?
lizmat tbrowder: at that level, it's just HTTP going back and forth, so there should be no difference 13:25
If I understand the question correctly
ufobat tbrowder, i think yeah
tbrowder i want to deploy a new site using cro, but i want to make sure it's secure as my current apache2 sites are. 13:26
13:27 aindilis left
ufobat i think it might be not working if you want to do http/2 to your reverse proxy 13:27
13:27 aindilis joined
tbrowder no, not using http2 yet 13:28
ufobat but internet -> https -> ngnix/apache -> http -> cro/bailador works, i think
tbrowder but https
13:28 p6bannerbot sets mode: +v aindilis
jnthn tbrowder: Yes, I've got most of my my production Cro apps deployed with an Apache reverse proxy; works fine. 13:28
ufobat tbrowder, maybe that helps you a bit gitlab.com/ufobat/voteimproved 13:29
tbrowder jnthn: do you use sytemd for starts and shutdowns?
jnthn tbrowder: No
tbrowder if so, mind sharing the config files?
jnthn tbrowder: Deployed in containers in a kubernetes cluster 13:30
tbrowder ah!
jnthn (Apache in its own container)
nelsonhb The succession of these flame emperors, from Shennong, the first Yan Emperor, until the time of the last Yan Emperor's defeat by the Yellow
Emperor, may have been some 500 years.
tbrowder jnthn: thanks 13:31
ufobat: thanks 13:32
13:32 Peter_R joined, p6bannerbot sets mode: +v Peter_R
tbrowder funny, just saw new email announcement from digitalocean about their new kubernetes DOK8s 13:34
13:35 zakharyas joined, p6bannerbot sets mode: +v zakharyas
Ulti jnthn: no not seen the slides, is it on your homepage under talks/papers I can go find it 13:36
jnthn Ulti: yeah, I think it had some title like "What if Perl 6 grammers could generate?" or something 13:37
I think it went down as the most headache-inducing talk I ever gave
Ulti Im just thinking for my bioinformatics stuff where I have some grammars it would be really quite nice to easily de/serialize using the same thing
jnthn: sounds good :) I will make sure to do some blood letting before I read it
oh you've updated your site! swanky 13:38
incase anyone else is interested jnthn.net/papers/2013-yapcna-gramma...nerate.pdf
especially as formats like Newick for representing phylogenetic trees are litterally just a parse tree and back again really 13:40
13:41 ufobat left 13:43 c1nil joined, p6bannerbot sets mode: +v c1nil
c1nil can i use mutable sub parameters? 13:45
pmurias jnthn: you might want to have a look at the boomerang language if you are interested in bidirectional parsing (and well everything)
lucasb c1nil: sub foo($x is copy) # if that's what you mean 13:46
pmurias lizmat: it seems like a tradeoff between being more truthfull (in a way) and pragmatism, I'll think that over 13:52
nelsonhb Netaji Subhas Chandra Bose International Airport
Bir Tikendrajit International Airport
Guwahati International Airport
Mandalay International Airport
Chiang Mai International Airport
Noi Bai International Airport
Siem Reap-Angkor International Airport
Mactan–Cebu International Airport
13:53 ChanServ sets mode: +o jnthn, pmurias left, nelsonhb was kicked by jnthn (nelsonhb)) 13:54 jnthn sets mode: -o jnthn, pmurias joined, p6bannerbot sets mode: +v pmurias
rindolf jnthn: thanks 13:56
pmurias lizmat: linux-browser is also something I'm considering (so that it both doesn't hide info and doesn't accidently get matched by some platform check) 13:59
14:02 molaf joined 14:03 p6bannerbot sets mode: +v molaf
pmurias in roast we have a test like this: ok +%*ENV.keys, '%*ENV has keys'; 14:11
do we want to *require* that the env variables aren't empty no matter where we are running?
timotimo ha 14:12
14:15 sena_kun joined
pmurias not a big problem to add some fake variables there for rakudo.js but getting rid of the test seems cleanr 14:16
* cleaner
14:16 p6bannerbot sets mode: +v sena_kun 14:17 manjaro-user- joined 14:18 p6bannerbot sets mode: +v manjaro-user-, nige_ left
vrurg pmurias: maybe skipping on certain platforms would be more appropriate? 14:19
14:19 kurahaupo left
lucasb Interesting, even with a empty environment "env -i /path/to/perl6 -e 'say %*ENV'", env still has PWD and SHLVL set 14:20
ah, perl6 is a shell script :) 14:21
invoking moar directly starts with a completely empty env 14:22
14:24 kktt joined, kktt left
pmurias well according to our specification it's not a Perl 6 if you start with a empty env ;) 14:24
timotimo no, our specification just says it has to make up a key, any key
lucasb well, someone should try if "env -i /path/to/moar [ --libpath=LIBPATH ] /path/to/perl6.moarvm -e 'say %*ENV'" fails that roast test :) 14:26
timotimo tbrowder: would you be interested in a perl 6 game of life that uses SDL2 instead of running inside of 6pad? 14:33
tbrowder yep (but don't know what SDL is for sure, SimpleDirectMedia?) 14:35
14:36 manjaro-user- left
pmurias tbrowder: yes 14:36
tbrowder timitimo: that would be great (i think, still reading about SDL) 14:37
14:41 kurahaupo joined
pmurias timotimo: looking through the irc logs it seems like 6pad has hang taking your code hostage :/ 14:41
14:42 p6bannerbot sets mode: +v kurahaupo
pmurias timotimo: how do you think making it preserve code on page reload would be good? 14:43
14:47 kktt joined 14:48 p6bannerbot sets mode: +v kktt
timotimo perhaps put everything in LocalStorage and offer a "history" kind of like an undo history? 14:51
14:51 curan left 14:53 pmurias left 14:55 pmurias joined, p6bannerbot sets mode: +v pmurias 15:00 pmurias left 15:03 SourceBaby joined, ChanServ sets mode: +v SourceBaby 15:04 p6bannerbot sets mode: +v SourceBaby, pmurias joined, p6bannerbot sets mode: +v pmurias
timotimo also, is there a way to not have the page unresponsive while 1) loading the perl6 javascript file and 2) compiling some perl6 code to js? 15:06
15:07 titsuki joined 15:08 p6bannerbot sets mode: +v titsuki 15:10 pmurias left, pmurias joined, p6bannerbot sets mode: +v pmurias
pmurias timotimo: I think there might be a way (by putting the actuall js compiler in an iframe) 15:11
15:11 rfold joined
pmurias timotimo: I have to think about (and experiment with that a bit) 15:11
timotimo: got to run& 15:12
15:12 p6bannerbot sets mode: +v rfold
Xliff Anyone seen this before? -- gist.github.com/Xliff/cba831252504...205437bd0b 15:12
15:12 rfold left, pmurias left
timotimo i wonder if it'd work better to put the compiler part into a web worker; functions are passed around "as strings" anyway in js, right? :P 15:14
15:19 graphene left 15:20 graphene joined 15:21 p6bannerbot sets mode: +v graphene 15:23 uzl joined 15:24 p6bannerbot sets mode: +v uzl
uzl Hello, #perl6! 15:26
yoleaux 04:07Z <Xliff> uzl: In your first example, the second comparison has a comment that should read "True, 220 and 284 are though." -- you had "28" rather than "284".
06:28Z <jmerelo> uzl: (just in case) It's mostly OK, but did you read the comments by Xliff? The title is OK. I might have used something like "Calling numbers names" "Or numbers by any other name" or something like that, but it's OK.
uzl Xliff: Thanks. I've fixed it! 15:27
.tell jmerelo I've gone with one of your titles. It's more subtle and sounds less pretentious ;-)! Feel free to put the article in reserve! 15:28
yoleaux uzl: I'll pass your message to jmerelo.
15:28 Sgeo_ left 15:32 uzl left 15:36 yqt left
Xliff Can someone tell me what it means when you get the following error: "Unknown element type in CArray" -- Is that a mismatched memory issue? 15:37
timotimo can you run the script under gdb? 15:38
Xliff Sure.
timotimo and "break CArray.c:331"
and then print repr_data[0]
Xliff Crap. I have to re-brew. Didn't remember debug 15:42
timotimo ah dang
i think it'd literally be no problem at all to have the default be --debug=3 or at the very least --debug=1 15:43
Xliff I know.
I keep forgetting I have an alias for that. So used to typing it out.
Doesn't take long, though.
Compile times are creeping up, again. 15:46
lizmat yeah, probably the new read-intX / write-intX methods 15:47
Xliff timotimo: Were you talking perl6-gdb-m? 15:49
timotimo yes 15:53
Xliff Every time I use 'perl6-gdb-m script args' I don't get the gdb prompt. Is there a way to pass commands to GDB? 15:54
Nevermind. Got it. 15:55
15:55 kurahaupo left
Xliff $1 = {elem_size = 8, elem_type = 0x555556d77588, elem_kind = 6} 15:55
timotimo that's a CUnion 16:00
Xliff Yep!
And I've had trouble with CUnions and CArray's before. You'd think I'd learn. 16:01
timotimo maybe it's enough to put a case for that where there's already cases for pointer, string, array etc such
Xliff CUnions are supported by NativeCall, so I would think they'd be good for CArray, yes? 16:02
timotimo well, yeah. just turns out somebody forgot to take care of them in CArray 16:04
Xliff D'oh 16:05
timotimo make_wrapper will also need a bit of code
Xliff Oh...wow. 16:06
timotimo but there's also a MVM_nativecall_make_cunion
Xliff OK, want me to make an issue? 16:07
timotimo i thought maybe you could make a patch :D 16:08
Xliff LOL!
While I am looking at the relevant parts of the code, I'd have no idea what to do.
This for make_wrapper: 16:10
case MVM_CARRAY_ELEM_KIND_CUNION:
return MVM_nativecall_make_cunion(tc, repr_data->elem_type, data);
?
16:11 llfourn left 16:12 zacts joined, p6bannerbot sets mode: +v zacts
timotimo i think so 16:12
Xliff paste.ee/p/XgQOK 16:16
16:16 llfourn joined 16:17 p6bannerbot sets mode: +v llfourn
timotimo looks good; does it seem to work? 16:19
AlexDaniel nnnnnnooooooooooooooooo github
my vertical space :(
:O and now it's gone 16:20
Kaiepi what happened to github?
scimon So 6.d lets me throw promises at it like crazy.
AlexDaniel they added an extra bar to the top of the screen with the issue title 16:21
but after refreshing the page it seems to be gone… weird
16:21 robertle left
scimon Making 4000 promises to read data files, throwing them into an array and then awaiting the lot. Just. Works :) 16:21
Kaiepi in a chat bot i'm writing there's a timeout on sending messages
AlexDaniel scimon: I know! That's how Blin works actually
Kaiepi so i have a send-bulk method that uses a lazy for to do Promise.in(atomic-inc-fetch $i).then({ self.send: $data }) and awaits it 16:22
lazy for is crazy useful 16:23
AlexDaniel scimon: basically I create a Promise for each module, and then there's a react block with as many `whenever`s as there are modules :)
16:23 jmerelo joined
AlexDaniel scimon: github.com/perl6/Blin/blob/master/...in.p6#L285 :) 16:23
16:24 p6bannerbot sets mode: +v jmerelo
Xliff timotimo: Let me see. 16:26
How can I force rebuild all of rakudo? 16:37
lizmat touch any of the files in src/core 16:38
scimon Neat.
Geth doc: 44ba9e8347 | (Elizabeth Mattijsen)++ | doc/Type/Endian.pod6
Introducing the Endian enum
16:42
doc: acbc324427 | (Elizabeth Mattijsen)++ | doc/Type/Blob.pod6
First stab at documenting new blob8.read- methods
doc: cd33e48117 | (JJ Merelo)++ | doc/Language/variables.pod6
Improves and debugs description, refs #2510
16:47
jmerelo lizmat++ ^^^
yoleaux 15:28Z <uzl> jmerelo: I've gone with one of your titles. It's more subtle and sounds less pretentious ;-)! Feel free to put the article in reserve!
jmerelo .tell uzl thanks! 16:48
yoleaux jmerelo: I'll pass your message to uzl.
16:56 domidumont joined
tobs` I'm doing something like this: » S:g['1'] = @patch[$i++] with $data « where I replace all 1's in $data with the elements of @patch in order. That works with a "my $i = 0" in the function but obviously won't when I use the anonymous state variable instead of $i. 16:56
I wonder if I can somehow have $ reset each time the function is entered but not reset while that particular line is executed. 16:57
16:57 p6bannerbot sets mode: +v domidumont, abraxxa left
AlexDaniel tobs`: so what's wrong with `my $i = 0`? :) 16:58
tobs` n-nothing
I thought "now is the perfect chance to use $++" but once again it wasn't 17:00
Xliff timotimo: OK. Segfaulting when I try to access the CUnion.
So there may still be something missing.
tobs` m: sub f { say $++ }; f; f; f; sub g { say do { $++ } }; g; g; g 17:02
camelia 0
1
2
0
0
0
tobs` hehe
AlexDaniel that looks correct
tobs` oh, but it resets on every evaluation of the do block, so I can't use that as an index. $i it is then. 17:04
jmerelo tobs`: blocks don't have state. Routines do, I guess. 17:05
m: sub f { say $++ }; f; f; f; sub g { say do -> { $++ } }; g; g; g
camelia 0
1
2
-> { #`(Block|58873200) ... }
-> { #`(Block|58873416) ... }
-> { #`(Block|58873488) ... }
jmerelo m: sub f { say $++ }; f; f; f; sub g { say -> { $++ } }; g; g; g 17:06
camelia 0
1
2
-> { #`(Block|61371048) ... }
-> { #`(Block|61371264) ... }
-> { #`(Block|61371336) ... }
jmerelo m: sub f { say $++ }; f; f; f; sub g { say { -> { $++ } }}; g; g; g
camelia 0
1
2
-> ;; $_? is raw { #`(Block|74260232) ... }
-> ;; $_? is raw { #`(Block|74522624) ... }
-> ;; $_? is raw { #`(Block|74522696) ... }
jmerelo aw, never mind.
Did you know you can try StackOverflow? Please do. :-)
m: sub f { say $++ }; f; f; f; sub g { -> { $++ } }; say g; say g; say g 17:07
camelia 0
1
2
-> { #`(Block|73077112) ... }
-> { #`(Block|73077328) ... }
-> { #`(Block|73077400) ... }
tobs` m: sub f { say $++ }; f; f; f; sub g { say { -> { $++ }() }}; g; g; g
camelia 0
1
2
-> ;; $_? is raw { #`(Block|79938208) ... }
-> ;; $_? is raw { #`(Block|79938424) ... }
-> ;; $_? is raw { #`(Block|79938496) ... }
tobs` m: sub f { say $++ }; f; f; f; sub g { say -> { $++ }() }; g; g; g 17:08
camelia 0
1
2
0
0
0
jmerelo tobs`: so Callables don't keep state either. It needs to be a routine.
tobs`: hum, but in that case the block is created in every call... 17:09
lizmat m: my $a = { say $++ }; $a() for ^10 # jmerelo: I don't think so ?
camelia 0
1
2
3
4
5
6
7
8
9
jmerelo lizmat: right. 17:10
lizmat++
tobs`: the problem is that you're creating the do block every time you call g, and $ is always lexically scoped. 17:11
tobs` What I was trying to do is get a new block in each invocation of the function, which then keeps the same state during my S:g
jmerelo tobs`: no can do. New block initializes state, unless you use caller state, which is probably not what you're looking for. 17:12
xlat m: (my $b=buf8.allocate(10)).contents = "foo!".encode.list; say $b;
camelia Cannot unbox a type object (Nil) to int.
in block <unit> at <tmp> line 1
xlat m: try (my $b=buf8.allocate(10)).contents = "foo!".encode.list; say $b; 17:13
camelia Buf[uint8]:0x<66 6F 6F 21 00 00 00 00 00 00>
xlat m: (my $b=buf8.allocate(4)).contents = "foo!".encode.list; say $b; 17:14
camelia Buf[uint8]:0x<66 6F 6F 21>
jmerelo tobs`: anyway. Try StackOverflow, really. We're reaching 900 questions... stackoverflow.com/questions/tagged/perl6 And someone who's not right here right now might see it and solve it.
There are a bunch of unanswered questions there, also. For instance, this one on using certfp for authenticating IRC bots by tyil stackoverflow.com/questions/536925...-ircclient 17:15
17:16 graphene left 17:17 zacts left 17:18 graphene joined 17:19 p6bannerbot sets mode: +v graphene 17:21 dakkar left 17:26 kensanata left 17:27 scimon left 17:35 |oLa| left 17:37 vrurg left 17:38 graphene left 17:40 graphene joined, zacts joined, p6bannerbot sets mode: +v zacts 17:41 p6bannerbot sets mode: +v graphene 17:45 lucasb left 17:54 c1nil left 18:03 jmerelo left 18:06 lucasb joined, p6bannerbot sets mode: +v lucasb 18:09 Sigfrid joined 18:10 p6bannerbot sets mode: +v Sigfrid 18:11 graphene left 18:13 graphene joined, p6bannerbot sets mode: +v graphene 18:25 sauvin left 18:37 tobs` left 18:46 pecastro joined 18:47 p6bannerbot sets mode: +v pecastro 18:55 pmurias joined, p6bannerbot sets mode: +v pmurias 18:57 zakharyas left
pmurias timotimo: functions are not passed around as strings in js 19:20
timotimo: the CORE setting is super heavy to load so the compiler and "executor" need to loaded once and together 19:21
El_Che It looks like Go is getting a CPAN like infra: www.prnewswire.com/news-releases/j...64117.html 19:23
xinming When I use something like perl6 -Ilib test.p6 the test.p6 only contains the simple use Module::Name:from<Perl5> Why rakudo can't find the perl5 module? 19:27
pmurias xinming: I don't understand the question 19:28
xinming: do you have a problem with rakudo not finding your perl 5 module? 19:29
xinming yes 19:30
hmm, seems the @INC is not changed
use lib doesn't change the @INC
pmurias xinming: maybe the Perl 6 and Perl 5 INC paths are not shared (I didn't check)?
xinming pmurias: I think I know the reason, the Inline::Perl5 doesn't use the value in perl6. so use lib 'lib'; in test.p6 doesn't work as expected. 19:33
but something like PERL5LIB="lib" perl6 test.p6 worked.
I think use lib 'lib'; won't affect Inline::Perl5 module. 19:34
lizmat Inline::Perl5 is usually installed: "use lib" is intended to be used for not installed modules only 19:37
19:41 Sigfrid left, Sigfrid joined 19:42 p6bannerbot sets mode: +v Sigfrid 19:44 sergot joined 19:45 p6bannerbot sets mode: +v sergot 19:47 zacts left
b2gills xinming: Perhaps `use lib:from<Perl5> 'lib'; useModule::Name:from<Perl5>` ? 19:48
lizmat use Inline::Perl5; %*ENV<PERL5LIB> = "."; use Foo:from<Perl5> # to load a ./Foo.pm works for me 19:51
hmmm... without it as well... :-(
please disregard ^^^ 19:53
19:56 domidumont left
sena_kun m: class Wrap { has $.a; }; class A is Set {}; say A.new(Wrap.new(a => 1)) eqv A.new(Wrap.new(a => 1)); 19:56
camelia False
sena_kun how do I fix this? I see docs mention WHICH overloading, but it isn't even called when defined in `Wrap`. 19:57
hmmm, in my tiny example WHICH is called... 19:58
sena_kun tries again
masak question: can someone define "closure" in a simple way?
(I know what it is, I'm just looking for simple ways to describe it) 19:59
sena_kun masak, piece of code + data necessary to execute it?
that's probably the simplest I can get, but it is a description of a lot of different things.
El_Che a function that may references variables in the surrounding scope? 20:00
sena_kun "a code block" will be a bit more precise(while being more general, yes), won't it? 20:01
20:02 Sigfrid left
El_Che throw anonymous somewhere 20:02
in
masak "a closure is a function that uses variables/names defined outside of it"
...maybe 20:03
lizmat s/function/Callable/ ?
sena_kun if you don't want to introduce "lexical" word, I think.
El_Che anonymous = can be defined as a variable on a scope
Geth doc: 98f3faa6dd | (Elizabeth Mattijsen)++ | doc/Type/Kernel.pod6
Document Kernel.Endian
masak lizmat: I think "function" is more precise than "Callable", actually. a Callable doesn't need to be a block of code, even. just something that can be called. 20:04
lizmat m: dd WhateverCode ~~ Callable # I guess that's true, as WhateverCode is guaranteed to not be a closure 20:05
camelia Bool::True
masak right, good example
lizmat hmmm... or is it ? hmmm
masak not in my book, no :)
El_Che are loop constructions a kind of closures in p6? or not related at all?
masak could you be more specific about what you're asking? 20:06
lizmat m: my $a = 666; sub a() { * - $a }; dd a.(42) # WhateverCode with closure ? 20:07
camelia -624
masak it's a WhateverCode _in_ a closure :)
El_Che for @foo -> $foo { say "block $foo" }
lizmat the $a is used inside the code
El_Che block accesses outside variable
masak El_Che: it's only an "outside variable" visually. it's actually just a parameter to the block. 20:08
El_Che masak: ah, yes, I remember now.
thx
masak or, perhaps better said, the block begins already at the `->` :)
(well, there's the _block_, and then there's the _block_ block) :P 20:09
El_Che func() { ... }("parameter") in other langs :)
block block - who is it? - not a closure
masak :P 20:10
actually, your string "parameter" is an argument :)
El_Che that's a good argument, there
masak well, not to argue, but... 20:11
masak .oO( ...I arguee ) 20:12
TreyHarris Oops, I idiotically did a git pull before saving changes to a file--and that file's been edited by someone else since my last pull. Nowhere conflicting, though. I can copy the entire section I modified, revert, and paste it back in... but I feel like my mind's blanking on a better way to handle this
(Er, sections; one above and one below the part the other commit changed. Otherwise this would be easy-peasy.) 20:13
masak TreyHarris: "Save As", check out your pre-pull commit, commit, go back to tip, cherry-pick?
TreyHarris masak: yep, exactly. thanks. (I'm using Magit, so that's very easy.) 20:14
masak \o/
TreyHarris Just had a brain-block
masak I was wondering what IDE that'd be that didn't refresh the files from disk automatically when they changed :)
still waiting for the editor that makes Git the inherent saving metaphor and abstracts away the disk itself 20:15
20:18 kensanata joined, p6bannerbot sets mode: +v kensanata
TreyHarris masak: no, it was my own idiocy--it was my first pull since I'd created this feature branch and I'd forgotten to set the upstream--something that I know I can do with Magit but is faster on the command line, so I did it in othe command line. So Magit didn't say "whoah, there, buddy" 20:21
20:28 andrzejku_ joined 20:29 p6bannerbot sets mode: +v andrzejku_ 20:30 coet joined, p6bannerbot sets mode: +v coet 20:31 andrzejku_ left 20:33 lichtkind joined 20:36 lichtkind left, lichtkind joined 20:38 lichtkind left, lichtkind joined 20:39 p6bannerbot sets mode: +v lichtkind
lichtkind p6: say <a b c> ~~ "a" 20:41
camelia False 20:42
lichtkind why?
p6: say [<a b c>] ~~ "a"
camelia False
lichtkind p6: say <a b c>.Set ~~ "a"
camelia False
gfldex a list of Str is not a Str
lichtkind p6: say (1 2 3) ~~ 3
camelia 5===SORRY!5=== Error while compiling <tmp>
Two terms in a row
at <tmp>:1
------> 3say (17⏏5 2 3) ~~ 3
expecting any of:
infix
infix stopper
statement end
statement modifier
statem…
lichtkind p6: say (1..3) ~~ 3 20:43
camelia True
lichtkind list on int is not an int
p6: say (1,2,3) ~~ 3
camelia True
lucasb you want (elem) 20:44
lichtkind lucasb, yes and i got it , but this seems to be inconsitant
pmurias masak: re git editor wouldn't that create horrible commit histories?
gfldex ~~ is not the most consistant operator we got indeed 20:45
lucasb lichtkind: ah, sorry. I didn't realize you're showing an problem in P6
lichtkind lucasb, you just rying to be helpful - all good 20:46
TreyHarris I thought there was a way to stick ":skip" or suchlike into "subtest" to get the entire subtest skipped, rather than having to count the plan of the subtest and skip that number? But I can't find it. 20:47
tobs lichtkind: the reason is (1..3).Int is 3 (the length of the list) whereas <a b c>.Str is not "a" 20:52
lichtkind p6: say (1,2,3) ~~ 2
camelia False 20:53
tobs m: say <a b c> ~~ "a b c"
camelia True
lichtkind indeed
thank you tobs
this not an smart match i imagined anymore
but at least consistant :) 20:54
20:54 pmurias left, pmurias joined, p6bannerbot sets mode: +v pmurias
TreyHarris m: say so <a b c>.contains('a b') 20:58
camelia True
TreyHarris m: say so <a b c> (cont) 'a'; say so <a b c> (cont) 'a b' 20:59
camelia True
False
TreyHarris I forgot until this moment that `contains` is a Str operation, not a container one
21:04 yqt joined, p6bannerbot sets mode: +v yqt
Kaiepi wait it's a Str and not a List/Array one? 21:07
fuck
gfldex m: say <a b c> eq "a"; # <-- thats what happens inside Str.ACCEPTS 21:12
camelia False
Kaiepi what's the List/Array method for checking if something exists inside an array? 21:16
(cont)?
gfldex m: say so <a b>».contains('a b'); # that's a nice riddle :) 21:17
camelia True
gfldex Kaiepi: You use a set operator. They coerce to Set and do what you expect. see: docs.perl6.org/language/setbagmix 21:18
tobs Kaiepi: (cont) will turn the array into a set. You can also use .first
Kaiepi ah perfect
thanks
21:19 zakharyas joined 21:20 p6bannerbot sets mode: +v zakharyas 21:22 claris3 joined, claris3 left, jast left, kst`` joined, kst` left 21:23 p6bannerbot sets mode: +v kst`` 21:25 jast joined 21:26 p6bannerbot sets mode: +v jast 21:40 zakharyas left 21:52 Sigfrid joined, p6bannerbot sets mode: +v Sigfrid 21:53 xlat left 21:55 kensanata left 21:58 lucasb_ joined 21:59 p6bannerbot sets mode: +v lucasb_ 22:04 kurahaupo joined, lizmat left 22:05 p6bannerbot sets mode: +v kurahaupo
sena_kun new advent post is here. \o/ 22:11
22:14 Sigfrid left 22:15 lucasb_ left 22:22 pnu___ joined, p6bannerbot sets mode: +v pnu___ 22:25 lizmat joined, p6bannerbot sets mode: +v lizmat, eiro1 joined, hoelzro joined 22:26 chsanch_ joined, hahainte1net joined, Ulti_ joined, ponbiki_ joined, p6bannerbot sets mode: +v eiro1, p6bannerbot sets mode: +v hoelzro, p6bannerbot sets mode: +v chsanch_, p6bannerbot sets mode: +v hahainte1net
Geth doc: 47847ccd0c | (Elizabeth Mattijsen)++ | doc/Type/Kernel.pod6
Kernel.Endian to be called .endian
22:27
22:27 p6bannerbot sets mode: +v Ulti_, p6bannerbot sets mode: +v ponbiki_ 22:28 charsbar_ joined, Garland_g[m]1 joined, p6bannerbot sets mode: +v Garland_g[m]1 22:29 S007 joined, p6bannerbot sets mode: +v S007, holyghost left, spacebat1 left, eiro left, Garland_g[m] left, Demos[m] left, charsbar_ is now known as charsbar, pnu___ is now known as pnu__, p6bannerbot sets mode: +v charsbar 22:30 Sigfrid joined, alpha6 joined, p6bannerbot sets mode: +v Sigfrid 22:31 Demos[m] joined, p6bannerbot sets mode: +v Demos[m], p6bannerbot sets mode: +v alpha6, spacebat1 joined, john_parr left, andrewalker left 22:32 p6bannerbot sets mode: +v spacebat1, john_parr joined 22:33 p6bannerbot sets mode: +v john_parr, irdr left 22:34 irdr joined 22:35 p6bannerbot sets mode: +v irdr 22:36 andrewalker joined 22:37 ponbiki_ left, ponbiki joined, p6bannerbot sets mode: +v andrewalker 22:38 p6bannerbot sets mode: +v ponbiki 23:06 Sgeo_ joined 23:07 p6bannerbot sets mode: +v Sgeo_ 23:08 graphene left 23:10 graphene joined, p6bannerbot sets mode: +v graphene 23:11 epony left
buggable New CPAN upload: Chart-Gnuplot-0.0.9.tar.gz by TITSUKI modules.perl6.org/dist/Chart::Gnupl...an:TITSUKI 23:13
23:15 yqt left 23:27 coet left 23:29 vrurg joined, p6bannerbot sets mode: +v vrurg
buggable New CPAN upload: Chart-Gnuplot-0.0.10.tar.gz by TITSUKI modules.perl6.org/dist/Chart::Gnupl...an:TITSUKI 23:33
23:36 pmurias left 23:43 cpage_ joined, pecastro left, p6bannerbot sets mode: +v cpage_ 23:45 cpage left, cpage_ is now known as cpage 23:46 lucasb left 23:47 zacts joined, p6bannerbot sets mode: +v zacts 23:51 zacts left 23:56 sena_kun left
Xliff Is there a way to tell a CArray that it has a certain number of elements (since it was returned with a C-Struct?) 23:57
I am trying to resolve this error: "Don't know how many elements a C array returned from a library"