»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend! Set by moritz on 22 December 2015. |
|||
00:00
pierre_ joined,
kurahaupo left,
obfusk joined
|
|||
viki | context: advent theme :) | 00:01 | |
AlexDaniel | viki: is there any way to add santa camelia logo? | 00:03 | |
00:07
effbiai left
00:10
canopus left
|
|||
viki | Oh, right, forgot about that | 00:12 | |
She ruins the sexy! | 00:13 | ||
AlexDaniel | looks great | ||
viki | Yeah? | ||
OK then :) | 00:14 | ||
00:16
espadrine_ left
00:19
canopus joined
00:27
adu joined
|
|||
AlexDaniel | viki: to be honest, #222 looks better than #555 :P | 00:27 | |
viki | We can't change stuff like that | 00:28 | |
AlexDaniel | :'( | 00:29 | |
u: CRY | 00:32 | ||
unicodable6 | AlexDaniel, U+1A7F TAI THAM COMBINING CRYPTOGRAMMIC DOT [Mn] (◌᩿) | ||
AlexDaniel, U+2CB6 COPTIC CAPITAL LETTER CRYPTOGRAMMIC EIE [Lu] (Ⲷ) | |||
AlexDaniel, U+2CB7 COPTIC SMALL LETTER CRYPTOGRAMMIC EIE [Ll] (ⲷ) | |||
AlexDaniel | u: CRY FACE | 00:33 | |
unicodable6 | AlexDaniel, gist.github.com/1eeff9ae31c3692fef...a4dc12f1ec | ||
AlexDaniel, U+1F622 CRYING FACE [So] (😢) | |||
AlexDaniel, U+1F62D LOUDLY CRYING FACE [So] (😭) | |||
AlexDaniel, U+1F63F CRYING CAT FACE [So] (😿) | |||
00:38
wamba left
00:40
adu left
00:42
vendethiel left
00:43
seatek joined,
vendethiel joined
00:46
rindolf left
|
|||
yoleaux | AlexDaniel: submit weird <--Inf++Inf\i> edge cases as roast tests | 00:49 | |
AlexDaniel | alright | ||
viki | :) | 00:50 | |
00:51
rindolf joined
|
|||
viki | huggable: advent | 00:52 | |
huggable | viki, github.com/perl6/mu/blob/master/mi...6/schedule | ||
AlexDaniel | viki: it looks a bit too empty | 00:54 | |
00:55
rindolf left
|
|||
samcv | why is it called Rakudo 'blead' why spelled this way? does it mean something special? | 00:55 | |
viki | mst told me once, but I forgot | 00:56 | |
16:14 mst iBakeCake: because that's been the perl tradition forever | 00:57 | ||
16:15 I believe it's because that branch is the bleading edge | |||
TimToady | at some point "the bleeding edge" was misspelled in Perl 5 culture | ||
and it stuck | |||
viki | heh | ||
samcv | that's not how you spell bleeding tho | ||
geekosaur | 2016 Oct 21 16:14:57 <mst>iBakeCake: because that's been the perl tradition forever | ||
2016 Oct 21 16:15:19 <mst>I believe it's because that branch is the bleading edge | |||
samcv | hah i see TimToady | ||
geekosaur | right, but bleeding edge is itself a pun on leading edge | ||
and I see viki found their log first, o well | 00:58 | ||
samcv | i was pretty sure it was refering to blades, like the bleeding edge the edge that is sharp and causes bleeding etc | 00:59 | |
geekosaur | that is where the original pun came from | ||
samcv | but i guess. the perl version could be leading? | ||
geekosaur | the leading edge of development is sharp and can cut you... | ||
so this is kinda trending back toward the original without losing the pun completely | 01:00 | ||
samcv | well i mean there's also cutting edge as well. | 01:01 | |
dalek | : 8977b19 | (Zoffix Znet)++ | misc/perl6advent-2016/schedule: Claim Dec 7 For "Subset In Your Ways: How To Make, Use, And Abuse Perl 6 Subsets" |
||
AlexDaniel | viki: wait, um | ||
viki | ? | ||
AlexDaniel | m: dd <0-1i> | ||
camelia | rakudo-moar 843a6b: OUTPUT«<0-1i>» | ||
AlexDaniel | m: dd <-0-1i> | ||
camelia | rakudo-moar 843a6b: OUTPUT«<-0-1i>» | ||
samcv | “Cutting edge” actually preceded “leading edge,” first appearing in a literal sense (the sharp edge of a knife or other cutting implement) in the early 19th century. The modern figurative use appeared in the mid-1800s, and is defined by the Oxford English Dictionary (OED) as “A dynamic, invigorating, or incisive factor or quality, especially one that delivers a decisive advantage. | ||
AlexDaniel | is it supposed to be this way? | ||
samcv | what would be the bleating edge ;P ( bleating like sheep) | 01:02 | |
MasterDuke | m: sub a($bbb) { $bbb = 1 }; a(2) | 01:03 | |
yoleaux | 29 Nov 2016 21:35Z <AlexDaniel> MasterDuke: tests? | ||
camelia | rakudo-moar 843a6b: OUTPUT«Cannot assign to a readonly variable or a value in sub a at <tmp> line 1 in block <unit> at <tmp> line 1» | ||
01:03
aborazmeh joined,
aborazmeh left,
aborazmeh joined
|
|||
viki | AlexDaniel: well, Complex's parts are nums and nums can do -0... | 01:03 | |
AlexDaniel | oh, well… okay then? | ||
MasterDuke | huh, i thought camelia got new commits pretty quickly? | 01:04 | |
AlexDaniel | eval: sub a($bbb) { $bbb = 1 }; a(2) | ||
evalable6 | AlexDaniel, rakudo-moar 3800e99: OUTPUT«(exit code 1) Cannot assign to a readonly variable ($bbb) or a value in sub a at /tmp/YfAjRms_iG line 1 in block <unit> at /tmp/YfAjRms_iG line 1» | ||
AlexDaniel | whateverable has a 10 minute delay tops | ||
MasterDuke | eval: use Test; throws-like {sub a($bbb){$bbb=1};a(2)}, X::AdHoc, message => /bbb/ | ||
evalable6 | MasterDuke, rakudo-moar 3800e99: OUTPUT«(exit code 1) 1..3 ok 1 - code dies ok 2 - right exception type (X::AdHoc) not…» | ||
MasterDuke, Full output: gist.github.com/c9185a4f3e6aef9b6a...d4396b10c8 | |||
lucs | Jack Reeves (C++ guy) started using "(B)Leading Edge" (pun intended) in the mid 90s. | 01:05 | |
AlexDaniel | hmmm seems like camelia is stuck on that commit for some reason | ||
MasterDuke | the error i get from the throws-like is from src/6model/containers.c in MoarVM | ||
viki | m: dd -0-1i | 01:06 | |
camelia | rakudo-moar 843a6b: OUTPUT«<0-1i>» | ||
MasterDuke | eval: use MONKEY; EVAL '{sub a($bbb){$bbb=1};a(2)}' | ||
evalable6 | MasterDuke, rakudo-moar 3800e99: OUTPUT«(exit code 1) Cannot assign to an immutable value in block <unit> at EVAL_0 line 1 in block <unit> at /tmp/ppYC9W505M line 1» | ||
viki | m: dd -0e0-1i | ||
camelia | rakudo-moar 843a6b: OUTPUT«<-0-1i>» | ||
viki | AlexDaniel: yeah, it's OK. | 01:07 | |
AlexDaniel: FWIW, I have a separate file in roast for all the negative zero stuff | |||
like... I'm still hunting/fixing cases where we don't handle it well | |||
m: dd "\x[2212]0".Num | |||
camelia | rakudo-moar 843a6b: OUTPUT«-0e0» | ||
viki | m: dd sprintf "%f", -0e0 | 01:08 | |
camelia | rakudo-moar 843a6b: OUTPUT«"-0.000000"» | ||
viki | m: dd "\x[2212]0".parse-base: 10 | 01:09 | |
camelia | rakudo-moar 843a6b: OUTPUT«0» | ||
MasterDuke | locally i get 'Cannot assign to a readonly variable ($bbb) or a value', when running that EVAL | ||
viki | m: dd "\x[2212]0e0".parse-base: 10 | ||
camelia | rakudo-moar 843a6b: OUTPUT«Failure.new(exception => X::Syntax::Number::InvalidCharacter.new(radix => 10, str => "0e0", filename => Any, pos => 2, line => Any, column => Any, modules => [], is-compile-time => Bool::False, pre => Any, post => Any, highexpect => []), backtrace => Backt…» | ||
viki | hm | 01:10 | |
01:10
zakharyas joined
|
|||
MasterDuke | oh wait | 01:10 | |
eval: use MONKEY; EVAL q|sub a($b){$b=1};a(2);CATCH{say .WHAT.gist}| | |||
evalable6 | MasterDuke, rakudo-moar 3800e99: OUTPUT«(exit code 1) (AdHoc)Cannot assign to a readonly variable ($b) or a value in sub a at EVAL_0 line 1 in block <unit> at EVAL_0 line 1 in block <unit> at /tmp/FuPkvclSSs line 1» | ||
viki | AlexDaniel: I have another gift :) | 01:12 | |
AlexDaniel | oh no… | ||
viki | m: say :10('0e0') | ||
camelia | rakudo-moar 843a6b: OUTPUT«0» | ||
viki | m: say :10<0e0> | ||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Couldn't process entire number: 1/3 int chars, 2/-1 fractional charsat <tmp>:1------> 3say :10<0e0>7⏏5<EOL>» | ||
MasterDuke | eval: use Test; throws-like {sub a($bbb){$bbb=1};a(2);CATCH{}}, X::AdHoc, message => /bbb/ | ||
viki | :) | ||
evalable6 | MasterDuke, rakudo-moar 3800e99: OUTPUT« 1..3 ok 1 - code dies ok 2 - right exception type (X::AdHoc) ok 3 - .message matches /bbb/ok 1 - did we throws-like X::AdHoc?» | ||
MasterDuke | interesting, just sticking that CATCH{} made it the right error | 01:13 | |
01:13
pierre_ left
|
|||
MasterDuke | * just sticking that CATCH{} in there | 01:13 | |
AlexDaniel | viki: hmmmmmmmmm | ||
this looks familiar | |||
viki: rt.perl.org/Ticket/Display.html?id=128804 | |||
:P | 01:14 | ||
m: say :35<lizmat> | |||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Couldn't process entire number: 2/6 int chars, 2/-1 fractional charsat <tmp>:1------> 3say :35<lizmat>7⏏5<EOL>» | ||
01:14
dataf3l_ left
|
|||
viki | AlexDaniel: but how come it works in :10('0e0') form? I thought the two were equivalent | 01:14 | |
AlexDaniel | ah, wtf | ||
O_o | |||
viki | :) | 01:15 | |
AlexDaniel | m: say :35('lizmat') | ||
camelia | rakudo-moar 843a6b: OUTPUT«Cannot convert string to number: malformed ':35' style radix number, expecting '>' after the body in '3:35<li⏏5zmat>' (indicated by ⏏) in block <unit> at <tmp> line 1» | ||
01:15
dataf4l left
|
|||
viki | hah | 01:15 | |
AlexDaniel | well, that's a nice error message | ||
seatek | if error messages get sufficiently good, there's little reason they shouldn't correct the error for you :) | 01:16 | |
viki | seatek: hah, I often think that about some of the errors. | ||
geekosaur thinks back to watfiv and shudders | |||
AlexDaniel | which is a very common idea actually | ||
and the typical response is “GREAT! Write a module!” | 01:17 | ||
seatek | it would be interesting trying to determine where to draw the lines, at assuming you know better :) | ||
might have to implement a danger scale on run | 01:18 | ||
dalek | : cf89606 | (Zoffix Znet)++ | misc/perl6advent-2016/schedule: Fix name |
01:19 | |
01:19
pierre_ joined
|
|||
seatek | much of that thinking must go on with perl anyway, as it parses with its many ways of figuring out what people may have meant | 01:20 | |
so at what point does it actually become an error | |||
i hadn't really thought of that before | |||
TimToady | The problem with a compiler that guesses right most of the time is what happens when it doesn't. :) | 01:23 | |
01:23
pierre_ left
|
|||
geekosaur | hence my shudder about WATFIV | 01:24 | |
first commercial compiler to do such on the fly correction. when it worked it was great, but when it was wrong, oh was it ever WRONG | |||
...and this in a language that was simple enough that such guessing was much easier than it would be in perl (any version) | 01:25 | ||
AlexDaniel | well, it does not have to be fully autonomous | 01:27 | |
seatek | that's what the danger slider is for :) | ||
AlexDaniel | just a simple question “Want me to change it to 「………」 [Y/n]” will do | ||
01:27
dontbe^2 joined
|
|||
seatek | maybe we could send all uncertain assumptions to google in real time and let deep learing answers come back, like those spooky dream pictures | 01:29 | |
might be interesting on global financial market data | 01:30 | ||
01:36
pierre_ joined
|
|||
AlexDaniel | .in 1d go through clog and see if there are any other < > cases that are obviously wrong | 01:38 | |
yoleaux | AlexDaniel: I'll remind you on 1 Dec 2016 01:38Z | ||
01:38
Vynce left
01:40
cdg left
|
|||
TimToady | .oO("Hello Dave, you appear to be terminating the wrong entity; fix it for you? [Y/n]") |
02:09 | |
.oO("Hello Dave, you appear to be terminating the wrong entity; fix it for you? [Y/y]") |
02:10 | ||
AlexDaniel | Y | 02:15 | |
Y | 02:18 | ||
02:19
pierre_ left,
kalkin- left,
kalkin-_ joined
02:20
geekosaur left
02:22
geekosaur joined
02:25
pierre_ joined
02:29
pierre_ left,
pierre_ joined
02:38
pierre_ left
02:41
leego left
02:44
dataf3l_ joined,
dataf4l joined,
pierre_ joined
02:45
ilbot3 left
02:47
ilbot3 joined
02:48
pierre_ left
02:50
leego joined
02:55
BenGoldberg joined
03:07
pierre_ joined
03:09
rpburkholder left,
Guest42590 joined
03:13
Guest42590 left
03:15
Vynce joined
03:22
noganex joined
03:25
noganex_ left
03:33
aborazmeh left
03:40
avalokite joined
03:44
chris2 left
03:47
chris2 joined
03:57
avalokite left
04:05
pierre_ left
04:11
pierre_ joined
04:15
Vynce left
04:16
pierre_ left
04:17
pierre_ joined,
b7j0c joined
|
|||
b7j0c | so I recently stumbled upon the "is pure" annotation for subroutines...how meaningful is this given perl6's strong support for powerful exceptions? | 04:18 | |
I realize "is pure" is probably just ignored now...but it seems an odd claim to make in perl6 that subs can be side-effect free | 04:19 | ||
04:21
pierre_ left
04:22
pierre_ joined
|
|||
ZzZombo | why" | 04:25 | |
?* | |||
sub x is pure {put 'x'} | |||
04:28
dataf4l left,
dataf3l_ left
|
|||
b7j0c | but thats just an expression. if you take a parameter, you have to assume it can carry an exception | 04:29 | |
perl6 doesn't complain when i attach "is pure" to functions that throw exceptions, for example | 04:30 | ||
how can a sub be "pure" if it doesn't even return a value of its signature? | 04:31 | ||
04:32
pierre_ left
|
|||
b7j0c | almost seems to be begging a "noexcept" annotation a la c++ | 04:33 | |
04:34
adu joined
04:36
dataf4l joined,
dataf3l joined
04:41
pierre_ joined
04:46
pierre_ left
05:02
khw left
05:06
adu left
|
|||
b7j0c | actually, even "put 'x'" is not "pure" | 05:07 | |
TimToady | the primary purpose of 'is pure' is to tell the compiler that it is allowed to do constant folding with it | 05:13 | |
it is an assertion that any given set of arguments will always produce the same result | 05:16 | ||
secondarily, we can report "Useless use" of any pure function in sink context, since the only reason to call any function in sink context is for side effects | 05:17 | ||
b7j0c | so should "is pure" cause the runtime to fail if I do something like get the time-of-day in a sub and do something with it? | 05:18 | |
TimToady | 'is pure' is not for adding any kind of type checking | 05:19 | |
it is not an instruction to check anything | |||
b7j0c | I guess I can't figure out if it is a promise I am supposed to be making to the runtime or the runtime to me..or what are the implications of lying | 05:20 | |
TimToady | it is merely an assertion of something you already know to be true, and if you put it on non-pure functions, it's your own fault :) | ||
it's merely an assertion to the compiler that there are no side effects, nor is there any internal state that would cause the function to be non-idempotent | 05:21 | ||
hence it is safe to assume we can call it once at compile time to do constant folding when we know the arguments are known at compile time | 05:22 | ||
b7j0c | feels more like "can memoize" than "is pure" | ||
if i ask the runtime to memoize a function result and then I end up blowing my own foot off, its on me | |||
TimToady | memoizing has additional run-time ramifications, especially for types that are not value types | 05:24 | |
but yes, pure is a kind of subset of that, as we use it | |||
b7j0c | cool, thanks for the clarification | ||
TimToady | another slight difference is that it's pretty much always a win to do constant folding on a pure function, but the benefit of memoizing depends critically on usage patterns, since a cache does you no good if you never repeat a calculation | 05:28 | |
and if you limit the size of the cache, you lose the benefit if it does not repeat often enough | 05:29 | ||
which is why we've had a separate 'is cached' that we've played with from time to time | 05:30 | ||
05:32
skids left
|
|||
seatek | well, tonight's rabbit hole has been junctions. going to map a new unicode character as a momento | 05:42 | |
05:46
mohae_ left
05:53
kalkin-_ left,
kalkin- joined
05:57
japhb left
05:59
japhb joined,
rindolf joined
06:02
b7j0c left,
Cabanossi left
06:03
Cabanossi joined,
effbiai joined,
effbiai left,
effbiai joined
06:12
eisen74 joined
06:18
pierre_ joined
06:23
japhb left
06:25
BenGoldberg left,
japhb joined
06:29
canopus left
06:32
canopus joined
06:34
_28_ria left,
girafe left
06:37
wamba joined,
domidumont joined
06:39
_28_ria joined
06:40
domidumont left
06:44
CIAvash joined
06:49
RabidGravy joined
06:51
nadim joined
06:53
japhb left
06:55
japhb joined,
domidumont joined
07:00
CIAvash left,
CIAvash joined
07:01
domidumont left
07:03
domidumont joined
07:09
Tonik joined
07:10
AlexDaniel left
07:12
nightfrog left
07:15
CIAvash left
07:20
japhb left
07:21
japhb joined
07:22
eisen74 left,
bjz joined
07:24
RabidGravy left
07:25
darutoko joined
|
|||
moritz | viki++ # advent theme, nicely readable | 07:27 | |
yoleaux | 29 Nov 2016 23:59Z <viki> moritz: I checked a few and they sucked. This one is sexy, so I went with it: perl6advent.wordpress.com/2015/12/18/ | ||
07:30
awwaiid left,
awwaiid joined
07:37
_28_ria left,
bjz left
07:39
_28_ria joined
07:42
dataf4l left,
dataf3l left
07:45
lizmat left
07:52
bjz joined,
dataf3l joined
07:54
_28_ria left
07:55
dataf4l joined,
_28_ria joined
07:58
Actualeyes left
08:01
dataf4l left,
dataf3l left
08:03
CIAvash joined
08:04
Wiertek joined
08:11
ufobat joined
08:13
Wiertek left
|
|||
nadim | viki: very nice indeed. if I may, can we get more than 50% advent post? the calendar column on the left is more or less noise and takes too much room IMO. also, the links in a color that doesn't look like errors. | 08:15 | |
08:17
avalokite joined
08:19
Actualeyes joined
08:20
firstdayonthejob joined
|
|||
moritz | if the screen is too narrow, you don't see the calendar column, so it's not a problem | 08:38 | |
and on wide screens I don't really mind | 08:39 | ||
08:42
brillenfux joined
08:47
pierre_ left
|
|||
nadim | It's not that there is too little room, just too little text, and too short sentences. i.imgur.com/nFUoMb5.png | 08:54 | |
08:56
bjz_ joined
08:57
pierre_ joined,
bjz left
09:12
LeCamarade joined
|
|||
LeCamarade | I know this channel is much too civil to poke fun at other languages, even though it has richly earned the right to. However, the recent article by Zed Shaw on Python 3's failures is proof-positive of why Perl 6 was doing the right things the right way all along. | 09:14 | |
Even if it takes 15 years, let it take 15 years and a serious and humble attempt to get things right and composable, rather than the mad rush that has ended up at Python 3. | |||
moritz | LeCamarade: I'd like that to be to true, but I don't see the evidence | ||
LeCamarade | learnpythonthehardway.org/book/nopython3.html | 09:15 | |
moritz | the usage numbers for python 3 are higher than Perl 6, both in relative and absolute numbers | ||
and the damage done to pyhon 2 and perl 5 is hard to quantify | |||
LeCamarade | Yes, but Perl 6 is a hundred-year language. Python 3 is a feeble attempt at Python 1.0. | ||
09:16
CIAvash left
|
|||
LeCamarade | My point is that Py3 is a terrible mess. I have been deploying production stuff on the latest Pythons for many years now. I have much less confidence in Py3 than I would have in PHP 5. No jokes. | 09:16 | |
Perl 6 got difficult problems right; it is a genuine improvement on Perl 5.20! Python 3, on the other hand, clearly did not have a humble linguist agonising over the features and how they work together. | 09:18 | ||
timotimo | the very early days of py3 were extremely bumpy, but isn't it the clear winner over py2 nowadays at least? | 09:20 | |
LeCamarade | Py3 assumed improvements to a language at this point would be easy. Wrong. TimToady knew right. | 09:21 | |
timotimo | i have stopped using python for my stuff when i joined the p6 community, but back then py3 was painful to use (no numpy or scipy or something) | ||
moritz | at $work, we use py3 for new projects, and it works fine | ||
LeCamarade | timotimo No. It is actually worse now. For example: we know about the Unicode implementation in Perl 6, and it is extremely far removed from where Py3 is _headed_. See that? | 09:22 | |
moritz Yes, I use Py3 too, and that is why I know to hate it! :-D I was hoping to convert all my Py2.7 projects on GAE to Py3 (having earlier moved them from Py2.5), and so I started messing with it. Dear God. | |||
seatek | Only time I've ever messed with Python is when I've had to go fix or tweak little things here or there. Reminds me of playing with plastic Lego blocks. | 09:24 | |
moritz | I guess the experience for a conversion is quite different than for a green-field project | ||
LeCamarade | SourceBaby: fine, I stopped looking for a new scripting language ever since Perl 6 came out, but before that time, I was probably one of the first to deploy Ruby 2.0 (called 1.9 at the time). I have a website running on Rakudo Star. I do bleeding edge. And Python 3 is haemorrhaging edge. | 09:25 | |
seatek | oh my gosh, "once" is not fooling around. it even survives multiple different class instantiations. | ||
LeCamarade | (I meant to write "So", not "SourceBaby".) | ||
seatek | m: class D { method m() { once say 'this'; }}; my $c = D.new; $c.m; my $d = D.new; $d.m; my $e = D.new; $e.m; | 09:26 | |
camelia | rakudo-moar 843a6b: OUTPUT«this» | ||
seatek | anyone know of a way to make it be... once... until i tell you again that you haven't done it? :) | 09:27 | |
LeCamarade | I just want to say something to this channel, and I hope it makes it to TimToady somehow: the slow, deliberate, careful approach to going beyong Perl 5 was exactly the right thing to do. Otherwise, Perl 6 would have been the kind of trivial (probably illusory) improvement on the former. | ||
seatek | I think the people here are really wonderful people LeCamarade | 09:28 | |
LeCamarade | Even Python 3 was more than 15 years in the making (as ovid or someone once pointed out in an e-mail spat about why Perl 6 was taking forever). I for one had been waiting for Perl 6 for 10 of those years. | ||
seatek Yeah, I find that they are nice. But there is a time for peace and a time for war. I am more on the latter end. ;-) The thing is, there is a time to say that "That sucks!" and I can never trust these people to say it so directly. Now, Perl 6 rocks to high heaven, because a man who was called to do languages for God (he was going to be a Bible translator) worked on it as his life's work. Py3 sucks, because they did not understand that this matter | 09:30 | ||
timotimo | seatek: build your own state variable and give the user access to resetting it by making it named | 09:31 | |
seatek | seatek: yeah that's what i was going to do. either that, or beg for a onceish function | 09:32 | |
i'm amazed it survives through that | |||
LeCamarade: it sounds stressful | |||
i say let them play with their legos :) | 09:33 | ||
LeCamarade | seatek Not if you feel called to do it; not if you feel incomplete otherwise. Isn't all this geekery and math stressful to you? ;-) | 09:34 | |
seatek | naw i kinda go zen on it. but arguing with people is is stressful to me. the mentalities are very different. python people seem to believe in One Way that is correct. and so it's very hard to help them see other things and ways | 09:36 | |
at least that's what i've found | |||
i think it's good to have the good fights out there though :) | 09:37 | ||
timotimo | we've seen enough good snark about python having more than one way, and in some cases all ways suck :( | ||
LeCamarade | Fine, but they are failing in their own methodology because they did not have someone sit down and figure out the one right way to do the one-right-way language. Py3 emphatically isn't it. | ||
seatek | i hear ya :) | 09:38 | |
LeCamarade | On the other hand, Perl 6 clearly understands the philosophy behind it so well that I can enforce a pythonic worldview in it--python done properly, even provably, in perlistic terms. | ||
09:39
wamba left
|
|||
LeCamarade | You see, Py3 thought that "all we need is to tweak this here." Wrong. This deep into the 21st century, if you are doing a language++, and especially if you break backward compatibility, you had better have had someone sit and think. We are not interested in yet another new syntax. Honestly, it is relieving that Perl 6 is so well-done that I do not expect to look around ever again. A pity I still can't get it to run on my Raspberry Pi! :-( | 09:41 | |
seatek | yeah one of the first things that struck me when starting into Perl6 was that somehow it felt WAY more structured, yet still felt almost completely free at the same time. Very odd. | ||
09:42
dakkar joined,
noganex left
|
|||
seatek | ok who needs once?? not me | 09:42 | |
LeCamarade | Now I use only two languages: Haskell and Perl 6. It used to be Haskell and Ruby, but Ruby was only for programs less than 301 lines long. Perl 6, which I write almost entirely statically-typed, can sustain thousands of lines. Py3 has not even began to be more-useful than Forth in that regard. It's an unfortunate joke. | ||
09:42
noganex joined
|
|||
seatek | i'm pretty well committed to Perl 6 for life now. which may be quite short, if i shoot myself because of the size/compiling stuff continuing to grow on this crazy thing | 09:44 | |
LeCamarade | What makes it all the more poignant for me is that, when Perl 6 was "delayed", the noise was (as is typical for us) all about how long it was taking. When I saw the result, I knew it was God who had commissioned TimToady. The result is what should have mattered. And this thing is insanely brilliant. I have been a language fanatic from my childhood, and very early on I decided I wanted a "perfect" language. I am sure I meant a "hundred-year language". P | 09:45 | |
09:46
pmurias joined
|
|||
LeCamarade | seatek Good on you! :-) That makes two of us. I literally do not bother with alternatives anymore. If you have an alternative for "system software", preferably Haskell, you should be fine. Lucky you, though, because I, on the other hand, have not yet successfully compiled Rakudo Star on my computer! :-( | 09:46 | |
(I mean my domestic-usage computer; it is a Raspberry Pi. So whenever I do something there, it is in Haskell, or Perl 5 because I can now tolerate that weirdness if I know I am not bound to it for the long haul.) | 09:47 | ||
seatek | LeCamarade: maybe you've been a very naughty person and you're being punished. while i, on the other hand, am practically perfect... ;) | ||
09:48
M_o_C joined,
M_o_C left
|
|||
LeCamarade | seatek I am sure I have been naughty. However, punishment should hurt some more than this ... :-D | 09:48 | |
seatek | i think you'll make a great holy crusader LeCamarade :) | 09:49 | |
i'm far too self absorbed i think .. :) | 09:50 | ||
pmurias | LeCamarade: re the anti python 3 rant, Perl 6 also avoids hidden binary data to unicode conversions | ||
LeCamarade | seatek Thanks! I wish you knew how right you are ... :-D (Hint: sacralist Reformed Presbyterians still exist, and they do believe in armed revolution, and, if they are me, are actively working to that end.) | 09:51 | |
09:51
CIAvash joined
|
|||
LeCamarade | pmurias Yes, but Perl 6 is way more orthogonal: in regular expressions (using Unicode classes, while Py3 goes "Wha'?"), and in allowing, say, Unicode quotes that work as they should (where Py3 just dies). | 09:53 | |
09:54
labster left
|
|||
LeCamarade | pmurias Actually, when it comes to Unicode, at present, no man should mention Perl 6 and a joke like Py3 in the same breath. World apart. I write _all_ my strings with proper quotes. _All_ of them. I cannot even type them because this client does not do Unicode as well as my Perl 6 does. | 09:54 | |
“Quotes” | |||
Yay! | |||
So, yeah: in _every_ case, in my code, I writes strings either as “strings” or as ‘strings’, depending on the need. | 09:55 | ||
And that is just one problem! I cannot live without that, by the way, because I insist on it as much as I insist on the commas, for which you can see evidence in my chats (since, unlike the quotes, I was already sure they would work …). | 09:56 | ||
timotimo | it does have the benefit of giving a clear start and end quote, for nesting and such | ||
though our smart quote stuff might be problematic for that? giving you multiple possible end-quotes for the same start-quote? | |||
m: say ‚foo’; say ‘bar’ | |||
camelia | rakudo-moar 843a6b: OUTPUT«foobar» | ||
timotimo | m: say ‚foo‘nested?’bar’ | ||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Two terms in a rowat <tmp>:1------> 3say ‚foo‘7⏏5nested?’bar’ expecting any of: infix infix stopper postfix statement end statement…» | ||
LeCamarade | I also already use things like → and the like in my Haskell. So I expected it to work. In Perl 6, it does. | ||
timotimo | okay, not nested with those kinds of quotes | ||
m: say ‘foo‘nested?’bar’ | 09:57 | ||
camelia | rakudo-moar 843a6b: OUTPUT«foo‘nested?’bar» | ||
timotimo | with this kind, though, it works | ||
yeah, that makes sense | |||
you don't want to have a quote character that you don't realize is a valid start-quote give you nesting within what you know to be your start-and-end marks | |||
LeCamarade | timotimo And that is just one simple thing that a grammar nazi like myself just cannot otherwise tolerate not having. Only one language gets it right. And that is one simple _source code_ matter! There are many millions of others. You still have stupid regexen in Py3. And they took as long at it as TimToady took with Perl 6! It’s an unfortunate joke. | 09:58 | |
You still have an “interpreted” language, and you still have to use “lex and yacc” to get a string parse. Not funny. | 10:00 | ||
timotimo | yeah, put the heaviest of quotations on the word ‘interpreted’ | 10:01 | |
LeCamarade | For ranges, I use the proper diæreses: … | 10:02 | |
timotimo | that term has long lost most of its usefulness | ||
10:02
AlexDaniel joined
|
|||
LeCamarade | Unless it really means nothing now, you should be able to tell your interpreted-language parser to just adopt _these other rules_ while it goes over _that other line_. We think this is a big deal because our bar has been set way too low by things like Py3. | 10:03 | |
AlexDaniel | LeCamarade: hello! | ||
LeCamarade | AlexDaniel Hi! :-D | 10:04 | |
AlexDaniel | I was reading the log… and seems like somebody really likes the quotes :) | ||
so I came here to say hi, because I really do too | |||
LeCamarade | Log? | ||
AlexDaniel | irclog.perlgeek.de/perl6/2016-11-30 | ||
LeCamarade: ah ya, by the way: gist.github.com/AlexDaniel/c89bd2786f9b63f31e4c | 10:05 | ||
m: say ‚foo‚nested?’bar’ | 10:06 | ||
camelia | rakudo-moar 843a6b: OUTPUT«foo‚nested?’bar» | ||
LeCamarade | AlexDaniel Cool resource! | ||
AlexDaniel | timotimo: works fine if you do it properly :) | ||
timotimo | well, yeah | 10:07 | |
i was talking about having different pairs | |||
LeCamarade | Sometimes I am coding in a francophone context, and I use xC2 cette sorte ». | 10:08 | |
10:08
synopsebot6 left,
M_o_C joined,
synopsebot6 joined
|
|||
LeCamarade | « quotes! » | 10:08 | |
10:08
M_o_C left
10:09
M_o_C joined,
M_o_C left
|
|||
AlexDaniel | LeCamarade: what about ∞, 2², ½ ? Do you use that stuff too? | 10:09 | |
u: MINUS SIGN | |||
unicodable6 | AlexDaniel, U+00B1 PLUS-MINUS SIGN [Sm] (±) | ||
AlexDaniel, U+02D7 MODIFIER LETTER MINUS SIGN [Sk] (˗) | |||
AlexDaniel, U+0320 COMBINING MINUS SIGN BELOW [Mn] (◌̠) | |||
LeCamarade | AlexDaniel Oh you bet! I get every excuse to! | ||
unicodable6 | AlexDaniel, gist.github.com/7fce0f40666a0d60db...5ce4b6fecd | ||
AlexDaniel | LeCamarade: what about −? | ||
LeCamarade | I use … in ranges, but … what is that, the em-dash? — ? | 10:10 | |
En-dash. I don’t know how to type it. | |||
:-( | |||
timotimo | but ⟨⟩ and «» don't have regular quoting semantics | ||
m: say «foo bar baz».perl | 10:11 | ||
camelia | rakudo-moar 843a6b: OUTPUT«("foo", "bar", "baz")» | ||
LeCamarade | AlexDaniel Is that the en-dash? I would assume it work like a mere -? | ||
AlexDaniel | u: - — | ||
unicodable6 | AlexDaniel, U+002D HYPHEN-MINUS [Pd] (-) | ||
AlexDaniel, U+0020 SPACE [Zs] ( ) | |||
AlexDaniel, U+2014 EM DASH [Pd] (—) | |||
AlexDaniel | uhh that's not it | ||
u: -−– | 10:12 | ||
unicodable6 | AlexDaniel, U+2212 MINUS SIGN [Sm] (−) | ||
AlexDaniel, U+002D HYPHEN-MINUS [Pd] (-) | |||
AlexDaniel, U+2013 EN DASH [Pd] (–) | |||
LeCamarade | timotimo Yes, actually. I use those for lists, I remember. There was something else I was demoing for my less-enlightened francophone friends. But, yes, I use them for qw// lists. | ||
AlexDaniel | LeCamarade: the issue with - is that it is used both as a hyphen and a minus | ||
LeCamarade: so unicode actually has a separate character for a minus | |||
LeCamarade: which normally looks identical, but still… | |||
and Perl 6 supports it too | 10:13 | ||
m: say −42 | |||
camelia | rakudo-moar 843a6b: OUTPUT«-42» | ||
LeCamarade | AlexDaniel Woah. Now I am going to have learn how to type that with X’ compos. | ||
u: - | |||
unicodable6 | LeCamarade, U+002D HYPHEN-MINUS [Pd] (-) | ||
LeCamarade | u: — | ||
unicodable6 | LeCamarade, U+2014 EM DASH [Pd] (—) | ||
AlexDaniel | LeCamarade: do you write your ‘’ “” 「」 quotes using compose key also? | 10:14 | |
LeCamarade | AlexDaniel Yes. | ||
AlexDaniel | that's kind of inefficient, I just added them all to my keyboard layout | ||
(so that the time to type " is identical to the time to type “) | 10:15 | ||
and … is one key press instead of 3 :) | |||
10:16
andrzeju_ joined
|
|||
LeCamarade | AlexDaniel Hmm. I wanted something I could google … | 10:16 | |
Actually, … is _four_ keypresses! | |||
10:16
dogbert2 joined
|
|||
LeCamarade | Compose + . + . + .. Absurd. :-( | 10:16 | |
AlexDaniel | yea, well… Compose is good for rare characters, but you should get common stuff right into your keyboard layout, I believe | ||
10:17
noganex_ joined
10:18
zakharyas left,
zakharyas joined
|
|||
LeCamarade | Compose is terrible, but I can only fix those things once I move away from using stock computers. The only piece I do not have, alas, is Rakudo Star on ARM64. I have even started thinking of replacing Pi with something like the JaguarBoard, so that I can move on. I do not want to configure crap; I want to build awesome. | 10:18 | |
10:18
perigrin_ joined,
domm1 joined,
krakan_ joined
10:19
baest_ joined,
Spot__ left,
ribasushi left,
zacts left,
setty1 left,
perigrin left,
domm left,
dakkar left,
apejens left,
mr-foobar left,
ilmari[m] left,
PerlJam left,
ShoaibJahejo left,
gfldex left,
ilbelkyr left,
timotimo left,
noganex left,
brillenfux left,
dogbert17 left,
andrzejku left,
Khisanth left,
timeless left,
huf left
|
|||
LeCamarade | AlexDaniel Which keyboard layout do you use? I use Dvorak. With Compose on caps. | 10:19 | |
10:19
saki_ left
10:20
jonadab joined,
mr-foobar joined,
PerlJam joined,
gfldex joined,
rblackwe joined,
apejens joined,
r3m_ joined,
ilbelkyr joined,
DrForr joined,
huf joined
10:21
saki joined
10:22
vcv_ joined
|
|||
LeCamarade | But back to the effusive pro-Perl 6 tribalism that got me in here today, in the first place: Py 3 people are still so, so far from even knowing that they could quote their strings properly, and they too broke backward compatibility and took 10+ years at it. Their problem is that they never had TimToady. | 10:22 | |
10:22
zostay left,
zakharyas left
10:24
timotimo joined,
timeless joined
|
|||
LeCamarade | Now, I am writing programs I expect my grandchildren to run. I can be that confident because I am coding in Perl 6 (and, where necessary or inevitable, Haskell). On the other hand, Py 3 will _have_ to quickly move to another botched attempt at ++. Py 4 will also fail, because it will not be Perl 6. :-p | 10:24 | |
10:25
g4 joined,
g4 left,
g4 joined,
musca joined,
Matthew[m] left,
baest left,
r3m left,
effbiai left,
nchambers left,
r3m_ is now known as r3m
10:26
zostay joined,
nchambers joined
|
|||
pmurias | LeCamarade: I don't think triabalism is a commonly held attitude on this channel | 10:26 | |
LeCamarade | Even if TimToady now said he had Perl 7, I would be excited but deeply sceptical. We know how much work and time it was to improve on Perl 5, and, good as that was, it was still something that could desperately use some improvement. Now, Perl 6 is a completely different opus. It would take a dedicated monastery about 100 years of humble monks trying things, praying, then coding, before Perl 7 could happen. And yet Perl 7 could happen. | ||
10:26
itaipu joined
10:27
Khisanth joined
|
|||
AlexDaniel | LeCamarade: I use a custom layout | 10:28 | |
LeCamarade | For one, I am only now focussed on changing the runtime. Rakudo Star is fine for getting me off the ground. Ultimately, it must be a Forth that is running Perl 6. Imagine that: Perl 6 (where Haskell won’t do)and the lot running on a Forth machine. That is what I am working towards. Now, I genuinely was going to take the time to do a proper “hundred-year language”, but then Perl 6 happened. I have only the other parts to work on, now. | 10:29 | |
AlexDaniel | it is based on dvorak (that is, all letters are in normal dvorak positions), but everything else is different | ||
however, you must have a japanese keyboard to use it properly | |||
LeCamarade | pmurias I know this channel is not nearly as tribalistic and jingoistic as it has earned the right to be. Oh, well. I don’t come that often. | ||
10:30
ilmari[m] joined,
dakkar joined,
setty1 joined
10:31
setty1 left,
dakkar left
|
|||
LeCamarade | pmurias And people do not really know what Perl 6 is about. They will not know the truth of it unless someone says “It is the best scripting language out there right now.” Someone has to tell the truth at some point. A fierce tribalist like me, no doubt. It is the truth, after all. | 10:31 | |
AlexDaniel | and that being said… I am happy that bash does not support ‘’ quotes :P | ||
dalek | c: 99fdca2 | gfldex++ | doc/Type/Routine.pod6: clearly state responsibilities when using `is pure` |
||
synopsebot6 | Link: doc.perl6.org/type/Routine | ||
10:31
grondilu joined
10:32
Matthew[m] joined,
shadowpaste joined
|
|||
AlexDaniel | LeCamarade: it would be nice if this fierce tribalist contributed to the core development in some way… all this excitement has to be put into the right direction :P | 10:32 | |
10:32
ribasushi joined
|
|||
AlexDaniel | and given that most of rakudo is written in Perl 6, I suspect you will like it | 10:33 | |
LeCamarade | AlexDaniel Yes. The right direction does not exclude loud declarations, even as it includes contributing to the core development. | ||
Meanwhile, I am only going to be taking on development starting next year, and primarily on ARM64. On FreeBSD. A very, very difficult mix; I wonder if I am well-prepared (enough). | 10:34 | ||
10:35
effbiai joined
|
|||
AlexDaniel | do we even support arm64 properly right now? | 10:35 | |
LeCamarade | Before that, though, there is donations for Rakudo development, et cetera. | ||
10:36
ShoaibJahejo joined,
Spot__ joined,
setty1 joined,
dakkar joined,
Spot__ left,
Spot__ joined,
ShoaibJahejo left,
ShoaibJahejo joined
|
|||
LeCamarade | AlexDaniel No. In fact, on FreeBSD, I cannot even get a compiler that will work. At present (12-CURRENT). | 10:36 | |
10:36
ShoaibJahejo left,
ShoaibJahejo joined
|
|||
AlexDaniel | well, that sucks | 10:37 | |
LeCamarade | But consider: instead of all the stuff people are spouting about Py 3, which does not even try to get things correct, if someone shouted from the rooftops “Actually, ye trogs, ‘tis Perl 6 ye are lookin’ for!” you would have the massive surge in core developers that you want. | ||
AlexDaniel | ok, I have to run. See you around! | 10:38 | |
LeCamarade | Glad for your quotes and Unicode resource! :-D | ||
ZzZombo | m: my @a=1;dd @a[0,3] | 10:40 | |
camelia | rakudo-moar 843a6b: OUTPUT«(1, Any)» | ||
ZzZombo | why is there only one Any? | ||
10:40
zacts joined
|
|||
gfldex | ZzZombo: you asked for 2 values and one of them is defined | 10:41 | |
ZzZombo | oh | 10:42 | |
m: my @a=1;dd @a[0..3] | |||
camelia | rakudo-moar 843a6b: OUTPUT«(1, Any, Any, Any)» | ||
10:42
AlexDaniel left
|
|||
gfldex | m: my @a=1;dd @a[0;3] | 10:42 | |
camelia | rakudo-moar 843a6b: OUTPUT«Failure.new(exception => X::OutOfRange.new(what => "Index", got => 3, range => "0..0", comment => Any), backtrace => Backtrace.new)» | ||
ZzZombo | shitty comma, I swear it slipped w/o my consent! | ||
gfldex | m: my @a=1;dd @a[0|,3] | 10:43 | |
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Preceding context expects a term, but found infix , insteadat <tmp>:1------> 3my @a=1;dd @a[0|,7⏏053]» | ||
LeCamarade | m: my @a = 1; dd @[0 … 3] | ||
m: my @a = 1; dd @a[0 … 3] | |||
camelia | rakudo-moar 843a6b: OUTPUT«[0, 1, 2, 3]» | ||
rakudo-moar 843a6b: OUTPUT«(1, Any, Any, Any)» | |||
gfldex | commas can Slip | ||
*can't | |||
seatek | m: subset PosInt of Int where * > 0; CATCH { say $_.perl }; my PosInt $i = -2; | 10:48 | |
camelia | rakudo-moar 843a6b: OUTPUT«X::TypeCheck::Assignment.new(symbol => "\$i", operation => Any, got => -2, expected => PosInt)Type check failed in assignment to $i; expected PosInt but got Int (-2) in block <unit> at <tmp> line 1» | ||
ZzZombo | so is here a shorter version of | ||
m: my @a=1;dd @a[0..(@a>1??1!!0)] | |||
camelia | rakudo-moar 843a6b: OUTPUT«(1,)» | ||
seatek | that's good | ||
this confuses me | |||
m: subset Password of Str where m/^<[0..z]> ** 10..100$/; CATCH { say $_.perl }; my Password $i = 'wefwef'; | 10:49 | ||
camelia | rakudo-moar 843a6b: OUTPUT«X::TypeCheck::Assignment.new(symbol => "\$i", operation => Any, got => "wefwef", expected => Password)Type check failed in assignment to $i; expected Password but got Str ("wefwef") in block <unit> at <tmp> line 1» | ||
seatek | oh got it right on this camelia | ||
must be my version | |||
gfldex | m: my @a = 1; say @a.head(2) | ||
camelia | rakudo-moar 843a6b: OUTPUT«(1)» | ||
gfldex | m: my @a = 1,2; say @a.head(2) | ||
camelia | rakudo-moar 843a6b: OUTPUT«(1 2)» | ||
gfldex | m: my @a = 1,2,3; say @a.head(2) | ||
camelia | rakudo-moar 843a6b: OUTPUT«(1 2)» | ||
ZzZombo | yay | 10:50 | |
gfldex | ZzZombo: ^^^ depends a bit who you expect to read your code. If they are fluent in bash .head is the way to go. | ||
pmurias | nqp-m: my $foo := 12; my int $bar := $foo || 200;say($bar) | 10:52 | |
camelia | nqp-moarvm: OUTPUT«0» | ||
pmurias | ^^ is this nqp-m bug known? | ||
jnthn | pmurias: I don't recognize it. | 10:55 | |
10:58
jonas1 joined
|
|||
LeCamarade | And let me say one last thing, since seatek noticed I am crusader proper: after the revolution, Perl 6 will be taught in our schools. So ultimately it will be the BASIC for a certain generation, no matter how many or how few tribalistic jingoists you have on the ‘Net. Remember this. :-) Good thing it is being logged. Also, just because it is always fitting: jnthn++ | 10:59 | |
11:00
LeCamarade left
|
|||
sjn | hello, #perl6 | 11:00 | |
viki | \o | ||
seatek | m: subset Password of Str where m/^<[0..z]> ** 10..100$/; CATCH { say $_.perl }; class P { method pset(Password $pw) { say $pw }; }; my $p = P.new; $p.pset('wefwef'); | 11:01 | |
camelia | rakudo-moar 843a6b: OUTPUT«X::AdHoc.new(payload => "Constraint type check failed for parameter '\$pw'")Constraint type check failed for parameter '$pw' in method pset at <tmp> line 1 in block <unit> at <tmp> line 1» | ||
seatek | ok that weird me out a bit | ||
it's changed to an AdHoc instead of Type error | |||
viki reads a few of LeCamarade posts above.... | 11:02 | ||
damn, I wish my drugs were that good... | |||
seatek | he teeters on the edge :) | 11:03 | |
viki -- can you solve my problems? | |||
viki | nadim: no, we can't change minute details of the theme because we run this on wordpress.com and they want a paid subscription to be able to do that. | ||
seatek: which are? | 11:04 | ||
seatek | if exceptions have to come up through multiple classes for subset type constraints, do the loose their original exception type? | ||
m: subset Password of Str where m/^<[0..z]> ** 10..100$/; CATCH { say $_.perl }; my Password $i = 'wefwef'; | |||
camelia | rakudo-moar 843a6b: OUTPUT«X::TypeCheck::Assignment.new(symbol => "\$i", operation => Any, got => "wefwef", expected => Password)Type check failed in assignment to $i; expected Password but got Str ("wefwef") in block <unit> at <tmp> line 1» | ||
seatek | This is right | ||
m: subset Password of Str where m/^<[0..z]> ** 10..100$/; CATCH { say $_.perl }; class P { method pset(Password $pw) { say $pw }; }; my $p = P.new; $p.pset('wefwef'); | |||
11:04
geekosaur left
|
|||
camelia | rakudo-moar 843a6b: OUTPUT«X::AdHoc.new(payload => "Constraint type check failed for parameter '\$pw'")Constraint type check failed for parameter '$pw' in method pset at <tmp> line 1 in block <unit> at <tmp> line 1» | 11:04 | |
seatek | this is not | ||
viki | There's a ticket for that. | 11:05 | |
And no, I can't solve it. | |||
seatek | ah! :) ok i'm NOT insane :) | ||
that's reassuring | |||
ok :) | |||
11:05
geekosaur joined
|
|||
seatek | i was just looking for reassurance or info. i'll resort to smartmatching the text of the error message... | 11:05 | |
hehehe | |||
btw nobody can change the text of exception message any more from this point on... ;) | 11:07 | ||
viki | m: subset Password of Str where m/^<[0..z]> ** 10..100$/ or die "cry me a river"; CATCH { say $_.perl }; class P { method pset(Password $pw) { say $pw }; }; my $p = P.new; $p.pset('wefwef'); | 11:08 | |
camelia | rakudo-moar 843a6b: OUTPUT«X::AdHoc.new(payload => "cry me a river")cry me a river in block <unit> at <tmp> line 1» | ||
seatek | hehehe :) :) | 11:09 | |
viki | seatek: you can throw proper exception yourself. Also there's modules.perl6.org/dist/Subset::Helper | ||
seatek | if i do down there, will it stick all the way up? | ||
or will it be stripped to adhoc too? | |||
oh this is nice | 11:10 | ||
11:12
pierre_ left
11:19
TEttinger left
11:20
nadim left
11:25
CIAvash left
|
|||
dalek | : d5f0f32 | (Zoffix Znet)++ | misc/perl6advent-2016/schedule: Remove pun from title (it's better elsewhere) |
11:27 | |
andrzeju_ | hey | 11:28 | |
viki | \o | ||
andrzeju_ | :D | ||
viki, could you look fast what I wrote? | 11:29 | ||
dalek | : d4025fc | (Zoffix Znet)++ | misc/perl6advent-2016/schedule: Book another day With "Set In Your Ways: Perl 6's Setty and Baggy Types" I'm just filling up holes. Feel free to remove me and claim those spots for yourself. |
11:30 | |
viki | andrzeju_: probably not, as I'm breakfasting and leaving to work shortly. | ||
andrzeju_ | :< | 11:31 | |
I am temporary do it at work, have no special tasks by these days | 11:32 | ||
dalek | : 7c0ac6f | (Zoffix Znet)++ | misc/perl6advent-2016/schedule: mark Zofspots as claimable |
||
viki | andrzeju_: well, there are 318-$bot-count people in this channel. If you post a link, they could read | 11:33 | |
andrzeju_ | sure, www.gitbook.com/book/damaxi/weird-...le/details | ||
dalek | : 2f59851 | (Zoffix Znet)++ | misc/perl6advent-2016/schedule: s/spot/post/ |
11:34 | |
11:34
_28_ria left
|
|||
andrzeju_ | viki, I am planning to read a bit information how the Perl6 design process look and architecture and then put it into introduction :P | 11:34 | |
viki | Cool. | 11:35 | |
We use the whirlpool metaphor.... | 11:36 | ||
.oO( swirling toilet? ) |
|||
The design and real-world usage goes back and forth like a water spinning in the toilet (or are we doing the whirlpool?), and with each spin, we get closer to the center, which represents the perfect design :) | 11:37 | ||
jnthn | That's the first time I've heard it described as like being in a toilet :P | 11:38 | |
seatek | with snakes in the plumming | 11:39 | |
viki | >:) | ||
seatek | and a nice plant to the right | ||
dalek | osystem: f273743 | spebern++ | META.list: add module |
11:41 | |
osystem: 22ea7cb | (Zoffix Znet)++ | META.list: Merge pull request #270 from spebern/master add module |
|||
viki | github.com/spebern/Parser-FreeXL-Native/ | ||
11:42
spebern joined
|
|||
dalek | : ec7ed54 | (brian d foy)++ | misc/perl6advent-2016/schedule: I changed my topic Just so other people know. |
11:43 | |
: b3d1338 | (Zoffix Znet)++ | misc/perl6advent-2016/schedule: Merge pull request #18 from briandfoy/patch-2 I changed my topic |
|||
viki | andrzeju_: hehe, you should make ingrish your gimmick in the book | 11:46 | |
don't try to fix it :) | 11:47 | ||
"I amn't Perl developer either." that's just gold | |||
andrzeju_ | huh, does it look not so bad? | 11:48 | |
11:48
Wiertek joined
|
|||
viki | andrzeju_: well, I know what you meant. It looks funny :) | 11:48 | |
And this way you don't need to worry about the language. If anyone tries to diss it, just say it was made that way on purpose :) | 11:49 | ||
Like this dude: www.youtube.com/watch?v=As10jr1Vvj0 | |||
andrzeju_ | hah, okay :D indeed I am quite funny guy | ||
viki | His heavy Russian accent is a gimmick | ||
11:50
wamba joined,
iH2O joined
|
|||
andrzeju_ | viki, okay thnks for hot words :D then I wil read some material and continue with it | 11:50 | |
11:51
iH2O left
11:53
itaipu left
11:55
effbiai left,
effbiai joined
11:56
setty1 left,
bjz joined,
bjz_ left
11:59
Actualeyes left
12:06
CIAvash joined
12:14
canopus left
12:15
zakharyas joined
12:20
kalkin- left
12:21
pierre_ joined,
canopus joined
|
|||
ZzZombo | Somebody got a minute to read stuff you probably won't agree to? | 12:22 | |
gist.github.com/ZzZombo/34803d3cc6...41b6cdbfc3 | |||
seatek | if you use a role instead of a class, you can "subclass" in a private attribute -- is that what would help? | 12:33 | |
12:33
pat_js joined,
wamba left
|
|||
seatek | role XML::GraphItemGroup does XML::GraphItem... or somesuch | 12:35 | |
i'd split it down into ever further granularity with roles though if it was me | |||
seatek goes afk for some much needs breaktime | 12:37 | ||
12:39
wamba joined
12:40
baest_ is now known as baest
12:43
Actualeyes joined
|
|||
sjn looks at perl6.org/compilers/, seeing that Parrot isn't mentioned... Should there be a "Historical Runtimes" section there? | 12:43 | ||
ZzZombo | seatek: each of those attributes would have distinct values, you would have to go out of your way and somehow initialize them all. | 12:49 | |
I assume you were talking about xmlnode. | |||
12:49
spebern left
12:58
grondilu left,
cibs left
12:59
chris2 left
13:00
cibs joined
|
|||
viki | ZzZombo: read stuff you probably won't agree to.... to what end? | 13:05 | |
13:06
chris2 joined
|
|||
pmurias | why does perl6.org/compilers mention that Rakudo is copyrighted by the TPF? | 13:09 | |
moritz | because it's true | 13:12 | |
viki | pmurias: whose is the copyright then? :) | ||
moritz | the CLA assigns them a non-exclusive copyright | ||
pmurias | moritz: why is that relevant enough to mention on the download page? | 13:14 | |
13:14
viki left,
viki joined,
viki left
|
|||
moritz | pmurias: that's not the download page, it's the info page about compiler(s) | 13:15 | |
pmurias: I don't find it misplaced | |||
when we had multiple compilers, we had the information who was responsible and/or the driving force, characterstics of the compiler, dowload links etc. | 13:16 | ||
sjn: please no historical runtimes; we try very hard to keep outdated information off perl6.org | 13:17 | ||
13:17
avalokite left,
notviki joined
|
|||
notviki | heh | 13:17 | |
The real viki ghosted me :) | |||
moritz | what's the relevance of teaching a newbie that rakudo was based on parrot, years ago? | ||
pmurias | moritz: why is that relevant? | ||
sjn | moritz: fair enough :) | 13:18 | |
pmurias | moritz: and is the CLA granting the TPF a license to use Rakudo the same thing as the "TPF copyrighting Rakudo"? | ||
moritz | pmurias: my legalese fu is not strong enough to answer that | 13:19 | |
ZzZombo | <viki> to what end? | ||
eh, what? | |||
notviki | ZzZombo: for what purpose would we read it? | ||
ZzZombo | ah, it's to help me with me having issues with P6 class system, I guess. | 13:20 | |
13:22
notviki is now known as cassini
13:23
cassini is now known as Guest80605
|
|||
pmurias | what are the arguments for keeping the "Copywrite by the TPF" mention | 13:23 | |
? | |||
I suspect that's actually not the case, and it might lead people to believe that Rakudo is closed source | 13:24 | ||
13:26
Guest80605 left
|
|||
dalek | href="https://perl6.org:">perl6.org: b3935c5 | (Pawel Murias)++ | source/compilers/index.html: Remove confusing mention of Rakudo being "copyrighted by the TPF". |
13:30 | |
13:32
babydrop joined
|
|||
babydrop | pmurias: section 4.1 gives TFP the non-exclusive copyright, | 13:35 | |
(of CLA) | |||
perlpilot | um ... Rakudo is still copyright TPF as far as I know. IF that's no longer the case, there are a *bunch* of files in the Rakudo repo that need to change. | 13:37 | |
13:38
CIAvash left
|
|||
perlpilot | okay ... maybe not a bunch, but several :) | 13:38 | |
babydrop | sjn: see what you started! :P | 13:39 | |
sjn | oh noes! | ||
perlpilot | Also, if TPF doesn't hold the copyright, who does? | ||
13:40
dataf3l_ joined,
dataf4l joined,
CIAvash joined
|
|||
babydrop | perlpilot: TPF does hold the non-exclusive copyright | 13:40 | |
We've just changed the compiler info page. | |||
perlpilot | To what end? | 13:41 | |
dalek | /advent_day_4_title_change: 7af7314 | (Brian Duggan)++ | misc/perl6advent-2016/schedule: title change |
||
pmurias | babydrop: 4.1 mentions granting a license | ||
babydrop | pmurias: license to what? | 13:43 | |
pmurias: "all intellectual property rights (excluding patent and trademark, but including copyright)" | |||
pmurias: the contributor still retains their rights and can do whatever they want with their contribution, but they can't sue TPF under copyright law | 13:44 | ||
pmurias | perlpilot: I removed the mention that Rakudo is coprighted by the TPF from the compilers page | 13:47 | |
babydrop | Yeah, it's not overly relevant on that page. | ||
13:50
zakharyas left
|
|||
dalek | : 7af7314 | (Brian Duggan)++ | misc/perl6advent-2016/schedule: title change |
13:51 | |
: 22c650d | (Brian Duggan)++ | misc/perl6advent-2016/schedule: Merge pull request #19 from perl6/advent_day_4_title_change title change |
|||
13:53
dataf3l_ left,
dataf4l left
14:02
itaipu joined,
user9 left
14:03
user9 joined
|
|||
ZzZombo | So... anybody? Please, I need your insight. | 14:03 | |
babydrop | heh, Google just called me... asking what I used their compute engine for. Told them Perl 6 compiler... | 14:04 | |
like a badass | |||
ZzZombo: but you said we wouldn't like reading it! :) | 14:05 | ||
14:06
cdg joined,
cdg left
14:07
cdg joined
|
|||
ZzZombo | Yes, because the previous time I tried to bring this topic, I got turned down, because apparently everything was thought of, and that P6 has is vastly superior to other languages. | 14:07 | |
babydrop | hehe | 14:08 | |
14:08
CIAvash left,
vendethiel left
|
|||
babydrop glances at "this class hierarchy" | 14:08 | ||
Well, I disagree, the previous time you brought it up, you got a nice, long blog post saying that OO are about passing messages around and that you should think about messages for and the class hierarchy will pop out out of it. | 14:09 | ||
But what you have in that gist is two classes with methods like set_name and set_count | 14:10 | ||
14:10
avalokite joined
|
|||
pmurias | ZzZombo: yes, that was the case ;) | 14:10 | |
ZzZombo | babydrop, I take it as you missed I stripped it down? | 14:11 | |
so then tell me what should I do? | |||
babydrop | ZzZombo: and someone already mentioned roles | ||
m: role Meow { has $!private-business = 42; }; class Foos does Meow { method meow { $!private-business } }.meow.say | 14:12 | ||
camelia | rakudo-moar 843a6b: OUTPUT«Cannot look up attributes in a Foos type object in method meow at <tmp> line 1 in block <unit> at <tmp> line 1» | ||
babydrop | m: role Meow { has $!private-business = 42; }; class Foos does Meow { method meow { $!private-business } }.new.meow.say | ||
camelia | rakudo-moar 843a6b: OUTPUT«42» | ||
ZzZombo | and the bit about them that I don't really understand is | 14:13 | |
m: role R { has $!a='foo' };role R2 { has $!a='bar' };class A does R {method m{put $!a}};class B is A does R2 {method n{put $!a}};B.new.m;B.new.n; | 14:14 | ||
camelia | rakudo-moar 843a6b: OUTPUT«foobar» | ||
ZzZombo | how it's supposed to work in cases like that. | ||
babydrop doesn't see what the case is about | |||
ZzZombo | I just don't really understand them. | ||
babydrop | roles get inlined into your class | 14:15 | |
ZzZombo | I tried to experiment wit them and got confusing results like ^ | ||
with* | |||
babydrop | So above, your class A still has role R in it, but class has its own $!a coming from R2 | ||
*but class B | 14:16 | ||
m: class A { has $!a = 'foo'; method m { put $!a } }; class B { has $!a = 'bar'; method m { put $!a }; B.new.m; B.new.A::m | 14:18 | ||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Missing blockat <tmp>:1------> 3ethod m { put $!a }; B.new.m; B.new.A::m7⏏5<EOL> expecting any of: statement end statement modifier statement modifier loop» | ||
babydrop | m: class A { has $!a = 'foo'; method m { put $!a } }; class B { has $!a = 'bar'; method m { put $!a }; B.new.m; B.new.A::m() | 14:19 | |
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Missing blockat <tmp>:1------> 3hod m { put $!a }; B.new.m; B.new.A::m()7⏏5<EOL> expecting any of: statement end statement modifier statement modifier loop» | ||
babydrop | :/ | ||
m: class A { has $!a = 'foo'; method m { put $!a } }; class B { has $!a = 'bar'; method m { put $!a }; dd B.new.*m | |||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Missing blockat <tmp>:1------> 3'bar'; method m { put $!a }; dd B.new.*m7⏏5<EOL> expecting any of: postfix statement end statement modifier statement…» | ||
jnthn | Missing clsoing } on the class | ||
babydrop | m: class A { has $!a = 'foo'; method m { put $!a } }; class B { has $!a = 'bar'; method m { put $!a } }; dd B.new.*m | ||
camelia | rakudo-moar 843a6b: OUTPUT«bar(Bool::True,)» | ||
babydrop | Thanks | ||
ZzZombo | *m? | 14:20 | |
perlpilot | ZzZombo: no, .*m :) | ||
babydrop | m: class A { has $!a = "foo"; method m { put $!a } }; class B is A { has $!a = "bar"; method m { put $!a } }; B.new.*m | ||
camelia | rakudo-moar 843a6b: OUTPUT«barfoo» | ||
babydrop | ZzZombo: ^ there. does that make more sence? | ||
ZzZombo | yea | 14:21 | |
babydrop | ZzZombo: both classes have their own $!a with different value and you get different value depending on whose class's method you call | ||
ZzZombo | but what's this *m thing | ||
babydrop | same with your role example. | ||
.* method call calls the method on all classes in the MRO | |||
so it calls B's m, then A's m | 14:22 | ||
perlpilot | ZzZombo: There's also .?meth which I find useful and you may too. It's like "call meth if it exists" | ||
14:22
wamba left
|
|||
babydrop | m: use MONKEY; augment class Any { method m { put "meows!" } }; class A { has $!a = "foo"; method m { put $!a } }; class B is A { has $!a = "bar"; method m { put $!a } }; B.new.*m | 14:22 | |
camelia | rakudo-moar 843a6b: OUTPUT«barfoomeows!» | ||
babydrop | And here I added `m` to Any too, so it called that too | 14:23 | |
14:23
cygx joined
|
|||
cygx | o/ | 14:23 | |
babydrop | \o\ | ||
cygx | perhaps a shorter example in P6 would help | ||
m: role Named { has $.name; method !rename($name) { $!n | |||
ame = $name } }; class A does Named { submethod TWEAK { $!name = "default" } }; | |||
class B is A { method rename($name) { self!A::rename($name) } }; my $b = B.new | |||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Missing blockat <tmp>:1------> 3 has $.name; method !rename($name) { $!n7⏏5<EOL> expecting any of: statement end statement modifier statement modifier loop» | ||
cygx | ; say $b.name; $b.rename("seuss"); say $b.name | ||
babydrop | hehehe | ||
cygx | c&p fail | 14:24 | |
ZzZombo | nicely failed | ||
cygx | m: role Named { has $.name; method !rename($name) { $!name = $name } }; class A does Named { submethod TWEAK { $!name = "default" } }; class B is A { method rename($name) { self!A::rename($name) } }; my $b = B.new; say $b.name; $b.rename("seuss"); say $b.name | ||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Cannot call private method 'rename' on package A because it does not trust Bat <tmp>:1------> 3od rename($name) { self!A::rename($name)7⏏5 } }; my $b = B.new; say $b.name; $b.ren» | ||
cygx | how would I implement something like that without having to trust all child classes beforehand | ||
ZzZombo | yeah, that trust thing | ||
just what I had described there as well | 14:25 | ||
wha solutions exist for that? | 14:26 | ||
BRB, dinner. | |||
babydrop | m: gist.github.com/zoffixznet/fafbdd1...c3bb108edc | 14:29 | |
camelia | rakudo-moar 843a6b: OUTPUT«defaultseuss» | ||
babydrop | IMO the mistake you're making is having the assumption that subclases must have privilidged access to ancestor's private guts | ||
moritz | cygx: right, make it a public attribute | ||
anyone can subclass your class, so it must be a stable API and documented anyway | 14:30 | ||
ZzZombo | But what if I wanna have my own TWEAK, for example, and also the one from the role? | 14:31 | |
14:31
CIAvash joined
14:32
eisen74 joined,
CIAvash left
|
|||
cygx | "even though you can set the name via .name = ..., use .rename(...) instead" | 14:32 | |
14:32
nightfrog joined
|
|||
cygx | that's smelly | 14:32 | |
babydrop | That's where jnthn's article comes in about thinking of messages in OO :) | 14:33 | |
( 6guts.wordpress.com/2016/11/25/per...ood-thing/ ) | 14:34 | ||
cygx | rename is a perfectly fine message | ||
the issue is a failure to express certain relationships without breaking encapsulation | 14:35 | ||
14:35
cdg left
|
|||
babydrop | It may be, but why is it in a subclass? :) | 14:35 | |
dalek | c: 4a5da6b | coke++ | xt/words.pws: learn new "word" |
14:36 | |
14:36
cdg joined
14:37
skids joined
|
|||
cygx | babydrop: having MutableVersion inherit from ImmutableVersion can be useful | 14:38 | |
pmurias | cygx: if you want to break encapsulation you have to use trusts | 14:39 | |
babydrop | cygx: well, we have List/Array, Map/Hash, Set/SetHash, Bag/BagHash, Mix/MixHash in core.... as mutable complements to the immutable ones. Do they have the issue you describe? | ||
pmurias | if class B was aware that class was using a Named role it would be break encapsulation | 14:40 | |
cygx | think about it this way: there are internal methods, infrastructural methods and interface methods | 14:45 | |
subclasses may require access to infrastructural methods, so in p6 they have to be promoted to the interface | |||
14:46
cdg left
|
|||
cygx | naming conventions can help with that, eg SHOUTING | 14:47 | |
14:48
cdg joined
|
|||
babydrop | "PHP Parse error: syntax error, unexpected '='" | 14:48 | |
That's what Perl6-ism of using kebob-case looks like in PHP :) | 14:49 | ||
14:56
avalokite left
14:57
lukaramu joined
14:59
firstdayonthejob left,
vendethiel joined
|
|||
ZzZombo | cygx: yes, I'm still not sold on that protected visibility is bad and therefore P6 is fine w/o it. | 14:59 | |
that exactly why it was invented. | 15:00 | ||
15:03
seatek left
|
|||
babydrop | What's protected visibility? | 15:04 | |
pmurias | only subclasses can access it | ||
babydrop | If your subclass is using my $!name, that means I can't rename it something else willy nilly. | ||
Without breaking that subclass. That's why it's private | 15:05 | ||
moritz | aka "you have to wear a funny yellow hat to see my privates" | ||
babydrop | hheh | ||
pmurias | babydrop: protected ones are not privates just, "it's public but you shouldn't use it on a whim, so we add an arbitary restriction" | 15:06 | |
babydrop | :/ | ||
cygx | in Java, funny hat means subclass and/or same package | ||
moritz | forcing people who *really* need to write subclasses, instead of using a more appropriate relationship | ||
forcing people who *really* need to access the attribute to write subclasses, instead of using a more appropriate relationship | 15:07 | ||
that's what I meant | |||
cygx | that's why if I were to design an OO system, I'd invert the trust relationship | ||
"on request, give me access to stuff that you deem infrastructural" | |||
pmurias | that breaks encapsulation | 15:08 | |
moritz | cygx: isn't that exactly what 'trusts' does? The author of the subclass requests access, and you trust it in the parent class | ||
cygx | so does slapping an "is rw" on things to make my example code work | ||
moritz: no, because it requires the truster to know about all trustees, instead of marking things accessible to anyone who requests access | 15:09 | ||
babydrop | cygx: I think you took my version of your example too literally. You don't "slap" `is rw`. You design proper interface. | 15:10 | |
15:10
eisen74 left
|
|||
moritz | cygx: I don't understand what benefits the "requesting access" step gives if it's granted automatically, always | 15:10 | |
15:11
g4 left
|
|||
pmurias | seperates the clean suggested API from the dirty infrastructual methods? | 15:11 | |
cygx | moritz: it's granted on request and keeps the public API clean | ||
pmurias: exactly | |||
babydrop | cygx: but then nothing is private? Or are you proposing an "it's their own dumb fault" as a response for anyone who uses ancestor's privates willy-nilly, when their code breaks all of a sudden? | 15:13 | |
cygx | no, you have to be declare which privates to make accessible on request, instead of who can touch them (as is the current approach) | 15:14 | |
s/to be/to/ | 15:15 | ||
pmurias | cygx: the ones that are accessible on request are not privates | 15:16 | |
babydrop | Then they no longer privates. I can't change them without breaking someone's code. | ||
pmurias | cygx: you could use a naming convention | ||
cygx | pmurias: indeed, cf irclog.perlgeek.de/perl6/2016-11-30#i_13655193 | 15:17 | |
babydrop | And I bet such a thing can be done with a trait on a method | 15:18 | |
So, in return to ZzZombo not buying things, I'm not buying that this paradigm is impossible in Perl 6 or that the system defeats itself or whatever that gist said. | 15:19 | ||
ZzZombo | but nobody has shown a way to do so, did they? The suggested workaround to hack into class internals and trust subclasses this way is dirty and dosn't allow for selective exposure of certain members only. | 15:21 | |
babydrop | ZzZombo: so that somehow means it's impossible? | 15:22 | |
ZzZombo: I'd show, but I have X amount of other things to take care of. | |||
ZzZombo: or rather, I'd try to make an `is protected` trait. I have no guarantee it works, since I don't know traits. | |||
And it'd install a check on a normally-public method to croak unless the class asked for protected attributes | 15:23 | ||
cygx | another approach besides noming convention: gist.github.com/cygx/a3de36abd3984...f13bd619e4 | ||
babydrop | or methods. And that would be obtained from caller() on a method that must be called to obtain access to prootected stuff | ||
callframe I mean | 15:24 | ||
ZzZombo | docs.perl6.org/type/$AMPERSAND$QUE..._MARKBLOCK is dead link on docs.perl6.org/type/CallFrame | 15:28 | |
babydrop | m: class A { method trustme ($who) { trusts $who }; method !meow { say "meow" } }; class B is A { BEGIN A.trustme(B); method meow { self!A::meow } } | ||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>An exception occurred while evaluating a BEGINat <tmp>:1Exception details: 5===SORRY!5=== Error while compiling  Cannot invoke this object (REPR: Null; VMNull) at :» | ||
babydrop | something like this I envisioned | ||
dunoo how to make it work or whatever | 15:29 | ||
And we can make our own metaclasses, I'm sure we can do something like that. | |||
Oh, I guess this is different from what I originally said. | 15:30 | ||
ZzZombo | That would be useful if you could arbitrarily attach a different one to a type. I've found no such way though. | 15:31 | |
15:31
firstdayonthejob joined
15:43
cibs left,
khw joined
|
|||
pmurias | cygx: that breaks polymorphisms | 15:44 | |
15:44
cibs joined
|
|||
cygx | pmurias: which 'that'? | 15:45 | |
15:45
user9 left
|
|||
pmurias | cygx: using a global sub | 15:45 | |
15:45
wamba joined
|
|||
[Coke] has a brief concern over bdf's new advent post title. | 15:46 | ||
(sounds very perl fivey. :) | |||
babydrop | huggable: advent | ||
huggable | babydrop, github.com/perl6/mu/blob/master/mi...6/schedule | ||
jnthn | Object hashes? | 15:47 | |
[Coke] | 9 slots still open. 9 days til first open slot (zoffix probably overburdened at 3 posts) | ||
jnthn doesn't even know if Perl 5 has those... | |||
babydrop | [Coke]: yeah, reminds me of Perl 5 too... but I don't really know what he'll write about | ||
jnthn | I mean, I figure it's about `my %hash{Mu}` | ||
That is, hashes with object keys | |||
babydrop | jnthn: the most common way to make an object in Perl 5 is to `bless` a hash :) | ||
jnthn | That was my first guess anyway :) | ||
babydrop: Sure, but I don't think I've ever called that an object hash ;) | 15:48 | ||
babydrop | true :) | ||
jnthn | Maybe a hash object but... :) | ||
cygx | pmurias: how is that a problem for my use case? the inheritance chain is known statically | 15:49 | |
ZzZombo | babydrop: that still lacks selectiveness. You trust all or nothing, so it doesn't emulate protected access very well. | 15:50 | |
15:51
user9 joined
|
|||
pmurias | cygx: if you inherit from B you can't override A::rename | 15:51 | |
babydrop | ZzZombo: selectiveness of what? | ||
ZzZombo | what members allows access to | 15:52 | |
allow* | |||
cygx | pmurias: sure - you'd have to override make-me-a-foo | ||
babydrop | ZzZombo: in the example above yeah | ||
ZzZombo: but I think it should be possible to make a trait that you mark methods with. Methods that in your code you'll write as public. And if they're accessed like normal public methods, the trait will croak, but if a class requested access to them, then they'll function normally, like public methods | 15:54 | ||
s: &trait_mod:<is>, \(:export) | |||
SourceBaby | babydrop, Something's wrong: ERR: Could not find candidate that can do \(:export) in sub sourcery at /home/zoffix/services/lib/CoreHackers-Sourcery/lib/CoreHackers/Sourcery.pm6 (CoreHackers::Sourcery) line 37 in block <unit> at -e line 6 | ||
babydrop | s: &trait_mod:<is>, \(:export, |c) | 15:55 | |
SourceBaby | babydrop, Something's wrong: ERR: ===SORRY!=== Error while compiling -eUndeclared routine: c used at line 6 | ||
babydrop | blahg | ||
15:55
eisen74 joined
16:00
wamba left
|
|||
nicq20 | ufobat: Are you online? | 16:01 | |
16:01
wamba joined
|
|||
babydrop | how come we don't sign R* releases.. | 16:02 | |
cygx | pmurias: having thought on it a bit longer, I agree that there are probably cases where not being virtual could be an issue | ||
so for now, naming convention its is... | |||
16:03
jonas1 left
|
|||
nicq20 | Anyone know if Bailador supports being a HTTPS server? | 16:09 | |
babydrop | You can always drop it behind reverse proxy | ||
16:11
domidumont left
16:16
Wiertek93 joined,
Wiertek left
|
|||
ufobat | nicq20, yes i am there | 16:16 | |
nicq20 | ufobat: Sorry, for bothering you. I was trying to figure out if Bailador supports being a HTTPS server. From what I can tell it does not, but I can get around that using a reverse proxy like babydrop suggested. | 16:18 | |
ufobat | no worries | ||
github.com/ufobat/Bailador/blob/ma...dor.pm#L97 | |||
it depends on the http:: whatever module you want to use | 16:19 | ||
nicq20 | ufobat: Oh, ok. Makes sense. :) | 16:20 | |
ufobat | you could use different http backends, some work | ||
some wont :-/ | |||
nicq20, github.com/ufobat/Bailador#get-psgi-app there is a method you need if you want to use a different http backend | 16:22 | ||
nicq20 | ufobat: Do you happen to know of one that would support being a HTTPS server? I looked at a few of them and it seems that none of them support it. :( | ||
ufobat | sorry, i dont know it :-( | 16:23 | |
nicq20 | ufobat: That's ok, I'll just use the reverse proxy method. Thatnk you! :D | ||
*thank | |||
ufobat | i would .. yeah exactly :) | ||
16:24
andrzejku joined
|
|||
ufobat | gl with it :) | 16:24 | |
16:25
andrzejku left
|
|||
ufobat | does anyone know if the london workshop talks will be on youtube? | 16:27 | |
16:28
Wiertek joined
16:30
Wiertek93 left
16:32
lizmat joined
16:33
Wiertek left
|
|||
ilmari | ufobat: #london.pm on irc.perl.org is probably a better place to ask | 16:35 | |
16:39
andrzejku joined
|
|||
babydrop | "The Perl 6 organization has their default repository permission set to write. This means that every member of this organization has write access to this repository, regardless of the team and collaborator access specified below." | 16:39 | |
So what's `write` access? Does that mean anyone in P6 org can push to it? | |||
babydrop assumes the default's good and moves on | 16:41 | ||
ufobat | ilmari, aye, thanks :) | 16:42 | |
16:47
Actualeyes left
16:51
Actualeyes joined
|
|||
dalek | b-rakudo: e8a69fe | (Zoffix Znet)++ | / (4 files): First working version of download page viewer |
16:51 | |
16:54
andrzejku left
|
|||
dalek | b-rakudo: cc124ce | (Zoffix Znet)++ | download-page.php: Comment out commandline script usage hack |
17:00 | |
b-rakudo: fdc68cd | (Zoffix Znet)++ | download-page.css: Make PGP sig links less in-your-face |
|||
babydrop | I'm moving star/archive/ files to star/ 'cause the download page script now clearly shows the latest release of each kind anyway and adding support for folders like that is extra work. | 17:02 | |
ummm... apparently rakudo.org is running PHP version, and I quote, "<Woet> yea.. thats been end of life for so long its not even mentioned on the end of life page" | 17:09 | ||
.seen pmichaud | 17:10 | ||
yoleaux | I saw pmichaud 15 Sep 2016 01:34Z in #perl6: <pmichaud> m: my $input = '(\d\d\d)'; my $m = 'a 123' ~~ /$0=<$input>/; say $m | ||
17:12
dogbert2 left
|
|||
[Coke] | babydrop: should perl6/web-rakudo be under rakudo/ ? probably just a stylistic thing. | 17:12 | |
babydrop | .ask pmichaud any way we could touch base on rakudo.org maintenance? Could a person be given a sudo or something along those lines? We need HTTPs, upgraded Wordpress, and upgraded `php` + upgraded something else too, I'm sure | 17:13 | |
yoleaux | babydrop: I'll pass your message to pmichaud. | ||
babydrop | [Coke]: probably, I mentioned the need to create it in #perl6-dev but nothing happened, so I created it where I had the perms to create it in | ||
17:13
dogbert17 joined
|
|||
[Coke] | the distinction was mainly to enforce the copyright issue on the code, so it's fine. no worries. | 17:14 | |
17:17
Vynce joined
|
|||
dalek | c: 800e445 | (Jan-Olof Hendig)++ | doc/Type/Supply.pod6: Clarified what happens if the interval is small. See RT #130168 |
17:17 | |
synopsebot6 | Link: doc.perl6.org/type/Supply | ||
synopsebot6 | Link: rt.perl.org/rt3//Public/Bug/Displa...?id=130168 | ||
17:20
wamba left
17:21
andreoss joined
|
|||
andreoss | can i define "bottom" objects in perl6? (as Nil/Nothing in Scala or undefined in Haskell) | 17:22 | |
dalek | b-rakudo: 4b7416f | (Zoffix Znet)++ | download-page.php: Add array workaround to support ancient PHP |
17:23 | |
timotimo | well, every type has its type object to stand in for an undefined value | ||
moritz is on his way to Berlin, to give a Perl 6 training | |||
and amazingly, the airport has free wifi. I thought German province uncapable of such advances :-) | 17:24 | ||
andreoss | m: class Foo {}; my Foo $x = Nil; say $x.^mro | 17:27 | |
camelia | rakudo-moar 843a6b: OUTPUT«((Foo) (Any) (Mu))» | ||
andreoss | how does this work? | ||
babydrop | andreoss: Nil is absence of value, so $x gets its default() whose default is Any | 17:29 | |
Oh | |||
andreoss: this being what? | |||
m: class Foo {}; my Foo $x; dd $x | 17:30 | ||
camelia | rakudo-moar 843a6b: OUTPUT«Foo $x = Foo» | ||
andreoss | m: role Abst { has $.x = die }; class Foo does Abst { has $.x = 1 }; class FooNil is Nil does Abst { has $.x = 2 }; my Abst $x = FooNil.new ; say $x, $x.^mro | ||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Attribute '$!x' already exists in the class 'Foo', but a role also wishes to compose itat <tmp>:1» | ||
babydrop | Oh, I guess when used that way the default is the type you specified | ||
m: my $x is default('meow'); dd $x | |||
camelia | rakudo-moar 843a6b: OUTPUT«Str $x = "meow"» | ||
andreoss | by this I mean Nil being subtype of Foo | ||
babydrop | You lost me | 17:31 | |
Nil passes type checks | |||
m: sub foo () returns Int { 42 }() | 17:32 | ||
camelia | ( no output ) | ||
babydrop | m: sub foo () returns Int { 'meow' }() | ||
camelia | rakudo-moar 843a6b: OUTPUT«Type check failed for return value; expected Int but got Str ("meow") in sub foo at <tmp> line 1 in block <unit> at <tmp> line 1» | ||
babydrop | m: sub foo () returns Int { Nil }() | ||
camelia | ( no output ) | ||
babydrop | see | ||
s/passes/bypasses/; | |||
andreoss | what if I want my own class to bypass this ? | 17:33 | |
m: role Abst { }; class Foo does Abst { has $.x = 1 }; class FooNil is Nil does Abst { has $.x = 2 }; my Abst $x = FooNil.new ; say $x.WHAT; say $x.x | |||
camelia | rakudo-moar 843a6b: OUTPUT«(Abst)No such method 'x' for invocant of type 'Abst' in block <unit> at <tmp> line 1» | ||
babydrop | andreoss: any subclasses of Nill also bypass typecheck IIRC | 17:34 | |
17:34
wamba joined
|
|||
timotimo | that's right | 17:36 | |
Failure will bypass, as well | |||
moritz | m: class Foo is Nil { }; sub f(Int:D $x) { }; f Foo.new | ||
camelia | rakudo-moar 843a6b: OUTPUT«Type check failed in binding to $x; expected Int but got Nil (Nil) in sub f at <tmp> line 1 in block <unit> at <tmp> line 1» | ||
moritz | m: class Foo is Nil { }; sub f(Int $x) { }; f Foo.new | 17:37 | |
camelia | rakudo-moar 843a6b: OUTPUT«Type check failed in binding to $x; expected Int but got Nil (Nil) in sub f at <tmp> line 1 in block <unit> at <tmp> line 1» | ||
moritz | only in assignment to variables, it seems | ||
andreoss | m: my Int:D $x = Nil.new | ||
camelia | rakudo-moar 843a6b: OUTPUT«Type check failed in assignment to $x; expected type Int:D cannot be itself (perhaps Nil was assigned to a :D which had no default?) in block <unit> at <tmp> line 1» | ||
babydrop | Oh, only return type constraints | ||
oh no, that's the :D failing | 17:38 | ||
m: class Foo is Nil { }; sub f(Int $x) { }; f Nil | |||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Calling f(Nil) will never work with declared signature (Int $x)at <tmp>:1------> 3lass Foo is Nil { }; sub f(Int $x) { }; 7⏏5f Nil» | ||
andreoss | so Nil is not a subclass of every class, just a compiler trick? | ||
babydrop | m: class Foo is Nil { }; sub f(Int $x?) { }; f Nil | ||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Calling f(Nil) will never work with declared signature (Int $x?)at <tmp>:1------> 3ass Foo is Nil { }; sub f(Int $x?) { }; 7⏏5f Nil» | ||
babydrop | andreoss: Nil is absence of value | ||
That's its use | |||
ugh.... the logos aren't showing up on my download page when I host it off rakudo :S | 17:40 | ||
andreoss | what if I want an abstract class (A), classes which implement A (B, C, D...) and a "bottom" class (Z) which is subtype of them all | ||
babydrop | I've no idea what either "bottom" or "subtype" mean :/ | 17:41 | |
andreoss | *subclass | ||
[Coke] | moritz: Perl 6 Training! Sehr güt! | ||
moritz | [Coke]: I hope it will be :-) | ||
babydrop | andreoss: ok, what do you mean by "bottom" tho? | 17:42 | |
cygx | andreoss: you can't really do that in p6 | ||
andreoss | en.wikipedia.org/wiki/Bottom_type | ||
cygx | andreoss: as far as I'm aware, you'd have to do something like `subset BOrBottom where B | Bottom` and use that everywhere instead of B | 17:43 | |
17:49
andreoss left
17:51
CIAvash joined,
CIAvash left
17:58
labster joined
|
|||
babydrop | huh | 17:59 | |
TIL: I can't copy-paste files with uber-long lines into a ssh session | |||
That's why the logos weren't showing up. The base64 background image URLs got abridged :/ | 18:00 | ||
18:03
dakkar left
18:05
nicq20 left
|
|||
dalek | b-rakudo: 42ca829 | (Zoffix Znet)++ | download-page.htaccess-sliver: Include domain in Redirect rule Server on rakudo.org doesn't support domainless rule |
18:06 | |
timotimo | moritz: yeah, binding is what signatures do, and binding Nil will not do the magic "reset to default value" thing | ||
18:06
andrzejku joined
|
|||
babydrop | ah | 18:06 | |
m: say 42 ~~ Nil | 18:07 | ||
camelia | rakudo-moar 843a6b: OUTPUT«False» | ||
18:07
mohae joined
|
|||
babydrop | Aanndd... my stuff's live rakudo.org/downloads/star/ | 18:13 | |
huzzah | 18:14 | ||
18:15
zacts left
|
|||
babydrop | .tell stmuk_ FYI, I've moved star/archive into just star/ since the new download page shows clearly what the latest releases are and not having to code for archive/ is less code. Also, there's no longer a need to update the `-latest-` URLs after each release, so I sent a PR to remove that from release guide | 18:18 | |
yoleaux | babydrop: I'll pass your message to stmuk_. | ||
babydrop | tbrowder: rakudo.org/downloads/rakudo/rakudo-latest.tar.gz | 18:19 | |
18:23
andrzejku left
18:26
domidumont joined
|
|||
babydrop | oh shit | 18:30 | |
I'm blind as a duck lol :) | |||
For some reason the page sorts different extensions together | 18:31 | ||
I mean same extensions together | |||
18:34
wamba left
|
|||
babydrop | s/some reason/I see why/; | 18:34 | |
18:37
pierre_ left
18:39
zacts joined
|
|||
pmurias | what would be a good tool to chart/track memory use of process? (node.js running rakudo.js) | 18:39 | |
dalek | b-rakudo: f52241f | (Zoffix Znet)++ | download-page.php: Use different way to filter pgp sig files The brace glob() returns result sorted by extension groups and we don't want that. |
||
[Coke] | pmurias: stackoverflow.com/questions/200185...of-node-js ? | 18:40 | |
18:51
ggoebel left
18:54
andrzejku joined
19:03
xylixy joined
19:04
xylixy left
19:06
setty1 joined
19:08
AlexDaniel joined
19:09
pecastro joined
19:10
darutoko left
|
|||
timotimo | babydrop++ # fantastic download page | 19:21 | |
19:28
domidumont left
|
|||
babydrop | \o/ | 19:30 | |
samcv: what top bar? | 19:32 | ||
19:32
Goros joined
|
|||
babydrop | samcv: you mean on rakudo.org/ ? | 19:32 | |
19:32
Goros left
|
|||
babydrop shrugs | 19:33 | ||
I'll leave it for those who like working with Wordpress :) | |||
19:35
wamba joined
|
|||
babydrop | FWIW the accepted answer on this SO confuses even me: stackoverflow.com/questions/4081493...e-elements | 19:36 | |
19:38
ggoebel joined,
pierre_ joined,
cdg left
19:42
pierre_ left
|
|||
dalek | c: 7d2a711 | coke++ | doc/Language/variables.pod6: Remove section calling $<> a $< twigil - closes #998 |
19:43 | |
synopsebot6 | Link: doc.perl6.org/language/variables | ||
19:45
RabidGravy joined
|
|||
babydrop | m: class Foo is Rat is Str {has $!numerator = 42; has $!denominator = 55}; my Rat $r = Foo.new | 19:47 | |
camelia | ( no output ) | ||
babydrop didn't realize that would work :\ | |||
m: class Foo {}; class Bar is Foo {}; has Foo $x = Bar.new | 19:48 | ||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>You cannot declare attribute '$x' here; maybe you'd like a class or a role?at <tmp>:1------> 3 Foo {}; class Bar is Foo {}; has Foo $x7⏏5 = Bar.new expecting any of: constraint» | ||
19:48
itaipu left
|
|||
babydrop | wat? | 19:48 | |
oh | |||
:) | |||
m: class Foo {}; class Bar is Foo {}; my Foo $x = Bar.new | 19:49 | ||
camelia | ( no output ) | ||
babydrop | Oh ok. I see my confusion now. | ||
19:51
cibs left
|
|||
AlexDaniel | m: my \selfie = π; say selfie | 19:52 | |
camelia | rakudo-moar 843a6b: OUTPUT«3.14159265358979» | ||
19:52
cibs joined
|
|||
AlexDaniel | m: my \self = π; say self | 19:52 | |
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>'self' used where no object is availableat <tmp>:1------> 3my \self = π; say 7⏏5self expecting any of: argument list term» | ||
mspo | m: say self.WHAT | 19:54 | |
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>'self' used where no object is availableat <tmp>:1------> 3say 7⏏5self.WHAT expecting any of: argument list term» | ||
19:54
andrzejku left
|
|||
dalek | c: 4ba2aff | (Zoffix Znet)++ | doc/Type/ (4 files): Use clearer language in allomorphs - Avoid magicalness. They're just subclasses. - Explicitly show they don't share object identity, in, e.g. set operatoions - Fix broken ComplexStr example that used a literal Complex instead of the allomorph. |
19:57 | |
babydrop | m: my \sеlf = π; say sеlf | 19:58 | |
camelia | rakudo-moar 843a6b: OUTPUT«3.14159265358979» | ||
babydrop doesn't see a problem :) | |||
19:59
AlexDaniel left
|
|||
dalek | c: 6f9f3be | coke++ | doc/Type/Instant.pod6: Reword Leap Second Blurb Closes #768 |
20:00 | |
synopsebot6 | Link: doc.perl6.org/type/Instant | ||
20:01
itaipu joined
20:05
kurahaupo__ joined
|
|||
stmuk_ | babydrop: I would have rather the pre-releases would have remained under 'archive' since I think having them obviousily visible is just confusing | 20:05 | |
yoleaux | 18:18Z <babydrop> stmuk_: FYI, I've moved star/archive into just star/ since the new download page shows clearly what the latest releases are and not having to code for archive/ is less code. Also, there's no longer a need to update the `-latest-` URLs after each release, so I sent a PR to remove that from release guide | ||
babydrop | stmuk_: you mean the pre-Christmass stuff? | ||
20:05
kurahaupo__ is now known as kurahaupo
20:07
nchambers left,
nchambers joined,
girafe joined
20:08
obfusk left
20:09
obfusk joined
|
|||
babydrop | I'll add back the archive.. on the weekend or Friday | 20:10 | |
20:10
domidumont joined
20:12
andrzejku joined
|
|||
dalek | b-rakudo: 14683f3 | (Zoffix Znet)++ | download-page.htaccess-sliver: Fix typo in rakudo `latest` URL asset name tbrowder++ |
20:13 | |
stmuk_ | babydrop: thanks | 20:14 | |
its just I see no advantage and much risk in enabling people to easily download 2010.07 versions etc | |||
babydrop | Sure. | ||
stmuk_ | BTW I was wondering if anyone had ran a WP security scanner recently :/ | 20:15 | |
babydrop | Well, I'm sure we have holes :) | 20:16 | |
We need an update of stuff | |||
Folks in #php didn't want to help me with my script because of how ancient our php installation is | 20:18 | ||
stmuk_ | :) | 20:19 | |
20:23
domidumont left
20:25
eisen74_ joined,
girafe2 joined
20:27
eisen74 left
20:28
girafe left
|
|||
moritz hates wifi that blocks port 22 | 20:28 | ||
mst | I remember when my father was in a hospice | 20:29 | |
I borrowed every spare 443 on shadowcat's systems to get enough tunnels out of there I could do ssh and he could use email ;) | |||
stmuk_ | tunnel over dns? :) | 20:30 | |
jonadab | stmuk_: tunnel IP over IP, more like. | ||
moritz | I have a host with ssh on port 443 that I can use for tunnels | 20:33 | |
20:35
firstdayonthejob left
|
|||
moritz | is it coincidence that the wifi disconnected me as soon as I googled "ssh jumphost configuration"? :-) | 20:40 | |
now using tethering over the mobile phone. At least there's decent LTE connection. | 20:41 | ||
20:43
wisti joined
20:44
raiph joined
20:45
firstdayonthejob joined
|
|||
stmuk_ | I just had to tender since a chromecast (powered off for months) went all windows update on us | 20:46 | |
20:49
skids left
20:51
Tonik left
20:58
eisen74_ left
21:04
cdg joined
|
|||
yoleaux | AlexDaniel: harass mst | 21:11 | |
timotimo | what. | 21:15 | |
babydrop | hehe :) | 21:17 | |
timotimo, irclog.perlgeek.de/perl6/2016-11-28#i_13643736 | |||
[Coke] | pod6 - any idea what I did wrong here? gist.github.com/coke/1946617c44717...e5cc518098 | ||
babydrop | is =pod ok instead of =end pod? | 21:18 | |
[Coke] | heh. | 21:19 | |
no, just saw that. | |||
timotimo | ah | ||
21:19
Matthew[m] left,
tadzik left,
ilmari[m] left,
Matias[m] left,
dp[m] left,
M-Illandan left
|
|||
MilkmanDan | Nice to see that the new Llama/Butterfly KS book is getting close to funded. | 21:23 | |
21:23
andrzejku left,
ChoHag left
|
|||
babydrop | ayeah | 21:24 | |
MilkmanDan | $32,012 pledged of $37,000 goal 384 backers | ||
21:24
TEttinger joined
|
|||
MilkmanDan | Any word on the new Camel Book? | 21:24 | |
[Coke] | nope | 21:26 | |
21:29
bjz left
|
|||
timotimo is without credit card | 21:29 | ||
21:38
ChoHag joined
|
|||
dudz | oh nice, almost there MilkmanDan | 21:39 | |
though not enough backers | 21:40 | ||
but with the monetary we can get started i reckon, keep our community small | |||
MilkmanDan | dudz: There is time to get more. :) | ||
dudz | :) | ||
once something gets big it must be abandoned anyway | 21:41 | ||
amazon, microsoft, google. | |||
[Coke] wonders why building the docs generates so many duplicated path warnings. | |||
Do we want to avoid duplication (fix the problem avoid the warning) or do we not care (don't emit the warning) | 21:42 | ||
babydrop | dudz, but those are evil corporations, not ideas :) | 21:43 | |
dudz | :) | ||
21:47
cygx left,
kyclark joined
|
|||
kyclark | I would expect the answer to this to be 1: | 21:47 | |
m: put ((1,2)).elems | |||
camelia | rakudo-moar 843a6b: OUTPUT«2» | ||
kyclark | While this would be 2: | ||
timotimo | extra parenthesis doesn't change anything | ||
kyclark | m: put ((1,2), (3,4)).elems | ||
camelia | rakudo-moar 843a6b: OUTPUT«2» | ||
timotimo | m: put ((1,2),).elems | 21:48 | |
camelia | rakudo-moar 843a6b: OUTPUT«1» | ||
timotimo | ^- that's what you want | ||
kyclark | Ah, hmm, OK. | ||
I’m struggling with turing a list of lists (tuples, really) into a hash | |||
Backing up, I have a two-column file that I want to ‘file’.IO.lines.map(*.split(/\t/) -> hash | 21:49 | ||
But I have to .flat.pairup to make it work. Seems overkill. | |||
Any suggestions? | |||
21:50
bjz joined
|
|||
timotimo | hm, you really need to do the pairup? i thought a flat list of values coerced to a hash gives you key, value, key, value, ... | 21:50 | |
but it could be .flat doesn't do enough and you have to .list or something | |||
kyclark | No, you’re right. That works. | ||
21:51
itaipu left
|
|||
kyclark | So that’s the best way, then? | 21:51 | |
jnthn | m: my %h = flat "a\t1\nb\t2\n".lines.map(*.split(/\t/)); say %h.perl | ||
camelia | rakudo-moar 843a6b: OUTPUT«{:a("1"), :b("2")}» | ||
timotimo | you can split on two different separators | ||
with a single call, i mean | |||
kyclark | Can you show? | 21:52 | |
timotimo | oh, also: it'll be a thousand times faster to split on "\t" instead of /\t/ | ||
kyclark | Noted. | 21:53 | |
timotimo | m: my %h = flat "a\t1\nb\t2\n".split(("\t", "\n")); say %h.perl | ||
camelia | rakudo-moar 843a6b: OUTPUT«X::Hash::Store::OddNumber exception produced no message in block <unit> at <tmp> line 1» | ||
timotimo | m: my %h = flat "a\t1\nb\t2\n".chomp.split(("\t", "\n")); say %h.perl | ||
camelia | rakudo-moar 843a6b: OUTPUT«{:a("1"), :b("2")}» | ||
timotimo | m: my %h = flat "a\t1\nb\t2\n".split(("\t", "\n"), :skip-empty); say %h.perl | ||
camelia | rakudo-moar 843a6b: OUTPUT«{:a("1"), :b("2")}» | ||
timotimo | take your pick | ||
[Coke] | GAH. doc build is soooooooooooo slow | 21:54 | |
kyclark | Is it better than “lines”? | ||
timotimo | no | ||
it might be better than lines + split, though | |||
kyclark | “lines” seems to self-document | ||
timotimo | that's right | ||
kyclark | Since it’s a small file, I’ll stick with lines + split | ||
Thanks. | |||
[Coke] | it seems like every time I try to do some doc stuff I end up yak shaving. | ||
timotimo | nothing about that split call says "the \t and \n will always take turns" | ||
babydrop | Is flat even needed? | 21:57 | |
timotimo | oh | ||
not with the split invocation, i don't think | |||
babydrop | m: my %h = "a\t1\nb\t2\n".words; say %h.perl | ||
camelia | rakudo-moar 843a6b: OUTPUT«{:a("1"), :b("2")}» | ||
babydrop shrugs | |||
timotimo | well, with .words your code will b0rk if there's multiple words in a single field | ||
21:58
bjz left
|
|||
babydrop | #WorksOnMyComputer :) | 21:58 | |
[Coke] | DrForr: how close is your module to letting us do syntax highlighting of perl 6 from perl 6? | 21:59 | |
babydrop | m: my %h = "a\t1\nb\t2\n".comb: not("\n", "\t"); say %h.perl | ||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Calling not(Str, Str) will never work with proto signature (Mu)at <tmp>:1------> 3my %h = "a\t1\nb\t2\n".comb: 7⏏5not("\n", "\t"); say %h.perl» | ||
babydrop | heh | ||
oh, right, it's none, not not :) | 22:01 | ||
But it just autothreads, not uses it as a matcher | |||
timotimo | you mean none, not not | 22:02 | |
oh | |||
you noticed | |||
the result ought to be funny, though. one string split by one sep, the other by the other | |||
babydrop | nah, it just finds the stuff | 22:03 | |
m: dd "a\t1\nb\t2\n".comb: none("\n", "\t"); | |||
camelia | rakudo-moar 843a6b: OUTPUT«none(("\n", "\n").Seq, ("\t", "\t").Seq)» | ||
timotimo | oh | ||
babydrop | m: dd "a\t1\nb\t2\n".split: none("\n", "\t"); | ||
camelia | rakudo-moar 843a6b: OUTPUT«none(("a\t1", "b\t2", ""), ("a", "1\nb", "2\n"))» | ||
timotimo | i thought you had split | ||
babydrop | ehehe | ||
that's cool | |||
timotimo | well, check this out: | ||
m: say "cool" if "hello how are you".comb(any("a", "e", "i", "o", "u")) > 3 | 22:04 | ||
camelia | ( no output ) | ||
timotimo | m: say "cool" if "hello how are you".comb(any("a", "e", "i", "o", "u")) > 2 | ||
camelia | rakudo-moar 843a6b: OUTPUT«cool» | ||
timotimo | m: say perl "hello how are you".comb(any("a", "e", "i", "o", "u")) > 2 | ||
camelia | rakudo-moar 843a6b: OUTPUT«5===SORRY!5=== Error while compiling <tmp>Undeclared routine: perl used at line 1» | ||
timotimo | m: say ("hello how are you".comb(any("a", "e", "i", "o", "u")) > 2).perl | ||
camelia | rakudo-moar 843a6b: OUTPUT«any(Bool::False, Bool::False, Bool::False, Bool::True, Bool::False)» | ||
babydrop | I don't get it | 22:05 | |
Why does it think a Bool is > 2? | |||
oh | |||
OK :) | |||
Neat :) | |||
22:06
RabidGravy left
|
|||
babydrop | m: say "No repeating stuff!" if .comb(.comb.any) > 1 given "There is repeating stuff here" | 22:07 | |
camelia | rakudo-moar 843a6b: OUTPUT«No repeating stuff!» | ||
timotimo | that's not correct :) | 22:08 | |
you need unless there | |||
babydrop | well, it is if you read "No repeating stuff!" as a reprimand :) | ||
timotimo | oh | ||
well, right | |||
babydrop | m: say "there is no repeating stuff" unless .comb(.comb.any) > 1 given "There is repeating stuff here" | ||
camelia | ( no output ) | ||
perlpilot | That is some non-obvious behavior | 22:09 | |
babydrop | m: say "there is no repeating stuff" unless .comb(.comb.any) > 1 given "There is repeating stuff here".comb.Bag.join | ||
camelia | ( no output ) | ||
babydrop | :( | ||
m: say "there is no repeating stuff" unless .comb(.comb.any) > 1 given "There is repeating stuff here".comb.Bag.keys.join | |||
camelia | rakudo-moar 843a6b: OUTPUT«there is no repeating stuff» | ||
babydrop | \o/ | ||
perlpilot: it's advanced quantum stuff :D | |||
timotimo | %) | ||
stmuk_ | [+] WordPress version 4.6.1 (Released on 2016-09-07) identified from meta generator | 22:15 | |
looks like someone did update the WP! | |||
someone++ | |||
22:16
ilmari[m] joined
|
|||
babydrop | \o/ | 22:16 | |
22:16
kyclark left
|
|||
timotimo | hopefully with a fully functional backup | 22:17 | |
22:19
tadzik joined,
Matthew[m] joined,
M-Illandan joined,
Matias[m] joined,
dp[m] joined
22:23
kurahaupo left
|
|||
babydrop | huggable: advent | 22:25 | |
huggable | babydrop, github.com/perl6/mu/blob/master/mi...6/schedule | ||
timotimo | yo babydrop, will you try to come up with a topic for me to write about? :S | ||
dalek | : b6f9046 | (Zoffix Znet)++ | misc/perl6advent-2016/schedule: Add another zofspot "Perl 6 Is My Drummer: Playing Music With Grammars" |
22:26 | |
babydrop | Wanted to write that for perl6.party for ages, but always put it off :) Should be neat | 22:27 | |
timotimo | sounds neat, yeah | ||
will you be using PortMIDI for that? | |||
babydrop | Audio::MIDI::Note (which uses it under the hood) | ||
Gonna try to make it play through my keyboard and then record me on guitars with Perl 6 doing the drums :D | 22:28 | ||
(hence the title :P) | |||
*keyboard as in musical instrument | |||
timotimo | :D | ||
"through" your keyboard, as in: the keyboard receives midi and synthesizes sound? | |||
babydrop | yeah | 22:29 | |
timotimo | understood | ||
my keyboard is midi-only, so my laptop synthesizes for me | |||
not that i have anything interesting i can input into the keyboard yet | |||
babydrop | As for the topic... dunno. I'd personally would read it if you wrote something about MoarVM guts :) | 22:30 | |
stmuk_ | haha the 23rd isn't the most positive topic | 22:35 | |
22:35
AlexDaniel joined
|
|||
babydrop | stmuk_: AlexDaniel said that it'll be positive :) | 22:35 | |
22:46
girafe2 left
|
|||
AlexDaniel | moritz: by the way, I need the access to the advent thing | 22:48 | |
22:53
ufobat left
|
|||
AlexDaniel | do I have to create a wordpress account for that? | 22:54 | |
babydrop | Yes. | ||
AlexDaniel | “To get started, tell us what your blog or website is about.”… | 22:55 | |
Fashion / Beauty, yes | 22:56 | ||
timotimo | haha | ||
you could do that | |||
nothing wrong with that, really | |||
AlexDaniel | “What would you like your homepage to look like?” – wait, I don't need a blog! | ||
babydrop | Just click "Other" and mash on the keyboard :) | 22:57 | |
hm | 22:58 | ||
AlexDaniel | well, have to come up with a username | ||
babydrop | AlexDaniel: /msg me your email I think I can just add you | ||
AlexDaniel | alexdaniel is taken | ||
timotimo | alexDOOMiel | ||
22:59
cpage left,
cpage joined
|
|||
babydrop | "Invitation sent successfully" | 22:59 | |
timotimo | wait, what? | 23:00 | |
oh, email, not user name | |||
AlexDaniel | “Password must be at least 6 characters.” – okay, it didn't like my 64-char long password | 23:01 | |
To accept this invitation you will need to: 1. Signup for a WordPress.com account | |||
ok I need an account anyway | |||
timotimo | yeah | ||
geekosaur | *golfclap* | 23:02 | |
(password) | |||
babydrop | Yeah, but it prolly won't be asking you all those questions about creating a blog. | ||
I was hoping | |||
23:02
Vynce left
|
|||
AlexDaniel | okay, here is my new blog: alexdanielprincess.fashion.blog/ | 23:03 | |
babydrop | hehe | 23:04 | |
AlexDaniel | babydrop: thank you | 23:10 | |
23:16
firstdayonthejob left
23:20
lukaramu left
23:21
benchable6 left,
unicodable6 left,
committable6 left,
bisectable6 left,
evalable6 left
23:27
bisectable6 joined,
ChanServ sets mode: +v bisectable6,
bisectable6_ joined,
bisectable6__ joined
23:28
bisectable6 left,
bisectable6_ left,
bisectable6__ left
23:29
bisectable6 joined,
ChanServ sets mode: +v bisectable6
23:30
bisectable6 left,
unicodable6 joined,
committable6 joined,
ChanServ sets mode: +v committable6,
bisectable6 joined,
ChanServ sets mode: +v bisectable6,
evalable6 joined,
benchable6 joined,
pierre_ joined
23:32
unicodable6 left,
pierre_ left
23:35
Actualeyes left
23:37
unicodable6 joined
23:38
committable6 left
23:39
unicodable6 left,
committable6 joined,
ChanServ sets mode: +v committable6
23:42
seatek joined
|
|||
[Coke] | ... still building local docs | 23:55 | |
some of that time is from my commute home, but not most of it | 23:57 | ||
babydrop | :o | ||
timotimo | could be because of inline python vs invoking python for our syntax highlighting? | ||
23:58
rindolf left
|