»ö« | perl6.org/ | nopaste: paste.lisp.org/new/perl6 | evalbot usage: 'perl6: say 3;' or rakudo:, alpha:, pugs:, std:, or /msg p6eval perl6: ... | irclog: irc.pugscode.org/ | UTF-8 is our friend!
Set by lichtkind on 5 March 2010.
00:06 quietfanatic left
snarkyboojum wiki should be updated to state that viv is a perl 5 script that uses a converted/translated perl5 version of the standard grammar (via gimme5) to parse perl6 programs and dump an AST, Perl 5/6 representation etc. 00:20
that'd be heaps clear to me than what's currently on www.perlfoundation.org/perl6/index.cgi?viv
00:27 rindolf left
snarkyboojum is lichtkind the man for the job? :) 00:32
pugssvn r30055 | lwall++ | [STD] move MONKEY_TYPING check to where we're already looking at augment and supersede
ash_ \n is considered part of whitespace, correct? 00:40
pugssvn r30056 | lwall++ | [Cursor] don't try -1 subscript on empty array 00:42
TimToady correct
snarkyboojum phenny: tell lichtkind that I found the viv page on the perl6 wiki misleading, and to see if he thought my newbie interpretation was helpful at all - providing it's not wrong :) (see backscroll for 2010-03-13) 00:43
phenny snarkyboojum: I'll pass that on when lichtkind is around.
ash_ cool, thanks TimToady++
00:45 mssm left 00:47 nihiliad joined
pugssvn r30057 | lwall++ | [t/spec] add 'use MONKEY_TYPING' where appropriate 00:47
r30058 | lwall++ | [STD] just say "symbol" when we're not sure what kind of symbol 00:48
00:53 rv2733 left
TimToady expect rakudo regressions until someone adds a stub MONKEY_TYPING.pm 00:59
(it's okay if it doesn't do anything for now) 01:00
jnthn needs sleep
I'll do it tomorrow if nobody beats me to it.
(Will try and make it vaguely work-ish too.)
TimToady it wasn't hard, given dynamic vars 01:01
jnthn Aye
TimToady though I just hardwired the 'use' in STD
jnthn Just forbid augment and supercede in its absence, basically?
TimToady since I can't actually execute BEGINish code yet
pretty much 01:02
jnthn OK, should be easy enough.
TimToady it's currently allowed on slangs always
but perhaps 'augment' is the wrong word then
jnthn OK, we don't do slangs yet though. :-)
Will pop it in tomorrow. $otherjob needed lots of attention today.
TimToady night 01:03
jnthn night o/
colomon \o
01:11 hanekomu_ left
colomon TimToady: spectest just passed here despite your monkeying around. 01:21
01:22 lue joined
TimToady rakudo: use MONKEY_TYPING; 01:24
p6eval rakudo f04eb8: OUTPUT«Unable to find module 'MONKEY_TYPING'.␤current instr.: 'perl6;Perl6;Module;Loader;need' pc 33812 (src/gen/role_pm.pir:0)␤»
colomon maybe those tests aren't turned on? 01:25
TimToady it would have to be those test files
it would fail on the use 01:26
which is at the top, generally
lue oi! o/ 01:28
colomon \o 01:29
ingy TimToady: :) You still need IO.pod? 01:33
I'll give er a looksee when I get over this cold
lue perl6 --mode="doctor" --target="ingy" --treat="cold" 01:40
01:48 ash_ left 02:05 eternaleye joined 02:06 jferrero left 02:20 hudnix left 02:21 hudnix joined 02:38 am0c joined
lue hello? 02:50
sorear HELLO 02:53
lue Hello. (it is quiet around here...) 02:55
Come to the dark side of 楽土. We use cookies :) (horrible pun) 02:56
(although, a pun more suitable for javascript...) 02:57
sorear the dark side of what? 02:58
lue rakudo. That's the kanji for rakudo, which in japanese means paradise. 03:02
03:03 Chillance left
lue rakudo is ラクド in japanese katakana (in hiragana it's らくど), and that comes to the japanese kanji 楽土. 03:05
TimToady or it's short for 駱駝道, the Way of the Camel 03:09
lue Last I heard it was short for ラクダーど. ラクダ I know means camel, but all the translators choke on the ーど part. 03:11
TimToady you've got the lengthening in the wrong place 03:16
らくだどう。
bbl & 03:17
lue alright. (jeez, I really need to learn 日本語.) 03:18
sorear also, you're using the wrong character set 03:23
I think
lue character set?
sorear notice how you're using katakana and TimToady is using hirigana 03:24
lue I prefer the look of katakana :)
If I were typing actual japanese, I'd pay attention to that. For example:
03:25 Trashlord joined
sorear personally I think you should just say "rakudo" 03:25
lue for possesive, I leave it の as opposed to changing it to ノ (by default it types in hiragana on this machine): ゼルダの伝説 03:26
(notice the name "Zeruda" is in katakana)
sorear: I know, but 楽土 just looks awesome :)
sorear: You'll find I do type rakudo a lot, I just use 楽土 when I feel like it. 03:27
sorear pity it's unmemorable to 90%+ of the tech community
<kanji><kanji> has bad google uniqueness properties
lue Oh, I believe japanese is a job requirement in the tech world. (especially if you're a fan of Nintendo :D ) 03:28
時の楽土 :) 03:30
daemon Kind of like alcoholism 03:32
if you do a lot of backend work
especially perl and python ;)
lue Hey, if your P6 implementation can't handle the string 駱駝, then it's not a real P6 implementation :) 03:33
afk &
sorear How does the Parrot events and asynchronous IO stuff get exposed in P6-space? 03:35
03:49 quietfanatic joined 03:52 jaldhar left
TimToady as far as I know, parrot doesn't actually do any of that yet 03:58
04:05 wknight8111 left
sorear Is there (going to be) any way to access interlanguage stuff from P6, separate from imports? 04:21
04:25 jaldhar joined 04:27 nihiliad left
sorear When you say use Foo:from<perl5>; does anything interesting happen, or does it just use perl5;Foo instead of perl6;Foo in the Parrot import? 04:35
04:36 am0c left
bkeeler I believe it's supposed to fetch the compiler object for the other language and sort of delegate to it somehow 04:43
sorear but...how 04:44
bkeeler Check pdd31_hll.pod in the parrot docs 04:45
04:46 rv2733 joined
sorear thnaks 04:49
bkeeler Interesting reading. I hadn't actually checked into it before
sorear now I just need to come up with, uh, sane semantics for Parrot<->Perl5 calling 04:56
it would be fairly easy if Perl5 parameters weren't in/out and hash references weren't so ubiquitous 04:58
bkeeler Yeah, that's gotta be a tricky task
sorear Actually I can probably just ask jnthn 04:59
Hopefully he has most of this figured out
bkeeler in bliztcost or whatever he calls it?
sorear yes
bkeeler I hope that works out, it will be a huge boost to parrot 05:00
sorear I can make it work to the level of a FFI 05:05
I have little clue if it can be made transparent
partly because I don't actually understand the Parrot interop specifications 05:06
and - with only one serious Parrot HLL - I have no example code to read
I hate trailblazing
bkeeler I know what oyu mean
sorear I can ask questions like "Is Perl 6 code ever directly exposed to foreign PMCs with foreign semantics" 05:07
but... nobody understands them, because I don't understand enough to correctly use the language 05:08
bkeeler I think there are provisions for mapping basic types like strings somehow too
It's not an area I've looked into in great detail though 05:09
05:15 xomas left 05:18 koj joined 05:19 koj left 05:20 jaldhar left 05:21 jaldhar joined
lue anyone here? 05:27
bkeeler sort of
TimToady looks around for his cricket 05:28
lue Someone should paste this link into this channel's topic: xkcd.com/519/
bkeeler Heh, it's true 05:29
05:30 jaldhar left, jaldhar joined
bkeeler I've a coworker who likes to say the only thing he learn in college that directly applies to his job is the art of subsisting from vending machines 05:31
sorear How is Perl6 supposed to handle foreign importing from languages with different module syntax?
use java.io.zip.DeflateOutputStream:from<java>; # yay for unlimited lookahead
bkeeler Various of the PDDs go into it a bit, but it's all a bit handwavy
That would likely be :: instead of . 05:32
sorear At the Parrot level, it makes complete sense to me
lue It's magic, Harry! (I have no other way of putting it.) 05:33
sorear However, the Parrot level doesn't have minor complications like... parsability
TimToady the foreign stuff goes inside quotes
bkeeler The HLL::Compiler stuff specifies a parse_name method that translates that sort of thing
TimToady the nickname goes outside in P6
sorear Nickname?
TimToady use MyNick:from<ThatBigLongName>
bkeeler Ah, even better
sorear Oh, I thought the syntax was use TheModule:from<HLL>
So, uh, how do nicknames work
Are they global?
Does every Perl6 module have to agree on the Perl<->Java name mapping? 05:34
Or does the 'use' just install a lexical/package symbol which points (indirectly) to the Module PMC?
TimToady see S11:507
bkeeler Would be an alias to the namespace you get back from the compiler's various methods I think
TimToady nicknames are lexical 05:35
bkeeler I wonder how it would look the other way? 05:36
import perl6.Soap.Lite.*;
The globbing that java does on the classname would be...interesting 05:37
sorear awesome, I would never have found that without you 05:39
this makes a bit more sense now
though I'm not sure how to handle the disconnect between (Perl5: A class is a namespace) and (Parrot: A class is a value) 05:40
bkeeler It's worth looking into the rakudo metamodel if you haven't already done so 05:41
sorear I have
(and I'm extremely familiar with the Moose metamodel)
bkeeler parrot also has opcodes for creating objects and classes 05:43
sorear When you say "use Compressor:from<java java.util.zip.Deflater>;"
is Compressor in the LexPad directly bound to a Parrot-Java PMC
or to some Raduko PMC that wraps an arbitrary PMC with Raduko semantics?
bkeeler Probably to some PMC provided by the Java compiler object 05:44
sorear this seems very unfortunate 05:45
bkeeler Well, don't take my word for it; like I say, I'm not particularly well versed in this stuff :)
Pmichaud and Tene seem like the best people to ask 05:46
Or perhaps the folks in #parrot
sorear What network is #parrot on? 05:47
bkeeler Either irc.parrot.org or irc.perl.org depending on which of these two documents I'm looking at is most current 05:49
sorear there are 91 members in MAGnet parrot 05:50
4 in freenode parrot
05:51 quietfanatic left
sorear and irc.parrot.org is a redirect to MAGnet anyway 05:51
so ... both documents are equally valid
bkeeler Aha
lue is there another perl6 channel out there? And if so, is this the "main one"?
sorear (irc.perl.org is a redirect to MAGnet)
This is, or was, the main perl6 channel
bkeeler This is the only one as afaik
sorear it was the main one back in 2006 when I was a pillar of #haskell
also, *lightbulb* 05:52
06:02 justatheory left 06:04 quietfanatic joined
lue
.oO(the lightbulb is getting very warm)
06:04
06:17 ShaneC left 06:22 payload left
bkeeler OK, so the previous discussion led me to look into Java's reflection and classloader stuff 06:35
My head hurts now
getClasses() 06:36
Returns an array containing Class objects representing all the public classes and interfaces that are members of the class represented by this Class object.
I've read that sentence like 6 times and my head is spinning 06:37
sorear Java supports nested classes 06:38
So does Perl 6
bkeeler ah, yes, that's likely what it's talking about 06:39
sorear a class isn't an object, it's a concept; Class objects are mere proxies
like how Moose::Meta::Class instances don't really have anything to do with Perl5 classes 06:40
sorear is currently braindumping a blizkost/SEMANTICS.DRAFT 06:41
bkeeler I confess I haven't really done any Moose
sorear++!
sorear bangily?
bkeeler If that's what floats your boat
lue [classobj1, classobj2, classobj3]; each classobj* is a representation of a public classes and its methods. 06:43
got it! :)
sorear bkeeler: when I see stuff like "sorear++!" I assume somebody misunderstood me, because I can't possibly be thatawesome 06:46
bkeeler Anyone making any kind of effort is automatically awesome 06:47
sorear If I want to define stuff that Parrot (and Perl6) can see but Perl5 doesn't, where should I put it? _perl5; ? 07:01
07:01 Trashlord left
lue g'night! 07:04
mberends sorear: "can see" in what sense? Parrot namespaces?
sorear mberends: can see, as in Perl5 code shouldn't be able to say "use Blizkost::SV", it would make no sense and not even work 07:05
maybe I should use a separate HLL tag
then Perl6 code can say "use SV :from<blizkost>" 07:06
or perhaps use Blizkost::SV :from<parrot> 07:07
mberends the Perl5 "use" command would never be executed by Parrot 07:08
sorear true 07:09
I think I like the last version best anyway though
the Parrot-side Blizkost code is a Parrot library, not a perl one
mberends right 07:10
the virtual-to-native bridging is the hassle, two independent execution environments 07:11
sorear According to PDD 11, it is possible for C code to call Parrot code and vice versa. According to PDD 23, Parrot has first class continuations. One or both of these must be unimplemented. 07:32
mberends More likely undocumented, except maybe the in the source of the implementation. Tene++ had some callbacks working a few months ago in an Enlightenment GUI demo. 07:43
s/the in/in the/
sorear mberends: I say unimplemented because for those two features to simultaneously exist is not possible 07:45
if you're going to write code which cannot exist, documenting it is the least of your concerns 07:46
more likely, the actual behavior deviates from the documented behavior in such a way as to not step on reality's toes
(e.g. Parrot continuations are actually escapecontinuations) 07:47
07:49 wave2 joined
mberends sorear: I beg to disagree. Continuations are a nice high level luxury for managing execution at a high level. The Parrot VM can do that. Calling C code is low level, and works with the stack etc. That is how Parrot asks your poor CPU and OS to do I/O, for example. They are not mutually exclusive, just different levels. 07:50
sorear True continuations are strictly more powerful than activation stacks 07:51
In particular, in a system with true continuations (e.g. Scheme), a routine can return multiple times
this will cause severe memory corruption in all C++ implementations and many C ones 07:52
if a single call to Parrot_call_sub returns more than once
mberends Parrot is written in C, so whatever "continuations" it implements or emulates boil down to C. It may be that Parrot's continuations do not conform to your criteria for "True continuations". 07:53
sorear HLLs with continuations can be implemented in C if they do not store activation records on the stack 07:54
mberends that's how Parrot works afaiu 07:55
sorear you can recognize an implementation like this by the fact that it does not support HLL->C->HLL sequences
mberends yes, that may the case here
sorear investigates 07:57
08:03 rv2733 left 08:06 wave2 left 08:19 Su-Shee joined
Su-Shee good morning 08:19
08:23 Trashlord joined
mberends hi Su-Shee 08:25
sorear hello
09:00 gfx joined, iblechbot joined 09:01 pjcj left 09:02 payload joined 09:04 am0c joined 09:07 gfx left 09:14 payload left 09:15 payload joined
sorear except for the exception stuff which is waiting on chromatic in #parrot for details, I've finished working out most of the broad structure of how I want Parrot/Perl5 interoperation to look 09:30
just need to get (TimToady and?) jnthn to look over pastie.org/867650 09:31
mberends cool
09:38 perl7 joined
mberends perl7: I am not amused by your choice of nickname. do you think it's clever? 09:51
09:52 mantovani left
perl7 mberends: There are more intelligent ways of calling me stupid 09:54
mberends perhaps I should have asked, do you think it's funny?
sorear [so we have a Nickname Police here?] 09:55
09:56 hanekomu_ joined
perl7 mberends: I'm waiting for perl6, I'm ready 09:56
mberends ok, and I don't mean to harass anyone, it was just my personal reaction. We are so looking forward to progress on Perl 6. 09:58
10:00 payload left 10:01 payload joined
perl7 me too 10:05
When do you think perl6 "1.0" will be released
mberends we honestly don't know. It's so hard. 10:06
chromatic Why does the version number "1.0" matter?
perl7 I've listened something about this Spring
mberends the Rakudo * release will be late April, maybe early May 10:07
10:07 payload left
mberends Rakudo * is planned to contain enough features that non language developers can do a lot with it. 10:08
perl7 "1.0" it's a common version name to say: this is good and ready, but perhaps more in the marketing place, I suposse
10:09 payload joined
mberends yes, the word "usable" is the one we like for Rakudo * 10:10
10:10 iblechbot left
perl7 and what about a CPAN * ? 10:11
mberends but "6.0.0" is still quite a long way off.
there are only some CPAN-ish building blocks, not yet "usable" grade 10:12
sorear questions of the form "when will XXX be ready" should always be accompanied with payment
volunteer manpower is not provided on schedules
we can probably give you an ETA in man-months, but not months
mberends that's exactly the problem 10:13
10:17 masak joined
masak perl7: way to choose an inflammatory nickname, buddy. :) 10:17
phenny masak: 12 Mar 23:09Z <snarkyboojum> tell masak - no worries - get better, and I'll look forward to it
masak perl7: is there anything we can help you with wrt the version of Perl *we're* working on? 10:18
perl7 masak: have a match?
masak perl7: no. just a Match.
masak looks up audreyt's hugging blog post 10:19
perl7: hey. I sense that you come here to be hugged properly. 10:20
perl7 masak: did I say something offensive?
masak hugs perl7. there. please, be happy.
perl7: oh! I see your nickname isn't new either. you've been here intermittently since 2008. 10:22
perl7 has a vocation to spy me? 10:23
masak perl7: no. sorry; just checked the logs.
they're public.
perl7 masak: curiosity killed the cat 10:24
masak perl7: yeah, I guess. :)
mberends Perl 7 is documented as the Perl 6 spec overflow. If an idea is potentially nice, but considered beyond the plans for Perl 6, it can be marked as possible Perl 7. "Beyond us", that's what prickled me ;)
masak Perl 7 is also mentioned by Apocalypse 1. 10:25
mberends indeed
masak "So Perl 7 will be the last major revision. In fact, Perl 7 will be so perfect, it will need no revision at all. Perl 6 is merely the prototype for Perl 7. :-)" 10:26
mberends with tongue firmly in cheek
masak right.
perl7: thence the connotations for your nick. you might as well have called yourself 'perfecter_than_thou' :P
perl7 perl will live forever, no matter what number goes behind (5, 6, 7, ...) 10:27
masak needs to go offline due to low battery 10:28
chromatic Let's hope not all versions of Perl will live that long.
masak please keep up the interesting discussion. see y'all later today. :)
xinming Even these days, perl 5 is still the good programming language. Though it looks abit rough.
10:28 masak left
perl7 Perl will outlive us all 10:30
10:36 payload left
mberends hopefully deconfused so that TimToady++ can understand it ;-) www.perlfoundation.org/perl6/index.cgi?viv 10:49
10:49 MAK_ joined
MAK_ Hi 10:49
I need some help installing rakudo on win32
I've build parrot using mingw 10:50
but when I install rakudo I get the following error message
D:\Rakudo\rakudo-2010.02>perl Configure.pl --parrot-config=D:\Rakudo\Parrot\parrot-2.1.1\parrot_config Reading configuration information from D:\Rakudo\Parrot\parrot-2.1.1\parrot_config ... Verifying Parrot installation... ===SORRY!=== I'm missing some needed files from the Parrot installation: C:/Parrot/lib/parrot/2.1.1/library/PGE/Perl6Grammar.pbc C:/Parrot/lib/parrot/2.1.1/library/PCT/HLLCompiler.pbc C:/Parrot/lib/par
sorear MAK_: your line is too long for IRC. Use paste.lisp.org/new/perl6 instead. 10:51
MAK_ ok
lisppaste3 MAK pasted "untitled" at paste.lisp.org/display/96323 10:52
MAK_ hmmm
actually its searching for file in C drive but I've installed in D
mberends there may be an older Parrot in your search path 10:53
try echo %PATH% 10:54
MAK_ ok
mberends this is the first time im installing rakudo 10:55
mberends MAK_: then C: versus D: is the likely cause
MAK_: you may even have uncovered a silly oversight in the build process :) 10:58
10:59 Patterner left
MAK_ yes 10:59
I just found out i didnt do a migw32 install-dev
mberends ok. the -dev part is *important* 11:00
snarkyboojum mberends++ - makes more sense now 11:03
re viv description on the wiki
mberends :) yes
MAK_ I just build both rakudo and parrot, turned out to be a piece of cake 11:04
:)
> say 'hello' hello > say 'hello,world' hello,world > say 'hello,world'; hello,world 11:05
from the REPL
it works with and without semicolon, is semicolon optional in perl6
sorear rakudo: say 'hello, world'
p6eval rakudo f04eb8: OUTPUT«hello, world␤»
sorear semicolon is optional if there is no following statment
rakudo: say 'hello, world' say 'hello' 11:06
p6eval rakudo f04eb8: OUTPUT«Confused at line 11, near "say 'hello"␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
pugssvn r30059 | vamped++ | changed "scalar context" into "item context" as per S02 11:08
snarkyboojum so the std: bot thingy uses viv?
std: say "hi" 11:09
p6eval std 30058: OUTPUT«ok 00:01 107m␤»
snarkyboojum it looks like the output of tryfile or something similar 11:10
std: say "hi"; a(); 11:12
p6eval std 30058: OUTPUT«Undeclared routine:␤ 'a' used at line 1␤ok 00:01 105m␤»
snarkyboojum almost definitely the output of tryfile
which doesn't use viv right? 11:13
11:13 M_o_C joined
mberends yes, I'll correct that in the wiki. They both use STD. 11:13
snarkyboojum yeah cool
11:14 MAK_ left 11:16 MAK_ joined
MAK_ My hello world program isnt working 11:16
Null PMC access in find_method('get_parrotclass') current instr.: 'perl6;ClassHOW;onload' pc -1 ((unknown file):-1) called from Sub 'perl6;Perl6;Compiler;main' pc 200604 (src/gen/perl6-actions.pir:0) ... call repeated 2 times
but the repl works 11:17
11:18 am0c left
MAK_ is any body there? 11:18
snarkyboojum MAK_: how are you running it? 11:19
11:20 quester joined
MAK_ from inside eshell in emacs 11:20
snarkyboojum did you do a make install? 11:21
MAK_ no
actually If i run it through dos prompt is runs ok
Looks like the problem is only through eshell in emacs 11:22
snarkyboojum I'd try a make install
snarkyboojum doesn't really know what the problem is tho :)
MAK_ Actually im working on windows vista
snarkyboojum not familiar with the build process on windows 11:23
sorear ok, I finished the exceptions & continuations section chromatic++ , anyone who thinks they know how Perl5/Perl6 interop should work should look over pastie.org/867726
11:23 chromatic left
MAK_ use warnings; isnt yet implemented I guess 11:26
sorear use warnings is *gone*
this is perl 6
clean break from the past
MAK_ ok, what about use strict
sorear warnings are mandatory - say goodbye to boilerplate
strictness too
MAK_ oops
ok
sorear here's how you start a Perl 6 file: module CoolMod; # note lack of boilerplate uses 11:27
snarkyboojum MAK_: how did you build rakudo on windows?
mingw32-make or something? 11:28
MAK_ First I installed mingw, then got the parrot release tarball from there site ,,, did a perl configure.pl and mingw-make and mingw-make dev-install
then the installed rakudo as perl configure --config-file=path-to-config-file 11:29
That was it
A syntax like break if (--$a == 0); is valid in Perl6 right 11:31
?
mberends yes, annd without parentheses 11:32
MAK_ but it gives the following error : Could not find non-existent sub &break
mberends rakudo: say "it is" if 4 > 2
p6eval rakudo f04eb8: OUTPUT«it is␤»
snarkyboojum no make for the rakudo build?
MAK_ Yes I did a make for rakudo build 11:33
snarkyboojum but not a make install
MAK_ no i didnt do a make install 11:34
snarkyboojum that'll fix your problem I reckon
MAK_ ok I will try now
snarkyboojum without a make install rakudo can't be run out of the root rakudo directory, which is probably what eshell is trying to do
MAK_ Yes as suggested It worked fine now 11:35
snarkyboojum wunderbar 11:36
MAK_ This was embarrasing how could i be so dumb
11:37 payload joined
lisppaste3 MAK pasted "break statement problem" at paste.lisp.org/display/96324 11:38
jnthn hello, #perl6 folk :-)
MAK_ This code gives an error
why is the break statement giving such an error
jnthn wonders if it's still called "break" in Perl 6. 11:40
MAK_ jnthn I didn't get you, Im new to perl 6... please let me know if there are some fundamental docs i need to read so that I dont ask questions whose answers are obvious 11:41
jnthn rakudo: succeed
p6eval rakudo f04eb8: OUTPUT«Warning␤»
jnthn MAK_: Heh, I was idly wondering rather than answering. :-) Just checking The Spec at the moment...
MAK_ okies :)
jnthn MAK_: From S04, I think it may be spelt "succeed" rather than "break" in Perl 6, but that doesn't appear to work for me either. 11:43
colomon shouldn't it just be "last" there?
MAK_ ok lemme try last
jnthn colomon: oh, maybe that one too
oh 11:44
MAK_ 'last' works
jnthn MAK_: Use "last" :-)
colomon++
MAK_ Yes 'Last' worked
great :)
colomon I thought break was for when statements, and is now replaced by succeed.
jnthn colomon: Yes, you're right.
colomon and good morning, too. :)
jnthn colomon: My brain hasn't really started working yet today. 11:45
colomon MAK_: also, "loop" is probably more idiomatic than "while(1)". (Should have the exact same results.)
MAK_ ok. will try loop 11:46
jnthn loop { ... } # infinite loop :-) 11:49
MAK_ perl 6 has limit on maximum recusion depth 11:50
*recursion*
colomon jnthn: do you have any advice for dealing with the insane math types on p6l? 11:52
jnthn colomon: Take p6l with a grain of salt. 11:53
colomon: There's often a disconnect between some of the posts and reality.
colomon jnthn: I very much understand that.
snarkyboojum phenny: tell lichtkind - it's all good mberends++ has updated the entry
phenny snarkyboojum: I'll pass that on when lichtkind is around.
jnthn colomon: For example, I've seen posts there claim stuff isn't spec'd when it's actually spec'd and implemented.
colomon Right now, these "why don't we have twenty more numeric types?" posts all seem to assume that Int is not Real, when the Real spec (and basic common sense) says it is. 11:54
jnthn Really? ;-) 11:56
MAK_ Does perl6 have a maximum depth on recursion?
jnthn MAK_: No, the VM has an artificial limiter in place at the moment though.
MAK_: Since call frames are allocated on the heap, you can pretty much go as deep as you have memory to sustain it.
MAK_ Will this be a thing even in the future? 11:57
jnthn MAK_: But at the moment, when we hit the limit it's usually some bug, so for now it's a useful debugging aid.
No, I expect we'll lift it.
MAK_ no issues, everything's ok so as long as the future is bright :) 11:58
jnthn :-)
colomon: Yes, it makes sense to me that Int does Real too.
colomon: I also agree we don't really want - or need - 20 more numeric types in Perl 6 core.
colomon and the idea that Perl 6 Simply Must have both cartesian and polar implementations of Complex is just wacky...
jnthn colomon: That's the point of the roles, iiuc - that people *can* implement extra numeric types. 11:59
In modules.
colomon jnthn: my goal is to make it easy to add new numeric types, not spend the rest of my life implementing everything that can be thought of. :)
jnthn colomon: Right
colomon: everything that can be thought of doesn't belong in the core. :-)
Even if we do have the KitchenSink. 12:00
colomon: Do we have a "Complex" role?
colomon jnthn: no
jnthn OK
Do you think we should have one?
(so that people can implement other types of complex...not that I understand the differences so great...) 12:01
colomon well, it might be useful to allow future expansion (see polar).
but other than that, no.
Complex is spec'ed as taking two Reals.
wait a minute... 12:02
well, there is a lower case complex too, so I suppose a role might make sense. 12:03
jnthn Yes, true.
colomon I'd consider it pretty low priority at the moment, for sure.
jnthn *nod*
12:04 pmurias joined
colomon hmmm... though actually, *do* the native types support roles? They're referred to as "non-object" types.... 12:07
they autobox if needed to look like the object types...
12:07 Lorn left 12:08 iblechbot joined
jnthn colomon: Well yes, that is the question... 12:10
...do we ever have them in an unboxed form where we can check stuch things? :-)
I'm not sure off hand. Nobody did native types yet, afaik, so there's likely some details to be really fleshed out. 12:11
colomon I almost think I'd just as soon forget the darned things. :)
jnthn You pretty much can forget them until after R*. :-) 12:12
colomon forget what? ;) 12:14
lisppaste3 MAK pasted "Array example" at paste.lisp.org/display/96326 12:16
MAK_ Didnt work the way i expected
12:17 arthur-_ left
jnthn MAK_: I think you want a hash rather than an array there. 12:17
12:17 arthur-_ joined
MAK_ references are numeric values right? 12:18
sorear jnthn: finally, you're awake 12:19
MAK_ so I'm basically assigning numeric values at both ends...
jnthn sorear: Yes, talk extra sleep today...trying to get rid of this rotten cold.
er
s/talk/took/
sorear yes. and it's 4am here :(
MAK_ I mean a[$first_reference] = $second_refrerence
so it should work 12:20
sorear anyways, I had a lightbulb moment yesterday and worked out most of a set of coherent semantics for Blizkost
please look at pastie.org/867726 and tell me if it's sane
jnthn sorear: Awesome...I saw the commit, but need to be a bit more concious before I read it.
sorear no commit yet
should I be putting this in the repo??
jnthn MAK_: I don't follow what you mean, but I don't expect it to work either. :-)
Feel free to create a docs directory in the repo and pop it there. 12:21
sorear I also need to flag down Tene and extract the meaning of HllInteroperability
because I have no idea how returning j. random pmc to Perl6 is expected to work
MAK_ jnthn , are reference numeric values? I mean valid array indices? 12:22
sorear done
jnthn MAK_: We don't really have references in Perl 6 in the sense that Perl 5 had them. I don't really see where you expect to have a reference anyway though, to be honest. I think I'm missing what you're getting at. 12:23
I agree biryani is awesome though.
MAK_ perlcabal.org/syn/Differences.html#...ference%29 says everything is a reference 12:24
sorear don't index arrays by refenerces 12:25
MAK_ why not
sorear even if they were numeric, they'd be around 10 digits
lisppaste3 jnthn pasted "for MAK_" at paste.lisp.org/display/96327
MAK_ is there an limit on array index number?
sorear array memory usage is 4 bytes * max index
actually sizeof(PMC*) 12:26
MAK_ jnthn i got your point that we must actually use hash and not arrays
12:26 perl7 left
jnthn When you try to put a string like foo as an array index, it attempts to coerce the string to a Num. 12:26
well, and Int i guess
MAK_ Actually I just wanted to check that 'everything is a reference' part
jnthn *an 12:27
sorear: I need to pop out for a bit now, but I'll read the doc a bit later on today :-)
sorear: And get back to you. 12:28
sorear oh goody
I hope I'm awake then
jnthn sorear: A quick glance over and it looks good/interesting.
I think our days overlap weirdly. :-) Where abouts are you?
sorear US west coast 12:29
MAK_ My point is $foo(of any type) is a valid array index due to 'every thing is a reference' as mentioned in perlcabal.org/syn/Differences.html#...ference%29
jnthn sorear: Ah, OK. Quite a way of central european time.
sorear I have a weird sleep schedule too - I actually sleep on Melbourne time 12:30
jnthn gotta go - be back in a little bit 12:32
MAK_ ok
snarkyboojum rakudo: my @array[0] = "a"; @array[4] = "b"; say @array.perl 12:33
p6eval rakudo f04eb8: OUTPUT«["a", Proxy.new(), Proxy.new(), Proxy.new(), "b"]␤»
snarkyboojum looks up Proxy.new()
12:34 meppl joined
MAK_ How do I view the value of a reference? 12:42
in rakudo?
snarkyboojum rakudo: my @a = 1,2,3; my $b = @a; say $b 12:47
p6eval rakudo f04eb8: OUTPUT«1 2 3␤»
snarkyboojum MAK_: I'm reading through perlcabal.org/syn/Differences.html atm .. looks interesting
MAK_ ok
m6locks is that like an automatic reference 12:48
saying a scalar equals an array
snarkyboojum rakudo: my @a = 1,2,3; my $b = @a; say $b ~~ Array
p6eval rakudo f04eb8: OUTPUT«1␤»
m6locks seems like it :)
snarkyboojum I'm looking at "References are gone (or: everything is a reference) in particular 12:49
MAK_ looks like $a, @a, %a all hold the address and not the value itself, in that case how do I see that value?
m6locks that's like in java, only s/references/pointers/
snarkyboojum MAK_: got an example? 12:50
MAK_ Actually I don't know how to view the value. I started with perl 6 around an hour back :) 12:52
snarkyboojum you could just say the value as per above?
rakudo: my @a = 1,2,3; my $b = @a; say $b.perl
p6eval rakudo f04eb8: OUTPUT«[1, 2, 3]␤»
snarkyboojum kinda like a built in data dumper :)
MAK_ No, I think when we say $a = @b we assign the address of @b to $a ... whereas in perl 5 we needed to do $a = \@b 12:53
12:54 payload left
snarkyboojum MAK_: so what are you trying to get? 12:54
m6locks i always thought those references were confusing, so it's an advancement that they're gone
12:54 quester left
MAK_ My original point was if references are valid array indices... a near hash simulatation can be achieved using arrays itself 12:55
*provided they are valid array indices* , which will be the case if they are numbers
snarkyboojum MAK_: I'm not sure they work that way 12:57
but then I'm a newbie too :)
MAK_ Actually 'if everything is a reference' is true, then a lot of power is automatically available to us :) 12:58
snarkyboojum rakudo: my @a = 1,2,3; my @array[@a] = "test"; @array.perl.say # this doesn't break 12:59
p6eval rakudo f04eb8: OUTPUT«["test"]␤»
12:59 payload joined
snarkyboojum it'll just whack it in as the first element in the array 12:59
MAK_ but that didnt quite work the way here paste.lisp.org/display/96326
snarkyboojum yeah it did 13:01
rakudo: my @array; my $a = "name"; my $b = "favourite food"; @array[$a] = "MAK"; @array[$b] = "biryani"; say @array.perl
p6eval rakudo f04eb8: OUTPUT«["biryani"]␤»
snarkyboojum anytime you access the array with $a or $b it's just giving you the first element (i.e. the only element) 13:02
MAK_ but on my prompt say @array[$a]; say @array[$b]; display the same value
snarkyboojum yeah they do
MAK_ yeah. why is that?
snarkyboojum not sure what it's doing, but $a, and $b are indexing the first and only element
:)
MAK_ To me it looks like $a == $b, lemme check that 13:03
snarkyboojum ah I think I know
13:03 hanekomu_ left
snarkyboojum my @array; my $a = "name"; my $b = "favourite food"; @array[$a] = "MAK"; @array[$b] = "biryani"; say +$a; say +$b; 13:03
rakudo: my @array; my $a = "name"; my $b = "favourite food"; @array[$a] = "MAK"; @array[$b] = "biryani"; say +$a; say +$b; 13:04
p6eval rakudo f04eb8: OUTPUT«0␤0␤»
snarkyboojum so $a and $b in Num context are 0 :)
so it's doing that when constructing and indexing into the array
MAK_ ohhh, now i got it :)
snarkyboojum +$a is $a in Num context btw
~$a is $a in String context 13:05
and there is ?$a I think for Bool
MAK_ how do i view the reference value of $a?
snarkyboojum not sure what you mean by reference value 13:06
sorear $a.WHICH
snarkyboojum I think that's just the same as $a.WHERE in rakudo which is the memory address or some such 13:07
or not :)
MAK_ yes thats what i meant
Ok now if a know a $a.WHERE can I get back the $a 13:08
snarkyboojum rakudo: my @a = 1,2,3; say @a.WHICH; say @a.WHERE; 13:09
p6eval rakudo f04eb8: OUTPUT«48004167394400␤48004167394400␤»
snarkyboojum no idea how you could do that, or if you'd want to :)
MAK_ like in C way , if i know &a i could always get *a 13:10
:)
snarkyboojum heh 13:11
MAK_ did I say something wrong
What I mean is will I be able to reach the value of the variable through its address 13:12
snarkyboojum use C: ) 13:13
sorry - don't know enough to help - but doesn't sounds like something you'd want to be doing
s/sounds/sounds/
eek
MAK_ in Perl 5 one can always do a $array_ref->[$index]
I was speaking of something similiar 13:14
snarkyboojum rakudo: my @a = 1,2,3; my $b = @a; say $b[2]; 13:15
p6eval rakudo f04eb8: OUTPUT«3␤»
13:16 wknight8111 joined
snarkyboojum wishes masak or someone was around to answer things more plainly and clearly :) 13:16
MAK_: I'm still learning this stuff too - it's good fun tho eh? :) 13:17
lisppaste3 MAK pasted "reference example" at paste.lisp.org/display/96329 13:20
13:20 MAK_ left
snarkyboojum yep in Mu.pir - looks like WHICH just calls WHERE which does a 'get_addr' on self 13:21
rakudo: my @array; @array.WHERE.WHAT.say 13:22
p6eval rakudo f04eb8: OUTPUT«Int()␤» 13:23
13:23 MAK_ joined
snarkyboojum that last paste MAK_ 13:23
rakudo: my @array; @array.WHERE.WHAT.say
p6eval rakudo f04eb8: OUTPUT«Int()␤»
snarkyboojum WHERE is returning an Int
or the memory address
so that can't be used as an array
MAK_ so how can the rakudo be told to treat it as an address 13:24
*how can*
snarkyboojum you mean a reference in the perl5 sense? 13:25
MAK_ yes, What I meant was if a assign $a = @b.WHERE ... how do I know go to @b[indexes] from $a 13:27
s/know/now/
snarkyboojum $a[index]
oops
not if $a = @b.WHERE
if $a = @b
MAK_ yes...
snarkyboojum @b.WHERE is going to give you a number, an Int, a memory address - that's all 13:28
MAK_ ok ... so is there something like $a.treat_as_reference[index]
snarkyboojum are you just after something like this? my @b = 1,2,3; my $a = @b; say @b[1]; say @a[1]; 13:29
rakudo: my @b = 1,2,3; my $a = @b; say @b[1]; say @a[1];
p6eval rakudo f04eb8: OUTPUT«Symbol '@a' not predeclared in <anonymous>␤current instr.: 'perl6;PCT;HLLCompiler;panic' pc 137 (compilers/pct/src/PCT/HLLCompiler.pir:101)␤»
snarkyboojum rakudo: my @b = 1,2,3; my $a = @b; say @b[1]; say $a[1];
p6eval rakudo f04eb8: OUTPUT«2␤2␤»
MAK_ no that was not what I meant
snarkyboojum MAK_: hehe sorry - I clearly don't get it :) 13:30
MAK_ $a = @b.WHERE; $a.treat_as_reference[0]
snarkyboojum MAK_: I don't think so
what are you trying to do with that approach though? 13:31
13:31 M_o_C left
MAK_ hmmm... well diffficult to give a use case to it right now, but I think if that can be done... it will be a helpfull feature 13:31
snarkyboojum sounds too low level to me 13:32
you're wanting to turn a memory address into a perl 6 datastructure
MAK_ yeah something similiar.... I always think of Perl as C of scripting languages
:) 13:33
I think summarizing it as a whole... we need to find a way of treating Num in reference context 13:34
snarkyboojum a reference to what though? 13:35
13:35 mikehh left, mikehh joined
mberends from the Perl 6 language design perspective, whatever it is that you want to do with pointers, should be doable with non-pointery things, because pointers so readily become dangerous and do wrong things. So there's a bit of the nanny in the language, just as in Java etc. 13:35
snarkyboojum security issues/portability/whatever else 13:36
mberends sure
snarkyboojum exactly :)
horrible thing to want in Perl(s) imo :)
MAK_ no why? if an adress doesnt exist it must autovivify 13:37
but yeah I do agree, its not safe for everyone 13:38
snarkyboojum don't see how it's necessary either
MAK_ well thats a different question altogether
mberends rakudo: my @a=<aa bb cc>; my $a=@a; say @a[0]; say $a[1] # $a is kinda "reference" 13:39
p6eval rakudo f04eb8: OUTPUT«aa␤bb␤»
snarkyboojum yeah, was showing that earlier
MAK_ mberends so there is no way of treating Num in context of a reference? 13:40
mberends MAK_: probably not. But I tend to stay away from the extremes of what is possible, others like masak++ like to explore the outer envelope more. 13:42
13:47 Chillance joined 13:48 payload left, mantovani joined
mberends MAK_: have you read about := for binding? Look in S02 from perlcabal.org/syn 13:49
13:49 mantovani left, mantovani joined
MAK_ mberends reading it now 13:50
13:51 wknight8111 left
MAK_ Rakudo says := is not yet implemented ... :) 13:52
sorear you can do it!~
mberends oops, it's in NQP but not Rakudo
MAK_ sorear Im just a small time application programmer, no very qualified with stuff like writing a compiler 13:54
*not*
Actually If I could, I would ... :( I wonder if there is a way to learn that 13:55
snarkyboojum pester people in here :)
mberends MAK_: don't worry, many people here (myself included) started here the same way
sorear there's no such thing as a program that cannot be hacked by mortals 13:56
MAK_ mberends , sorear thanks that gives me hope :)
And makes me feel good too, not all communities are so welcoming to new people 13:57
mberends as jnthn++ wrote a few months ago, programs are just another kind of data
jnthn back 13:59
sorear hurray 14:00
snarkyboojum I sometimes think cool tech like Perl 6 is waay funkier than the latest iPad or whatever other gadget 14:04
v. cool to watch it being built :) 14:05
14:05 nacho joined
MAK_ Actually funkier stuff is built using languages like Perl 6 14:06
snarkyboojum that too 14:07
MAK_ Imagine all the bioinformatics stuff without Perl. Its pretty scary 14:09
snarkyboojum there's always biopython :P
MAK_ Yes they will ask you to program with all your hands tied down 14:10
14:20 nacho left 14:24 payload joined
snarkyboojum MAK_: check out Captures as well 14:24
14:25 synth left
snarkyboojum rakudo: my $a = \(1,2,3); say $a.WHAT 14:25
p6eval rakudo f04eb8: OUTPUT«Capture()␤»
MAK_ ok 14:26
snarkyboojum rakudo: my @items = 1,2,3; my $a = \@items; say $a.WHAT
p6eval rakudo f04eb8: OUTPUT«Capture()␤»
snarkyboojum more info at perlcabal.org/syn/S08.html
std: my ¢a = (1, (2, (3, 4))); 14:27
p6eval std 30059: OUTPUT«===SORRY!===␤Malformed my at /tmp/XvUlDJ754k line 1:␤------> my ⏏¢a = (1, (2, (3, 4)));␤ expecting scoped declarator␤FAILED 00:01 107m␤»
snarkyboojum std: my @%a = (1, (2, (3, 4)));
p6eval std 30059: OUTPUT«===SORRY!===␤Preceding context expects a term, but found infix = instead at /tmp/R4xEn8knbJ line 1:␤------> my @%a ⏏= (1, (2, (3, 4)));␤ expecting any of:␤ argument list␤ prefix or term␤FAILED 00:01 106m␤» 14:28
MAK_ another thing that I may observed why do we have the '^ ' after '.' .... .^does(Capture). 14:29
s/may/have
14:34 ruoso joined, rv2733 joined
snarkyboojum rakudo: say List.^does(Iterable) 14:35
p6eval rakudo f04eb8: OUTPUT«0␤»
snarkyboojum rakudo: say List.^methods.perl 14:36
p6eval rakudo f04eb8: OUTPUT«maximum recursion depth exceeded␤current instr.: 'perl6;Seq;!fill' pc 13697 (src/builtins/Block.pir:19)␤»
snarkyboojum rakudo: say List.^parents.perl
p6eval rakudo f04eb8: OUTPUT«(Iterator, Iterable, Any, Mu)␤»
snarkyboojum introspection baby!
rakudo: say List.HOW 14:38
p6eval rakudo f04eb8: ( no output )
14:38 MAK_ left
snarkyboojum rakudo: say List.HOW.parents 14:38
p6eval rakudo f04eb8: OUTPUT«too few positional arguments: 1 passed, 2 (or more) expected␤current instr.: 'perl6;ClassHOW;parents' pc 4221 (src/metamodel/ClassHOW.pir:335)␤»
snarkyboojum rakudo: say List.HOW.parents(List) 14:39
p6eval rakudo f04eb8: OUTPUT«Iterator()Iterable()Any()Mu()␤»
jnthn rakudo: say List.^parents
p6eval rakudo f04eb8: OUTPUT«Iterator()Iterable()Any()Mu()␤»
snarkyboojum yeah
jnthn oh, you already did that above :-)
snarkyboojum just working out what .^ does
I read a great article you wrote about it somewhere 14:40
:)
so I take it SomeObject.^does(Role) checks to see if SomeObject does role Role? 14:41
trying to answer MAK_'s question above
jnthn Correct 14:42
If SomeObject inherits from Any though, then it has it's own .does method that forwards to .^does
snarkyboojum MAK_: there you go .. took a while for me to get there :P
jnthn But generally you should just write SomeObject ~~ Role 14:43
And let smartmatch take care of the details. :-)
snarkyboojum ah - what jnthn++ said then :)
rakudo: say Num.^methods.perl 14:45
p6eval rakudo f04eb8: ( no output )
snarkyboojum alpha: say Num.^methods.perl
p6eval alpha 30e0ed: OUTPUT«[{ ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ... }, { ...
..}, { …
snarkyboojum eek
alpha: say Num.^methods 14:46
p6eval alpha 30e0ed:
..OUTPUT«predatanhcosecexpacosecacoshNumsinhWHICHcotancosechatan2acotanComplexsecaseccotanhlogtansechlog10atancosacossqrtsintanhasincoshsuccsignperlasinhacosechScalarStracotanhunpolarACCEPTSasechRatflipdoesatanhcosecexpacoseccharscancosechlcfirstrootsmapciscombloglog10atanminacosmaxbyteseva…
jnthn rakudo: say Num.^methods>>.name.join(', ') 14:47
p6eval rakudo f04eb8: ( no output )
jnthn alpha: say Num.^methods>>.name.join(', ')
p6eval alpha 30e0ed: OUTPUT«unpolar, sech, ACCEPTS, atan, asech, acos, Rat, sqrt, tanh, asin, atanh, cosec, cosh, exp, acosh, succ, Num, sign, perl, WHICH, cotan, atan2, Scalar, Complex, sec, log, tan, log10, cos, sin, pred, acosec, sinh, asinh, cosech, acotan, acosech, Str, asec, cotanh, acotanh, floor,
..sech…
jnthn Think .methods may have problem still on master.
snarkyboojum ah - the >> trick 14:48
geez perl6 is good :)
14:49 nihiliad joined 14:56 arthur-_ left 14:58 gbacon left, arthur-_ joined 15:10 payload left
avar alpha: say Str.^methods>>.name.join(', ') 15:11
p6eval alpha 30e0ed: OUTPUT«WHICH, ACCEPTS, perl, sprintf, Scalar, Complex, Str, pred, encode, succ, floor, sech, asech, rand, truncate, round, sort, sqrt, rindex, asin, split, cosh, exp, match, acosh, grep, words, values, can, cotan, atan2, lcfirst, srand, map, polar, cis, kv, samecase, log, min,
..capitalize,…
15:13 M_o_C joined 15:15 masak joined
masak oh hai. 15:15
what's this Japanese twitterer saying? twitter.com/t_aldehyde/status/10419192099
something about 'write and write'. 15:16
rakudo: my @array[3] = 'test'; say @array.perl 15:19
p6eval rakudo f04eb8: OUTPUT«["test"]␤»
masak seems the dimensionality is parsed but ignored at present.
jnthn Yes 15:20
masak snarkyboojum: I'm here now. :)
jnthn Another of those "put in a patch to parse it with no implementatin" patches.
snarkyboojum masak: hi there - 2:20am here.. here in body only :)
masak snarkyboojum: I'm not sure I'll be able to answer things plainly and clearly, but I'll definitely try my best :) 15:21
snarkyboojum masak: I did quite a bit of waffling this evening
masak snarkyboojum: fwiw, I'm also trying to build up a world view of Perl 6 where 'reference' isn't a key term.
snarkyboojum: 'waffling'? is that good?
it sounds kinda tasty.
snarkyboojum :)
masak snarkyboojum: I've been meaning to dig into the SIC serialization. maybe this meeting will finally spur me to do so. 15:22
so far today, I've just been having excellent Mexican food and watching episodes of Dexter.
snarkyboojum masak: lovely - I'm about to collapse in a heap so I'll be keen to bug you about it tomorrow if you're around 15:24
masak snarkyboojum: anyway, in Perl 6, since most everything is a reference, there's no real benefit in talking about them all the time. we might as well dump the first three words in 'a reference to this or that object'.
snarkyboojum: I'll try to be around tomorrow, yes.
snarkyboojum masak: I agree - and I think I gave that impression
masak aye.
15:24 lestrrat is now known as lest_away
snarkyboojum even found a nice reference to "References are gone (or: everything is a reference)" in perlcabal.org/syn/Differences.html 15:25
masak yup. that's a good summary. 15:26
snarkyboojum so pointed MAK_ at that
masak mathw: do you think it'd be reasonable to expect to have Form.pm done or done-to-a-large-extent for the Rakudo Star release? 15:29
mathw: is the answer different if there's two of us working on it? :)
jnthn masak: Ooh, you did the Mexican nom thing too, huh? :-) 15:30
masak jnthn: big time.
it was wonderful.
for about an hour or so... :)
15:30 synth joined
masak blows his nose 15:30
15:31 jaldhar left
snarkyboojum well, night all - happy perl 6 hacking :) 15:31
masak snarkyboojum: 'night!
15:32 TiMBuS joined
sorear pokes jnthn 15:32
jnthn masak: Yes, the effect...wears off. 15:33
sorear: yes, yes...I have your proposal open in a browser tab. :-)
masak decides to give named enums another try 15:34
jnthn finishes making his cup of mint tea and takes a look through it
dalek kudo: a078e49 | masak++ | src/core/Any-str.pm:
[Any-str] format should be hexadecimal, not float
15:36
masak forgot to commit and push that during the hackathon. 15:37
15:40 gbacon joined
jnthn sorear: Wow, you've put quite some thought into this! :-) 15:43
sorear++
sorear: In a sense, it sounds like the registry approach and mappers is a much more extensible way of the marshall_arg handling that's in place today. 15:44
And just overall better designed.
jnthn likes the look of that :-) 15:45
mberends too
jnthn Did I miss it, or is there a way in there to explose a P5 sub in Parrot space spec'd in there?
*expose
15:45 synth left
mberends explose sounds truer 15:46
jnthn oh, sorry, wrapper
Looks like it does that.
15:46 synth joined
jnthn sorear: Anyway, I like The Plan. :-) 15:46
15:47 lue left
jnthn mberends: How goes FDBI? :-) 15:47
15:47 nsh left, lue joined 15:48 nsh joined
masak jnthn: some PAST::Op with :pasttype('call') have a :name that starts with a '!', and others have a name starting with '&'. what's the difference? 15:49
jnthn masak: When you write a sub foo() { } in Perl 6, its name in the lexpad/namespace is akshually &foo 15:51
That explains the &s
masak aye.
jnthn The ! is a "this thingy is private" market
*marker
It's used for guts methods that shouldn't be callable from Perl 6 space.
masak aha.
jnthn *guts subs
15:52 jferrero joined
masak shouldn't my CREATE_NAMED_ENUMERATION be a 'this thingy is private' sort of thing, in that case? 15:52
jnthn Well, there's the sma issue that you're writing in in Perl 6, no? :-)
masak ah. 15:53
right.
and Actions is in nqp.
jnthn I think the right thing to do in the long run will be to reserve some namespace though
15:53 jaldhar joined
jnthn Perl6::Compiler::Glue or some such 15:53
masak nod. 15:54
sorear jnthn: mmm. OK. 15:55
Now I just need to actually learn Parrot
jnthn sorear: Anyway, you can take my liking the plan as approval to start hacking Blizkost in that kinda direction, if you like. :-)
sorear I also need to understand how Perl 6 etc is expected to actually *use* this stuff 15:56
jnthn I guess that in a sense, Parrot PMCs are the kind of Parrot analog to Perl 5 SVs.
sorear the PDD-31 namespacing stuff makes sense to me
jnthn Well, our primary goal at the moment is being able to use CPAN modules from Perl 6.
sorear what doesn't really make sense is sharing PMCs across language boundaries
jnthn In theory, that's where the vtable comes in. 15:57
sorear I don't suppose I can just shove any ol' PMC into a Perl6 symbol table and expect Perl6 to handle it sanely
Well
For Perl6 it might actually work because of how similar P6 and Parrot are
jnthn Depends what you shove in, but to some degree that should be possible.
sorear but for more exotic stuff like Java and TCL??
jnthn Actually, I suspect that Rakudo swaps out more parts of Parrot than e.g. TCL does. 15:58
We have a custom multi-dispatcher, custom parameter binder, customer method dispatcher...
sorear Rakudo's metamodel is more analagous, though
jnthn But they all hang off the find_method and invoke vtable methods.
sorear we have objects with many types, we use vtable calls...
as opposed to the TCL metamodel: Everything is a string. No, really, *everything*. 15:59
jnthn Wow. :-)
masak sounds like TRAC, too. :)
sorear (although Tcl 8.0 has a crazyyyy hack where some strings are internally stored in parsed form so parsey primitives are near-noops)
Java at least has static type information, so the Java/Parrot importer can use static signatures to generate PMC->Object stuff 16:00
this assumes, however, that importers should be generating stub code at all 16:01
which is hinted at in PDD-31, but I wouldn't go so far as to say implied 16:02
sorear tries to summon Tene
16:02 wolf2k_ubuntu joined
sorear hmm 16:03
16:03 Exodist left
sorear I think in the process of explaining my problem I actually mostly figured it out 16:03
jnthn :-) 16:04
sorear though I still need to bounce this off Tene
jnthn *nod* 16:05
sorear since (s)he's apparently listed as the interop czar
jnthn Yes, Tene++ has a good grasp of inter-HLL things.
16:05 arthur-_ left 16:06 lichtkind joined
jnthn BTW, when is the next Rakudo monthly 16:06
?
sorear third thurdsay
jnthn If it's third Thursday in march that's like...ouch...next week!
sorear ouch?
jnthn Just feels scarily soon. :-)
masak that's really soon.
we need more colomons. 16:07
sorear I suppose "next week" is also the deadline for R* stuff
jnthn Not really
R* is in April. :-)
Late April.
sorear jnthn: do you know how the dalek nick mapper works
jnthn 'fraid not. 16:08
sorear after pushing that SEMANTICS file my realname got ++'d
jnthn dalek: help
...well, that's helpful
16:14 justatheory joined, Exodist joined 16:16 Exodist left, Exodist_ joined 16:20 masak left
lichtkind mberends: thanks 16:23
phenny lichtkind: 12 Mar 06:45Z <vamped> tell lichtkind re: irclog.perlgeek.de/perl6/2010-03-11#i_2092652 there is an error at the bottom. "Parrot will join Perl and Parrot" - I think => "Parrot will join Perl and Python"
lichtkind: 00:43Z <snarkyboojum> tell lichtkind that I found the viv page on the perl6 wiki misleading, and to see if he thought my newbie interpretation was helpful at all - providing it's not wrong :) (see backscroll for 2010-03-13)
lichtkind: 11:53Z <snarkyboojum> tell lichtkind - it's all good mberends++ has updated the entry
16:28 iblechbot left 16:30 ash_ joined
TimToady I had an idea for string representations this morning that seems interesting in my pre-coffee state. 16:31
sorear do tell
TimToady suppose, instead of indirection, NFG uses numeric methods and stores extended chars in rationals
sorear I have lots of ideas for string representations, most of them suck
NFG? 16:32
TimToady then all numbers are numerically comparable
a concept that is we came up with a year or two ago
it's written up in parrotland somewhere
ash_ wikipedia fails me, it says NFG is New Found Glory... i think your not talking about a band for some reason 16:33
TimToady NFG is NFC plus any non-composable sequences get negative temp ord that indexes into a table
but this is a different idea
my idea this morning is that extra characters in a sequence instead get stored as the fractional part of a Rat 16:34
then you can always compare two chars under Numeric and tell if they are the same char
sorear I think you just reinvented UTF-8. 16:35
TimToady no
this is not a variable width encoding, from the standpoint of p6
it's an array of numbers, most of which can be integers
with appropriate cheating representations for when most/all of the numbers are integers 16:36
sorear Ooooh
I like the idea.
TimToady and cat strings are just lazily constructed number arrays
sorear At least from a mid-level perspective 16:37
TimToady a rat64 can hold most non-composable chars, and there's always FatRat if we need it
philosophically it's still a form of NFG, but the indirection is via numeric typology rather than memory address
sorear yes
TimToady and multi-method numerics can be relied on for most comparison operations 16:38
sorear Where do we use random-access NFG strings?
TimToady so leg turns into <=> on each index position
sorear (or leg could just be bytewise leg with an appropriate variable width encoding) 16:39
TimToady but you can't index variable width easily 16:41
problem we have in p5
sorear For a random access representation I love this.
TimToady encoding all chars into a point on the real number line solves the fork presented by the two major NFG proposals 16:42
one NFG proposal was to have a global lookup table for negative integers
advantage: all strings are ==able via the integer value, even when negative 16:43
disadvantage: subject to DOS attack
that was my original proposal
sorear other disadvantage: triggers my global state gag reflex
TimToady the current Parrot proposal is per-string lookup 16:44
advantage: less problem with DOS
disadvantage: can't compare two negative values directly
16:44 dolmen joined
TimToady they are from different tables 16:44
16:44 arthur-_ joined
TimToady but using reals solves both of these 16:44
maybe call it NFR 16:45
normalize to reals
or "no fear" :)
sorear I suppose this needs a heterogenous array that can store both native ints and Rat PMC pointers 16:46
TimToady yes, but that can be optimized in various directions
especially if parrot can be persuaded to support such a structure 16:48
16:52 rgrau left
TimToady numerically, the fractional part of the rat could store multiple extender chars mod 0x110000, assuming that no extender would be larger than allowed by Unicode 16:52
16:52 rgrau joined
TimToady that still allows base characters to exceed 0x10ffff 16:53
so we still get private use characters in arbitrarily large sizes, just not extenders 16:54
hmm, someday there might be surreal numerics as well, which might be useful for huge extenders 16:55
sorear ...
TimToady modulus of Inf, as it were
but that can come later :) 16:56
arnsholt Surreal numbers?
TimToady google is your friend 16:57
arnsholt So it turns out, indeed
TimToady then we can have NFS :) 16:58
arnsholt At first blush it sounded like a Perlism, rather than a mathematicsism
TimToady well, Knuth and I have several things in common. :)
arnsholt Hehe 16:59
TimToady oddly, at the last Hackers Conference, I got to help him with a problem in unicode encodings he was having. 17:00
because people send him citations in all sorts of weird non-unicode encodings 17:01
so I gave him some magical perl incantations that would let him try different translations 17:02
lue hello! 17:04
TimToady o/
oh, another advantage of NFR, ord can give you the entire first character as a Rat 17:06
and floor of that gives you the ord of its base char 17:07
17:07 lue left, lue joined
lue /msg nickserv identify 6502 17:07
TimToady :sameaccent becomes easier too, I suspect
um 17:08
this is why I use an alias for that, and just say /id :)
17:17 Psyche^ joined, Psyche^ is now known as Patterner
lue Can some compress a few hours worth of backlog into a few sentences for me? :) 17:19
17:22 M_o_C left
lue afk & 17:22
sorear lue: MAK_ is new to Perl; TimToady wants to represent strings using numbers larger than infinity; jnthn likes my proposed semantics for Perl5/Parrot interoperation 17:25
TimToady actually, I'm happy with numbers smaller than infinity for now 17:26
rakudo: say "NFR" before "NFS" 17:27
p6eval rakudo a078e4: OUTPUT«1␤»
TimToady or we could scrap the old NFG proposal and steal the acronym 17:32
araujo scratches his head and wonders if cloning from rakudo git at 4Kbs isn't just too slow 17:35
TimToady mberends: that's still not quite right. viv has nothing to do with LTM, and LTM is not emulated by rule ordering 17:38
Cursor.pmc implements true LTM
and doesn't care about rule ordering except in the case of ties
(and, in fact, it uses another intermediate tiebreaker before that) 17:39
sorear TimToady: Do you have any strong feelings on the matter of Perl 5 and Parrot interoperation?
TimToady no, other than that Perl 6 wants Perl 5 to interoperate as seamlessly as possible 17:40
so having to talk about parrot is not good from a p6 point of view
pugs: use v5; print $] 17:41
p6eval pugs: OUTPUT«Error eval perl5: "sub { use ops (':default', 'binmode', 'entereval');; print $]␤␤}"␤*** 'print' trapped by operation mask at (eval 2) line 3.␤␤Undefined subroutine &main:: called.␤»
TimToady not allowed under safe, I guess
mberends jnthn: I'm creating a FakeDBI and a FakeDBD::mysql, and may also create FakeDBD::sqlite. Loading at runtime works. In order to verify that modules operate correctly, I'm currently porting the test suites of the Perl 5 equivalents. It will take a few days. I'll merge the initial results into zavolaj. Then I'm going back to work on proto. When proto works a bit, I'll move the FakeDBI stuff into separate repositories. I'm not planning to do *all* the wo 17:42
rk, there is lots of low hanging fruit for eager helpers to play with.
sorear TimToady: ok, I think I can work with that :)
mberends TimToady: thanks for the LTM correction, I'll look harder at the details and update the wiki again 17:43
TimToady the intermediate tiebreaker is actually longest literal match 17:44
we will recognize a word\w+ over a \w+, aand wordsworth beats them both 17:45
mberends TimToady: thanks 17:47
TimToady but again, that's how Cursor works, not viv 17:48
mberends maybe it's time to read the source code ;) 17:50
TimToady the LTM is in cursor_fate 17:51
jnthn mberends: OK, sounds good. And yes, I expect once the basics are there it'll be easy to recruit more volunteers. :-) 17:57
17:57 chromatic joined, chromatic left 18:00 abra joined
mberends TimToady: ack -l cursor_fate pugs/src/perl6 does not seem to show the source of cursor_fate. Where does cursor_fate come from? 18:00
TimToady Cursor.pmc 18:04
line 440 or so
ack is probably outsmarting you
it probably thinks .pmc is compiled code :) 18:05
mberends no, I was overlooking .pmc files as I guessed they were 'compiled'
self.blame()
exactly line 440 18:08
18:14 rv2733 left 18:34 ash_ left
TimToady phenny: tell masak "It's perverse that in Perl 6 you always write 'is' when it seems like you should write 'are'" 18:39
phenny TimToady: I'll pass that on when masak is around.
18:52 M_o_C joined 18:53 IllvilJa left 18:58 abra left
lue hello 19:04
19:19 perl7 joined, Exodist joined, Exodist_ left 19:20 abra joined
ingy morning 19:28
lichtkind ingy: moin
ingy :)
19:29 nadim joined
lue xkcd.com/378/ what DO you real programmers use? I prefer emacs. 19:30
ingy: mornin'
19:32 abra left 19:39 IllvilJa joined 19:45 xomas joined, xomas left, xomas joined
colomon lue: don't know if I count as a real programmer, but I use TextMate. Well, emacs if I'm stuck editing on a Linux box, but I vastly prefer TextMate. 19:50
lue I usually use Kate, but I really want to start using just emacs (if it didn't take a minute to load...)
colomon Back in my Windows days I used the Semware Editor, which was blazing fast and nicely customizable. I had it used Wordstar key sequences for a number of things...
Su-Shee I use gvim. but I'm no manly real programmer as well. ;) 19:51
lue I want to get a keyboard with a bunch of useless keys just to set bizzare commands to them :D 19:52
Su-Shee well press esc in vim and just let your cat walk over the keyboard and you'll see plenty of action and features ;)
lue my cat doesn't walk on keyboards. He just goes over them :) 19:53
(of course, most of our keyboards are on rolling shelves...)
19:54 Exodist left, Exodist joined 19:55 rgrau left 19:59 Exodist left
dalek kudo: 3ddd002 | jonathan++ | src/ (3 files):
Implement 'use MONKEY_TYPING'; augment and supersede are now forbidden without it. Infinitesimally small chance of entire works of Shakespeare being written as a side effect.
19:59
19:59 Exodist joined
colomon Ah, traits.pm handles the use MONKEY_TYPING for the entire core? 20:00
jnthn colomon: yes, see comment 20:01
colomon: If we do seperate compilation we'll have to scatter it more liberally
But for now it's fine in the first file, since we just concat 'em. 20:02
colomon rakudo: class Foo { has $.bar; }; say Foo.new.Str 20:04
p6eval rakudo a078e4: OUTPUT«Foo()<0x2aff2adff458>␤»
colomon interesting... 20:05
jnthn Just the class name with a memory address.
colomon yes.
jnthn Think that's what we did in alpha too.
colomon I don't recall ever seeing that before, but then, I don't know that I ever really tried it. 20:06
mathw phenny: tell masak It's possible if you nag me enough, and assistance would probably be useful. 20:09
phenny mathw: I'll pass that on when masak is around.
20:14 Exodist_ joined, Exodist left 20:19 Exodist_ left 20:20 Exodist joined
pugssvn r30060 | lwall++ | [STD] catch use of non-$ hard reference 20:21
Tene sorear: pong 20:23
20:26 TiMBuS left
Tene sorear: IMO, my inclination is that :from<foo> just returns foo-level stuff. You can always write a Perl6 wrapper around the library, even one that uses metamodel stuff to do it dynamically, but my conclusion after thinking about all of the issues in automatic translation last time was that we don't want to go there, at least not at first. I don't think it's possible to do properly in all cases ever, but it might be possible to do right in ... 20:28
... some cases in different ways, so it might make sense to also provide some libraries that try to do it if asked.
sorear: I'm going to be in and out all day, so please feel free to leave me details here, or email to /me at allalone.org, and I'll reply ASAP 20:29
sorear: I would love to have additional eyes on these issues. 20:30
sorear: I'm going AFK now, but I look forward to hearing from you. 20:32
20:32 M_o_C left 20:38 payload joined 20:41 rv2733 joined
Tene sorear: IMO, we *should* be able to put any PMC at all in a Perl 6 lexpad and have it work "properly", FSVO "properly". Methods on the object should always work. I also think that we should have Rakudo use at least some of the vtables appropriately. For example, IMO calls to postcircumfix:<[ ]> should in at least some cases map to the get_pmc_keyed_int vtable, and defining a method named postcircumfix:<[ ]> on a class should define a vtable ... 20:43
... override for that vtable, so other languages can do positional access on Perl 6 objects without calling strangely-named methods. Rakudo isn't doing that yet. In general, I consider any case of Rakudo actually breaking when given a non-native object to be a bug.
20:51 perl7 left
TimToady so far, parrot's abstractions have been far from leakproof... 20:56
20:56 Exodist_ joined
lue aye, but what about the draft? 20:56
20:56 Exodist left, Exodist_ left
TimToady missed it by a year 20:56
20:56 Exodist joined 21:01 vamped joined 21:02 arthur-_ left 21:03 arthur-_ joined 21:04 justatheory left 21:08 masak joined
jnthn lolitsmasak 21:09
masak \o/
phenny masak: 18:39Z <TimToady> tell masak "It's perverse that in Perl 6 you always write 'is' when it seems like you should write 'are'"
masak: 20:09Z <mathw> tell masak It's possible if you nag me enough, and assistance would probably be useful.
masak :) 21:10
not only is the messaging service around here great; the messages are, too :)
21:10 justatheory joined
masak jnthn: I've made an iota of progress on the named enums failure mystery. 21:11
jnthn masak: Cool
masak jnthn: it's the namespace parameters that cause things to blow up.
jnthn Ah.
masak still don't know why. 21:12
jnthn Maybe there's something funny with using namespace PMCs from Perl 6 like they're hashes. :-/
But shouldn't be. 21:13
masak that implies that we get past the calling mechanism and into the sub itself.
there are some indications we don't.
most notably, 'Null PMC access in invoke()' 21:16
21:16 masak left
jnthn
.oO( Null masak access in #perl6 )
21:16
21:17 masak joined
jnthn masak: So I guess a say at the start of the named enum creator doesn't print anything? 21:17
masak my neighbours' wifi connection är kass... 21:18
jnthn: will check.
jnthn masak: btw, why is it "är kass" here, but "e kass" in the song?
...or was it "min man är kass" in the song too?
jnthn didn't remember it that way
masak jnthn: 'e' is texting/hurried/slang for 'är'. 21:19
mostly because that's how it's pronounced.
jnthn Ah, I see. 21:20
masak (just as 'jag' is pronounced 'ja' and 'det' is pronounced 'de') 21:21
mberends a Dutchman might think your neighbournet is made of cheese
masak :)
I see the similarity cheese-kass-keso. 21:22
lue fromage!
masak Fromage is the odd one out in this kass :) 21:23
lue gorganzola! cheddar! guda! feta! mozzarela! 21:24
(sorry sir, we're all out)
masak By the way, I hear *real* mozzarella is made from buffalo milk. I'm eager to try that out sometime.
jnthn wendslydale?
21:25 DarkWolf84 joined
jnthn masak: Heh, that typical "if it's a common word it may well not be pronounced as it's written" thing bites again. :-) 21:26
DarkWolf84 hi :)
jnthn hi DarkWolf84
masak DarkWolf84: \o
lue \o
masak jnthn: yeah, well. fortunately the common words are finite and listable. :)
lue
.oO(what's the esperanto word for cheese?)
DarkWolf84 I really like to test the new rakudo versions
:)
lue DarkWolf84: do you wish to possess the bleeding-edge of rakudo? 21:27
masak lue: 'fromaĝo'.
jnthn Warning: blood stains. 21:28
lue masak: dankon
masak :)
DarkWolf84 i have the git version
not the last
lue you already have it then! \o/ have you compiled it?
DarkWolf84 it needs all inf to get compiled on my pc :(
yeah 21:29
masak 'all inf'?
lue all inf? I do not know that terminology
DarkWolf84 all eternity/infinity 21:30
:)
mberends DarkWolf84: be sure you also have subversion installed so that you can keep your Parrot up to date as well. We're get PARROT_VERSION bumps every few days.
jnthn
.oO( I accidentally the whole infinity )
DarkWolf84 just a silly p6 joke
jnthn mberends: Heh, half of them of late were to do with readdir. :-P 21:31
masak DarkWolf84: it seems doing 'ulimit -v 800000' before compiling Rakudo is a good idea nowadays. it's quite memory-intensive.
21:32 jferrero left
DarkWolf84 rakudo: ($a, $b) for 1..5 Z 6..10 -> $a, $b 21:32
p6eval rakudo 3ddd00: OUTPUT«Confused at line 11, near "($a, $b) f"␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
DarkWolf84 not works here too
:(
masak DarkWolf84: can't do statement-modifying for loop and '->' at the same time.
DarkWolf84: unltimately, it's because the '->' "belongs" to its block. 21:33
DarkWolf84 how to do it right
masak s/un/u/
rakudo: for 1..5 Z 6..10 -> $a, $b { say ($a, $b).join('!') } 21:34
p6eval rakudo 3ddd00: OUTPUT«1!6␤2!7␤3!8␤4!9␤5!10␤»
DarkWolf84 ok only the common form works :)
vamped is there a way to have phenny: private /msg someone instead of publicly
masak DarkWolf84: aye. for the above-stated reason.
lue masak: what is this ulimit command! Do not tell me I could use this to compile locally w/o killing the computer! 21:35
21:35 payload left
DarkWolf84 and it's really fast 21:35
masak lue: the trick is courtesy of moritz_++, who seemingly knows his Unix.
DarkWolf84: we don't hear that often around here :)
DarkWolf84 It's lot faster than alpha 21:36
masak unless it's in the context of "it crashed really fast"...
DarkWolf84 oh yeah I know this
It's really smells like rakudo * 21:37
ok I have second probably dumb question 21:38
jnthn nearly has a few more smart-matching tests brought back again. 21:39
DarkWolf84 how is map working in perl6
rakudo: map{.say} 1..20
p6eval rakudo 3ddd00: OUTPUT«Confused at line 11, near "map{.say} "␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
masak DarkWolf84: it gobbles as many items as there are parameters, and then runs the block and puts the results in an array.
21:39 jferrero joined
jnthn rakudo: map {.say}, 1..20 21:39
p6eval rakudo 3ddd00: ( no output ) 21:40
colomon sink
masak DarkWolf84: you might want to look at the CORE/Setting implementation of map to see it in more detail.
jnthn oh
colomon rakudo: (1..20).map({.say}).eager
DarkWolf84 rhe same bug
p6eval rakudo 3ddd00: OUTPUT«1␤2␤3␤4␤5␤6␤7␤8␤9␤10␤11␤12␤13␤14␤15␤16␤17␤18␤19␤20␤»
DarkWolf84 the same bug*
21:40 vamped left
colomon rakudo: (1..*).map({.say}).batch(20) 21:40
p6eval rakudo 3ddd00: OUTPUT«1␤2␤3␤4␤5␤6␤7␤8␤9␤10␤11␤12␤13␤14␤15␤16␤17␤18␤19␤20␤»
jnthn DarkWolf84: The problem is that map is lazy, and we don't have it becoming eager in sink context yet. 21:41
DarkWolf84 I forgot about lazy lists
thanks
colomon If you look at my last example there, the lazy list is infinite, and batch(20) means "Look at the next 20 items on the list". 21:42
rakudo: (1, 1, *+* ... *).batch(20).perl.say
p6eval rakudo 3ddd00: OUTPUT«(1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, 233, 377, 610, 987, 1597, 2584, 4181, 6765)␤»
lue is going to try compiling 楽土 locally in the first time for a long time.
masak rakudo: (1, 1, *-* ... *).batch(20).perl.say 21:43
p6eval rakudo 3ddd00: OUTPUT«Method 'Num' not found for invocant of class 'Block'␤current instr.: 'perl6;Mu;' pc -1 ((unknown file):-1)␤»
colomon masak: I only added Whatever to closure for *+n, n+*, *+*, and *-n. :) 21:44
DarkWolf84 ;(
masak colomon: ok :)
DarkWolf84 is there any way to make map to be not lazy 21:45
colomon rakudo: multi sub infix:<->(Whatever, Whatever) { -> $a, $b { $a - $b } }; rakudo: (1, 1, *-* ... *).batch(20).perl.say
p6eval rakudo 3ddd00: OUTPUT«Confused at line 11, near "rakudo: (1"␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
masak DarkWolf84: assign it to an array?
DarkWolf84: print the results?
jnthn Or .eager it like colomon showed
DarkWolf84 ok
jnthn or I think you can do...
colomon I believe the correct answer is "no".
jnthn rakudo: eager map { .say }, 1..20 21:46
p6eval rakudo 3ddd00: OUTPUT«1␤2␤3␤4␤5␤6␤7␤8␤9␤10␤11␤12␤13␤14␤15␤16␤17␤18␤19␤20␤»
colomon You can use .eager it get the results from it eagerly.
jnthn Oh
Yes, I guess if you look at it that way... :-)
colomon but it's still lazy internally, you're just getting all the lazy results at once. :) 21:47
DarkWolf84 thanks again for the help
mberends o/ # travel .nl -> .uk for $work next week 21:48
21:49 mberends left
colomon ooo, the uk. 21:49
pugssvn r30061 | jnthn++ | [t/spec] Correct a test. 21:50
masak DarkWolf84: we're glad to help, and motivated by the fact that you might very well take your newfound knowledge and write something really cool with it. :)
colomon rakudo: multi sub infix:<->(Whatever, Whatever) { -> $a, $b { $a - $b } }; (1, 1, *-* ... *).batch(20).perl.say 21:51
p6eval rakudo 3ddd00: OUTPUT«No applicable candidates found to dispatch to for 'infix:<->'. Available candidates are:␤:(!whatever_dispatch_helper , !whatever_dispatch_helper )␤␤current instr.: '_block44' pc 445 (EVAL_1:150)␤»
lue remember, colomon? No custom ops yet! :) 21:52
that still seems weird though...
colomon lue: that means you cannot add new ops. infix:<-> had better already be an op!
this is some wacky bug instead, I'd say.
lue I know, I corrected myself up there :) 21:53
jnthn rakudo: our multi sub infix:<->(Whatever, Whatever) { -> $a, $b { $a - $b } }; (1, 1, *-* ... *).batch(20).perl.say 21:54
p6eval rakudo 3ddd00: OUTPUT«(1, 1, 0, 1, -1, 2, -3, 5, -8, 13, -21, 34, -55, 89, -144, 233, -377, 610, -987, 1597)␤»
jnthn Ah.
colomon: We're not quite right on lexical-y multi bits yet. 21:55
colomon eh?
masak++ # that's a cool series! 21:56
lue afk &
masak colomon: it's just fib with a few minus signs thrown in :)
colomon masak: I know, but that's a nifty property I didn't expect. :) 21:57
masak it's a bit funny that the first star automatically comes to mean S(n-2)...
mathw \o/ 21:58
21:59 hercynium joined
jnthn ooh, NPW 2010 has a site! 21:59
masak far too late, I realized that when perl7 said that curiosity killed the cat, I should have replied that it was Schrödinger; at least we think so. 22:01
masak .oO( this pun delivered to you by deferred evaluation )
time to sleep a bit again, methinks. my cold is abating, but I need to help it out the door, too. 22:04
o/
22:04 masak left
pugssvn r30062 | jnthn++ | [t/spec] Bring some tests in line with the spec. 22:05
jnthn 3 more tests files and just short of 50 extra passing tests coming up. :-)
DarkWolf84 goodnight 22:06
22:07 DarkWolf84 left
jnthn ooh, actually maybe 4 and just over 50. 22:08
22:09 Su-Shee left 22:12 eternaleye left 22:18 nihiliad left
pugssvn r30063 | jnthn++ | [t/spec] Re-fudge ternary.t - we gain one the alpha failed, but also lose one that we can't do in master yet. 22:20
colomon \o/ 22:31
jnthn colomon: Just pushed - we win back 5 test files. :-) 22:32
dalek kudo: 5ec16a7 | jonathan++ | src/core/ (4 files):
Get several more cases of smart-matching to work again.
22:34
kudo: 8edd6c9 | jonathan++ | t/spectest.data:
Turn five more test files on again.
22:39 vamped joined
vamped what exactly does it mean to fudge a test? 22:40
jnthn vamped: Adding a directive like: 22:41
#?rakudo skip 'reason here'
To the .t file
A preprocessor called fudge then generates a .rakudo file and we run that instead of the .t file when doing make spectest for Rakudo
vamped ok - so just skipping part of the test file? 22:42
jnthn So we can, on a per-compiler basis, avoid running certain tests that will cause Epic Fail.
Right, but it actually commetns out the relevant tests.
Since they may actually cause parse fails.
So it's a bit more than just inserting a skip.
vamped ok. thanks. i got it.
jnthn :-)
22:52 pmurias left
vamped man each time I go back to coding perl 5, I find myself wanting to use perl 6 features which would make it oh-so-much easier 22:53
23:00 quietfanatic left 23:01 quietfanatic joined
colomon vamped: yes, it does make life hard. :) 23:03
jnthn ah, nice... 23:04
> class Foo { method lol { say "rofl" } }
> class Bar is Foo { method lol { say "omg hilarious" } }
> my $x = Bar.new; $x.lol; $x.Foo::lol;
omg hilarious
rofl
23:04 quietfanatic left
jnthn ...now we might be able to run some of the inheritance tests again. 23:04
23:04 quietfanatic joined
jnthn
.oO( Q. What do you call a highly amused Australian entertainer? A. Rofl Harris )
23:06
colomon go jnthn++, go! 23:07
23:11 quietfanatic left, quietfanatic joined 23:13 quietfanatic left
jnthn 69262 23:17
pugssvn r30064 | jnthn++ | [t/spec] Some reviewing and re-fudging of S12-class/inheritance.t. Toss one test and change two that I disagreed with. 23:19
jnthn Another two test files and a closed RT ticket coming up. 23:26
:-)
jnthn waits for spectest run
23:31 M_o_C joined
dalek kudo: 04102ca | jonathan++ | src/ (3 files):
Get $x.Foo::bar method syntax working again, minus a bug the version in alpha had.
23:38
kudo: 3282274 | jonathan++ | t/spectest.data:
Turn back on two inheritance related test files.
jnthn Here's some stats on tests from alpha that we still have got commented out: gist.github.com/331631 23:40
(test files, that is)
23:44 am0c joined 23:51 wolverian joined 23:55 quietfanatic joined 23:59 lichtkind left