Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2008-05-28

Perl 6 | Reference Documentation | Rakudo

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:04 jferrero joined #perl6
00:13 mncharity p6 creation status: () parser, still don't have one.  STD.pm is p6, partially running after automagic massage, largely correct, "almost good enough for now" spec.  parrot's grammar is p6, runs, somewhat slowly, but is less coverage.  STD_red, a manual massage of STD.pm, is not p6, runs quickly, has coverage somewhere between pugs/STD and rakudo.  pugs is non p6, increasingly non-spec, runs. somewhat slowly.
00:13 pugs_svnbot r20563 | bacek++ | [spec] Remove test skip for rakudo (requires rakudo r27848+). Fix array declaration
00:15 mncharity () regex engine.  no p6 ones at all.  rakudo's PGE best working one.  yet_another_regex_engine, in p5, has portability problems (eg, "not running on 32-bit perl").  nothing else really usable.
00:20 mncharity () compiler.  pugs - non p6, mature, dead.  rakudo - non p6, active.  elf - p6, low-bus-number active, currently less wizzy than pugs and rakudo, more than kp6.  being implemented in p6 perhaps provides greater leverage for wizziness than rakudo's pir, but less than pugs's haskell.  kp6 - sort of p6, inactive.
00:23 mncharity () runtime.  no p6 ones at all.  rakudo - active, featureful, but gaps still prevent extending it using p6.  elf - combination p5 and p6.  less complete than rakudo or pugs, perhaps even than kp6.  pugs - you know.
00:24 Auzon mncharity: Nice summary. Is this for a blog or similar?
00:24 vixey STD.pm almost runs?!
00:24 vixey how?
00:27 mncharity () usability: pugs - a bit slow, good coverage, has been used with several smallish (a few classes) projects, attempts at larger projects consistently fail.  elf - fast, narrower eclectic coverage, has been used for one larger project than pugs, but less code total.  rakudo - speed medium, more robust coverage, but almost no p6 ever run.
00:29 mncharity vixey: re 'STD.pm almost runs?!', said "partially running".  cd src/perl6; ./STD5_run.  can generally do expressions.
00:29 Auzon elf has a project?
00:29 pmichaud rakudo is non-p6?  by what measure?
00:30 bacek joined #perl6
00:30 mncharity re blog, thinking up elf summary for avar metastasized into a big picture summary.  cause hard to do the smaller without the bigger.
00:30 mncharity re 'elf has a project', huh?
00:31 mncharity pmichaud: my impression is other than the parser grammar, it's written almost entirely in pir, not p6.  no?
00:31 pmichaud no.
00:32 mncharity great!  elaborate...
00:32 mncharity ?
00:32 pmichaud the parser and the conversion to an AST are both written in p6.
00:32 Auzon re project: "[elf] has been used for one larger project than pugs, but less code total"
00:32 pmichaud http://svn.perl.org/parrot/trunk/languages/perl6/src/parser/actions.pm
00:32 lambdabot http://tinyurl.com/5b5g2h
00:32 avar Parrot recently implemented a mini-perl6 like language that they use for AST manipulation
00:32 mncharity re parser, PGE is p6?!?  or you mean, PGE, written in pir, takes a p6 grammar which generates a p6 ast?
00:33 pmichaud PGE, written in pir, can parse and execute p6 grammars and rules.
00:33 pmichaud rakudo is mostly written in P6.
00:33 pmichaud unless you're requiring that every tool used in the compiler toolchain is written in p6.
00:33 avar So the parser is PGE (implemented in PIR), the AST hacking is done in their miniperl6 and the actual logic is in PIR still
00:34 avar Like the implementation of operators and whatnot
00:34 avar (last I checked)
00:34 mncharity re every tool, not at all
00:34 pmichaud "the parser is PGE" is a bit misleading
00:34 pmichaud Rakudo's parser is written in Perl 6.
00:34 pmichaud PGE is a parser engine.
00:35 pmichaud Rakudo's parser is at http://svn.perl.org/parrot/trunk/languages/perl6/src/parser/grammar.pg   and http://svn.perl.org/trunk/languages/perl6/src/parser/grammar-oper.pg
00:35 lambdabot http://tinyurl.com/5jh29s
00:36 pmichaud sorry, 2nd url should be  http://svn.perl.org/parrot/trunk/languages/perl6/src/parser/grammar-oper.pg
00:36 lambdabot http://tinyurl.com/5r3cfq
00:36 avar I mean the PGE library, but it by design has the same syntax as some of perl 6
00:36 avar It still has inline pir there and not perl 6 and so on.
00:37 allbery_m joined #perl6
00:37 pmichaud yes, it has a small amount of inline PIR.  But I don't think that's enough to say "it's not p6".  The vast majority of the core code for the compiler is written in Perl 6.
00:37 pmichaud I think it's very misleading to say that Rakudo is written in PIR.
00:38 mncharity it might be clearer to say that rakudo's _grammar_ is written p6.  to avoid confusion between 'parser as spec+engine' vs 'parser as spec, engine separate thing'.  ie, "yacc's parser is written in yacc" and "yacc's parser is written in C", are both true, but the latter more informative.
00:38 pmichaud mncharity:  do you include the conversion to an ast as being part of the grammar?
00:39 mncharity given the {make ...} regex stuff, yes.
00:39 avar pmichaud: I don't think what I said was misleading (2008-05-28 00:34:12 <avar> So the parser is PGE...). When I was hacking on rakudo albeit doing some minor changes all the stuff I was doing was in PIR because I wasn't working on changing the grammar or the AST.
00:40 pmichaud what changes were you making?
00:40 mncharity 'The vast majority of the core code for the compiler is written in Perl 6', aside from the grammar, is that the miniperl6 avar mentioned?
00:40 avar adding object methods and other small stuff like that.
00:40 pmichaud avar:  can you give me a specific example?
00:41 pmichaud mncharity: if by "miniperl6" you mean "the code that is in actions.pm", then yes.
00:41 avar One patch I think I did added .sum to lists and arrays, another added a .say method to Object.
00:41 pmichaud can you write ".say" in Perl 6?
00:43 avar I don't pretend to know the first thing about rakudo really I'm just saying that when I was poking it 24/18/12/6 months ago all the stuff I was doing was almost exclusively in PIR because I wasn't changing the syntax or adding new features to the parser.
00:43 mncharity i have no idea what "miniperl6" means, looking for clarification....  is "actions.pm" plus the grammar the aforementioned "vast majority of the core code", or is there more I should look at?
00:43 pmichaud mncharity: grammar.pg is the grammar (the part that builds a parse tree).  actions.pm is the part that converts a parse tree into an AST.
00:44 pmichaud that, plus a variety of runtime libraries, is the rakudo compiler.
00:44 pmichaud avar:  rakudo has substantially changed in the past 6 months, then.
00:44 pmichaud avar:  as of 6 months ago most of what we were writing was PIR, yes.
00:44 avar Parrot has a language with a perl6 like syntax that has just enough features to do the operations you need to have for AST hacking, i.e. simple datatypes, constructing lists etc. They use that to parse their AST manipulator and generate a .pir file
00:44 pmichaud as of 5 months ago most of what we have been writing is p6.
00:45 avar (All the stuff goes into one giant PIR file which then gets compiled to a pbc or executable)
00:45 avar (Standard disclaimer about me not knowing anything about parrot here)
00:45 pmichaud (avar has the basic  build process correct :-)
00:45 mncharity re 'can you write ".say" in Perl 6?', yes.  http://svn.pugscode.org/pugs/misc/elf/elf_f_src/Prelude.pm  oh, that's *say().  There's a .print there though.
00:45 mncharity ;)
00:45 pmichaud and .print is written in P6?
00:45 avar So stuff like object methods and such gets written in perl 6 now?
00:46 pmichaud we're still writing the object methods for core types in PIR, simply because that's easier.
00:46 pmichaud for example, it's fairly difficult to justify writing "substr" in Perl 6, given that the PIR version is about 5 lines of code.
00:47 mncharity re 'actions.pm is the part that converts a parse tree into an AST', ah, ok.  so re earlier 'is AST part of grammar', then not so much.  is anything downstream of the AST in p6?
00:48 mncharity re "it's fairly difficult to justify writing "substr" in Perl 6, given that the PIR version is about 5 lines of code", wrt rakudo, sure.  wrt "it would be nice to run p6 in peoples' browsers, and elsewhere", it would be nice to have a p6 implementation of substr.
00:48 pmichaud is there a p6 implementation of substr somewhere?
00:49 mncharity at least a p6 implementation that moved from all the prelude multi and type'ed argument ness down to something more primitive.
00:49 pmichaud in Prelude.pm, where's the definition for 'print' that 'say' is using?
00:50 pmichaud (anything downstream of the AST in p6)  Parrot has a common AST representation -- the tools that compile the AST into PIR are themselves written in PIR, yes.
00:50 pmichaud but that's really a part of the toolset.
00:50 mncharity print is a p5 primitive.  should probably be renamed something like  primitive::print, since there's no way such a p5 primitive is going to correctly participate in multi dispatch, etc.
00:51 pmichaud right, so even Prelude isn't pure Perl 6.
00:52 pmichaud it relies on p5 primitives.
00:53 mncharity err, you don't mean elf's Prelude.pm, yes?  using a primitive defined elsewhere wouldn't make it not pure Perl 6.  re Prelude in general, of course runtimes define some things a primitives, how else.  Though there's an insentive to have them not end up directly in the Prelude.  but re self hosting, the more
00:54 pmichaud rakudo does the same thing -- it defines some things as primitives.  And it uses PIR to do that.
00:54 mncharity p6 spec prelude which is available as p6, the less the various runtimes will need to implement.  again, not directly an issue for rakudo, but certainly one for p6 in general.
00:55 pmichaud I agree, the more prelude that we have as p6 spec, the better.  But lacking that prelude, rakudo chooses to do a lot of its runtime primitives in PIR.
00:55 pmichaud but the bulk of the *compiler* is clearly p6.
00:55 mncharity re primitives, sure, but the point is, pugs's compiler guts are written in haskell, elf's in p6, and rakudo's in pir.
00:56 mncharity me reads, preceeding line, things
00:56 mncharity *thinks
00:56 mncharity "vocabulary" conflict
00:57 mncharity the thing which takes an ast, does scope, lifetime, type and dataflow analysis, in so far as any of our compilers do, do it in haskell, p6, and pir, respectively.
00:57 mncharity and runtime code emittion
00:57 mncharity *emission
00:58 duzy joined #perl6
00:58 duzy greeting :)
00:58 pmichaud perhaps.  but someone working on the rakudo compiler itself never has to deal with the underlying PIR
00:59 pmichaud (yes, most of do deal with some pir, and knowing pir is helpful)
00:59 pmichaud *most of us
01:00 mncharity re someone working, definitely vocabulary divergence. :)   s/compiler/implementation/ and I'll bite.
01:00 mncharity though...
01:00 avar Yeah, but what the compiler maintainer has to deal with and whether the whole system is bootstrapped are two really different things:)
01:00 mncharity I thought it still wasn't possible to chose to write, say, a prelude method or sub in p6?
01:01 pmichaud one can write subs in p6, yes.
01:01 avar But AFAIK parrot has never been aiming for a Perl 6 bootstrap
01:01 pmichaud we don't have a good mechanism to include those as part of the perl6.pbc file yet, but that's coming real soon.  But we're also finding that there aren't a lot of subs that we're dying to have written as Perl 6.
01:02 pmichaud rakudo's primary goal is a working Perl 6 implementation.  bootstrapping is secondary.
01:02 pmichaud (we expect to do bootstrapping, yes, but thus far it's a secondary goal.)
01:04 mncharity so "one can write subs in p6", but until "real soon", it is not currently possible to write prelude subs or methods for rakudo in p6.  with the addendum that you're finding such a thing to be of limited interest.
01:04 avar Yes I know, parrot is a runtime as opposed to a x-in-x compiler like kp6 tried to be or your average C compiler is.
01:04 avar But it's aiming to bootstrap eventually? I didn't know that?
01:04 avar s/\?$//
01:05 avar How will that work? Parrot has a lot of libraries in PIR that further rely on stuff written in C which would all have to be rewritten in Perl 6 if it were to bootstrap itself, or am I misunderstanding what you mean by bootstrap?
01:06 pmichaud I mean that eventually the AST compiler and possibly PGE will be (re)written in Perl 6.
01:06 pmichaud once the AST compiler is written in Perl6, we can target whatever backend we really want.
01:06 pmichaud (actually we could do that now, but it's not a huge priority at the moment.)
01:07 pmichaud if by bootstrap you mean "a complete implementation from Perl 6 to machine code written entirely in Perl 6"... I don't know anyone who is doing that.
01:07 mncharity so to recap, my undertanding is rakudo is p6 in the grammar and actions, and entirely non-p6 in the engine, analysis, emission, runtime, and prelude.  yes?
01:08 pmichaud prelude will become more p6 as we progress
01:08 pmichaud but yes, that's a fair understanding.
01:09 pmichaud what is elf's runtime written in?
01:11 mncharity almost entirely p5.  both because of Moose and Class::Multimethods, and because it's currently heavily using unboxed objects.  and because very little besides a few unboxed objects are implemented.
01:12 pmichaud right.  so the fact that a runtime is non-p6 is likely to be expected.
01:12 mncharity objective is to minimize the p5 footprint as much as possible.  given that anything non-p6 will all have to be rewritten for each new backend.
01:13 pmichaud reasonable.
01:14 pmichaud (for the target goal)
01:14 mncharity re runtime, I'd ideally like to have almost all the runtime in p6, with backend-specific overlays.  but... don't even have macros yet, so still far from that.
01:15 mncharity next step along that path is separating the "figuring out what the IR tree is trying to say" from the "emit a method call as piece of p5 code X".
01:15 pmichaud anyway, yes, there's a fair amount of non-p6 code in rakudo (if one counts the compiler tools used to generate it), but the bulk of the analysis and conversion from parse tree to executable form is being done in p6.
01:16 pmichaud I certainly think of rakudo as being written with more p6 code than non-p6 code.
01:16 * mncharity boggles... interesting
01:19 mncharity I suspect my concept "rakudo" includes many files which your's doesn't.  view from outside parrot, vs view from inside.
01:19 pmichaud well, if one treats 'elf' as requiring p5/moose, then I suspect the view is much the same :-)
01:19 mncharity ie, if PGE is a compiler tool, no part of rakudo, then the entire rakudo front-end is p6.
01:20 pmichaud I think that p5 and moose are elf's virtual machine, while parrot is rakudo's.
01:20 pmichaud (phone)
01:21 mncharity currently the primary elf variant isn't using Moose... wondering whether it might be worth dropping Moose for a while, in pursuit of kiss variant pruning.
01:21 stevan_ mncharity: fyi - Moose/MOP svn HEAD is 20-25% less slow
01:22 mncharity ! :)
01:22 mncharity hi stevan_
01:22 mncharity startup or runtime?
01:22 stevan_ uhm
01:22 stevan_ test suite :)
01:22 mncharity * running time
01:22 mncharity :)
01:23 stevan_ but seems to be reflected in several other large moose app test suites too
01:23 pmichaud okay, p5 is elf's virtual machine.  :-)
01:23 pmichaud and perhaps parts of CPAN ?  ;-)
01:23 mncharity :)
01:23 mncharity autobox
01:24 pmichaud anyway, an outside view of 'elf' might say it's mostly p5 and C.  :-)
01:25 Ched- joined #perl6
01:25 mncharity but I would love it if someone started a non-p5 backend.  basically, if elf isn't running just fine on some non-p5 backend, then elf still has a fundamental gap.  but that's just the focus with which it was defined.
01:26 pmichaud there is that difference -- in the parrot world we aren't explicitly targeting other backends
01:26 pmichaud anyway, I'm going to go hack again.
01:27 TimToady stevan_: can moose parameterize roles on values in addition to types yet?
01:27 stevan_ no, it cant even do it on types yet
01:28 TimToady hmm, thought I read that somewhere...
01:28 mncharity re "explicitly targeting other backends", indeed.  which makes it harder to draw such "what is the language" lines.  targetting multiple backends makes the choice clearer.  eg, perl compatible regexp engines are out (everyone has them), p6 regex engines are in.
01:28 stevan_ no, we have parameterized types
01:28 TimToady okay, it's eval for now then...
01:28 pmichaud TimToady: oh, I had a question regarding list() -- does that get special parsing treatment?
01:28 mncharity back to hack.   enlightening conversation.  tnx
01:28 pmichaud or is it a normal function?
01:29 TimToady I think it's a function that processes on the raw Capture maybe
01:29 pmichaud the example being:     list(1, 2, a=>3, 4)
01:30 TimToady assuming a raw Capture can keep those 4 things in order, of course...
01:31 pmichaud hmmmm
01:31 TimToady but it does seem that it should treat a=> as a pair, not as a named arg
01:31 pmichaud currently pugs does something special with "list" to make it work.
01:31 TimToady especially when you start writing @(1, 2, a=>3, 4) instead
01:31 pmichaud er, "work".
01:31 mncharity if anyone is looking for a challenging p5 project, create a p5 module/design, which compared to Moose, is more focused on p6 compliance, and less on "humans can actually use it by hand in p5".  perhaps involves cannibalizing Moose.  ie, the objective
01:32 mncharity is to end up with a *fast* prototype spec object system which can be emitted to mechanically.
01:32 pmichaud pugs:  my &f := &list;   say &f(1, 2, a=>3, 4);
01:32 exp_evalbot OUTPUT[*** Named argument found where no matched parameter expected: ("a",Ann (Pos (MkPos "/tmp/3B2HytjWsa" 1 35 1 36)) (Val (VInt 3)))␤    at /tmp/3B2HytjWsa line 1, column 23-40␤]
01:32 pmichaud pugs:  say  list(1, 2, a=>3, 4);
01:32 exp_evalbot OUTPUT[12a      34␤]
01:34 TimToady looks like pugs has special-cased list() where it should instead know how to retrieve the orginal Capture order
01:34 pmichaud anyway, I have my answer for now, which is that either Captures keep track of the argument order, or we do something special with list
01:34 pmichaud if Captures keep track of the original argument order, that's going to make things tricky for Parrot.
01:35 pmichaud because Parrot requires named arguments to come after positional ones
01:36 mncharity does anyone know how much of t/ rakudo parses?  /me ponders ways to move from STD_red to p6...
01:36 pmichaud (currently PCT reorders arguments to make sure this requirement is met.)
01:37 TimToady seems like any time you throw info away you end up with a design smell of some sort or other...
01:38 pmichaud also, as a head's up -- named argument passing was a topic of today's #parrotsketch and will likely come up during the design meeting
01:39 pmichaud somehow we'll have to bridge the gap between Parrot and Perl 6... and my preference is that Parrot do it and not have to do a lot of workarounds in rakudo :-)
01:40 pmichaud where "do it" == "the bulk of the work in bridging the gap"
01:40 pmichaud anyway, thanks for the answer.  :-)
01:40 TimToady well, it might be the wrong answer... :)
01:41 pmichaud I'm sure if it is you'll tell us at some point :)
01:41 TimToady usually after someone has told me (repeatedly) :)
01:41 pmichaud it's not clear from the synopses that captures record relative positions of named and positional values
01:41 lisppaste3 joined #perl6
01:42 pmichaud (perhaps because this question hasn't come up before.)
01:42 TimToady I've always kinda had the feeling it oughta, but audrey argued me out of it, for various good reasons, but the real problem may be a language design problem
01:43 TimToady and maybe pairs are a little too context-dependent in their meaning
01:43 TimToady there are various ways to finesse it, but it's not clear what the costs are
01:43 pmichaud fwiw, everything is okay with  (1, 2, a=>3, 4), because it's not a postcircumfix:<( )>
01:43 pmichaud same for  @(1, 2, a=>3, 4)
01:43 pmichaud it's only something like   list(...) that poses a difficulty at this point.
01:44 pmichaud (from what testing I've done.)
01:44 TimToady well, it's possible to move the problem around without solving it too...
01:44 pmichaud :-)
01:45 TimToady and arguably @(...) should treat a pair as a named argument, since it's an operator, and operators are just functions
01:45 pmichaud yes, there's that argument also. :-)
01:46 pmichaud anyway, something to think about.  for now rakudo will likely take the pugs approach until we can figure out how it fits together and what we'll need or have from Parrot to resolve it.
01:47 pmichaud it's not and urgent problem from the rakudo perspective.
01:47 pmichaud s/and/an/
01:47 TimToady 'k will go off and think & # dinner
01:47 pmichaud thanks, enjoy dinner.
01:48 cjfields_ joined #perl6
01:49 pmichaud oh, here's a radical and possibly very bad suggestion
01:49 pmichaud have  foo => 3  always be a positional pair, and require a colon for named arguments
01:50 pmichaud a => 3    # positional pair
01:50 pmichaud :a => 3    # named argument, same as :a(3)
01:52 pugs_svnbot r20564 | Auzon++ | [gsoc_specteset] adding some simple module re-export tests
01:53 Auzon Apparently I can't spell spectest. Oh well.
01:53 mncharity :)
01:56 alester_ joined #perl6
02:15 Auzon joined #perl6
02:22 BinGOs_ joined #perl6
02:25 cjfields joined #perl6
02:41 alester_ joined #perl6
02:56 cjfields joined #perl6
03:42 eternaleye_ joined #perl6
03:45 TimToady I was thinking more like named args always use a => 3 or :a(3), and you have to say 'a' => 3 to force pairs in argument lists (but circumfix:<( )> always makes pairs regardless
03:53 TimToady problem with :a => 3 is that :a is a term in its own right
03:53 REPLeffect_ joined #perl6
04:06 cjfields joined #perl6
04:06 cjfields left #perl6
04:55 diakopter TimToady: b/c of the specification for a Perl 6 interpreter/compiler to treat source code as Perl 5(.which?) until "use v6;", it seems to me that any complete implementation will need perl5.x.x (at least) linked (b/c no one is going to succeed to reimplement perl5 (perfectly) in Perl 6 or even PCT).  This means every (bootstrapped, self-hosting, or otherwise) Perl 6 implementation will include perl5 as a dependency.  It also ...
04:55 diakopter ... implies to me that when implementing tight interaction between/among the interpreters, a perl5-hosted implementation has advantages.  thoughts?
04:57 diakopter TimToady or anyone else, I mean...
05:00 Auzon Yeah, the requirement of Perl 5 is somewhat constraining
05:00 diakopter and for the (conjectured?) requirement of a perl6 to analyze/compile source to an executable, it seems to me that all these executables will end up looking just like PAR executables, b/c of the possible necessity of doing an arbitrary runtime eval().  Another advantage of a Perl 5 host?
05:00 Auzon Too bad it's so popular ;)
05:01 Auzon I imagine we'll see Perl 6 implementations linking to libperl, or just ignoring that part and almost being Perl 6.
05:02 diakopter or that specification redacted :D
05:03 diakopter but that begs another question - is it also a requirement for a perl6 to include a Perl5 grammar?    ??!!!?
05:03 Auzon I've recently been wondering about a perl52perl6 translator of sorts, based off of Perl 5's PPI module (http://search.cpan.org/perldoc?PPI)
05:03 lambdabot Title: PPI - Parse, Analyze and Manipulate Perl (without perl) - search.cpan.org
05:04 alc joined #perl6
05:05 Auzon Apparently it's pretty good with parsing perl5. So maybe it'd be enough to write a translator using that, then translating itself to Perl 6.
05:06 Auzon Maybe I'm missing something. And maybe PPI isn't good enough here.
05:06 diakopter it seems that (as pugs does) it would be extremely convenient to be able to use/require CPAN(5) modules already in site/  At least you would want to be able to interact with them somehow.
05:06 diakopter but I don't know if the synopses address that.  (use'ing Perl 5 modules from Perl 6 code)
05:07 diakopter I mean, it's all quite magical in pugs
05:08 TimToady ppi isn't good enough, which is the whole reason I wrote mad instead
05:08 * diakopter read that as "went mad"
05:08 Auzon Likely that too ;)
05:08 TimToady and as it happens, the p5-to-p6 translator was a SoC project two years ago :)
05:09 Auzon How well did it go?
05:09 TimToady okay given how much we didn't know yet about Perl 6...
05:09 TimToady it's in Haskell
05:09 TimToady takes yaml output of MAD as input
05:10 Auzon Interesting.
05:10 diakopter TimToady doesn't need any more compelling reasons to go mad.
05:11 TimToady see ./misc/pX/Common/P5_to_P6_Translation if you're interested
05:13 * diakopter waits for the implementation named "psyx"
05:13 diakopter several pronounciation choices
05:13 TimToady biab &
05:14 Auzon Interesting, but I don't speak Haskell
05:16 Auzon anyway. sleep &
05:18 diakopter fg
05:18 Auzon yes, thanks.
05:48 benjammy joined #perl6
05:59 meppl joined #perl6
06:46 luqui joined #perl6
07:06 japhb joined #perl6
07:10 b_jonas joined #perl6
07:12 pbuetow joined #perl6
07:15 IllvilJa joined #perl6
07:15 agentzh joined #perl6
07:15 smtms joined #perl6
07:15 kane_ joined #perl6
07:15 Caelum joined #perl6
07:15 Maddingue joined #perl6
07:15 kolibrie joined #perl6
07:15 arguile joined #perl6
07:36 iblechbot joined #perl6
07:41 cosimo joined #perl6
07:59 bsb left #perl6
08:09 pmurias joined #perl6
08:10 alanhaggai joined #perl6
08:37 Caelum joined #perl6
08:40 alanhaggai joined #perl6
09:26 lambdabot joined #perl6
09:46 rindolf joined #perl6
09:58 elmex joined #perl6
10:04 ludan joined #perl6
10:04 ludan hi
10:04 moritz_ hi
10:11 rindolf Hi ludan
10:11 rindolf Hi moritz_
10:11 rindolf Hi all.
10:49 ruoso joined #perl6
10:52 alanhaggai_ joined #perl6
11:03 Ukkaron joined #perl6
11:09 IllvilJa joined #perl6
11:09 Ukkaron left #perl6
11:18 mj41 joined #perl6
11:20 FurnaceBoy joined #perl6
12:17 braceta joined #perl6
12:40 alanhaggai joined #perl6
12:51 cmarcelo joined #perl6
13:22 REPLeffect_ joined #perl6
13:29 alc joined #perl6
13:30 jhorwitz joined #perl6
13:31 rakudo_svn r27871 | pmichaud++ | [rakudo]:
13:31 rakudo_svn r27871 | pmichaud++ | * Add some more operators (RT#54946, dolmen++)
13:31 rakudo_svn r27871 | pmichaud++ | * Patch courtesy Olivier Mengu?\195?\169 <olivier.mengue at gmail.com>
13:36 allbery_b joined #perl6
13:36 wknight8111 joined #perl6
13:51 rakudo_svn r27872 | pmichaud++ | [rakudo]:
13:51 rakudo_svn r27872 | pmichaud++ | * Refactored version of List's grep, reduce, first methods (RT#54822, bacek++)
13:51 rakudo_svn r27872 | pmichaud++ | * Patch courtesy Vasily Chekalkin <bacek@bacek.com>
13:56 rakudo_svn r27874 | pmichaud++ | [rakudo]:
13:56 rakudo_svn r27874 | pmichaud++ | * Handle negative length in Str.substr (RT#54766, bacek++)
13:56 rakudo_svn r27874 | pmichaud++ | * Patch courtesy Vasily Chekalkin <bacek@bacek.com>
14:03 sscaffidi joined #perl6
14:06 pugs_svnbot r20565 | moritz++ | [spec] last item of an array is @a[*-1], not @[-1]
14:08 rakudo_svn r27875 | pmichaud++ | [rakudo]:
14:08 rakudo_svn r27875 | pmichaud++ | * Update README with "make spectest_regression" (RT#54762, moritz++)
14:08 rakudo_svn r27875 | pmichaud++ | * Patch courtesy Moritz Lenz <moritz@casella.verplant.org>
14:09 chris2 joined #perl6
14:12 rakudo_svn r27876 | pmichaud++ | [rakudo]:
14:12 rakudo_svn r27876 | pmichaud++ | * Add 'pop' function.  (RT#54746, bacek++)
14:12 rakudo_svn r27876 | pmichaud++ | * Patch courtesy Vasily Chekalkin <bacek@bacek.com>
14:17 cjfields joined #perl6
14:18 TJCRI joined #perl6
14:21 pugs_svnbot r20566 | moritz++ | [spec] more @a[-1] -> @a[*-1] transition
14:22 cjfields rakudo: my $str = 'AAGGAGTGACTCAAAA'; my $str2 = $str.trans('wsatugcyrkmbdhvnATUGCYRKMBDHVN' => 'WSTAACGRYMKVHDBNTAACGRYMKVHDBN'); $str.say; $str2.say;
14:22 exp_evalbot rakudo r27876 OUTPUT[too few arguments passed (2) - 3 params expected␤current instr.: '_block11' pc -340181811 ((unknown file):-1)␤
14:22 jrockway joined #perl6
14:22 cjfields pugs: my $str = 'AAGGAGTGACTCAAAA'; my $str2 = $str.trans('wsatugcyrkmbdhvnATUGCYRKMBDHVN' => 'WSTAACGRYMKVHDBNTAACGRYMKVHDBN'); $str.say; $str2.say;
14:22 exp_evalbot OUTPUT[AAGGAGTGACTCAAAA␤TTCCTCACTGAGTTTT␤]
14:22 moritz_ what's Str.trans ?
14:23 cjfields transliteration
14:23 moritz_ ah, tr///
14:23 cjfields S05?
14:23 moritz_ S29 perhaps?
14:24 cjfields http://feather.perl6.nl/syn/S05.html#Transliteration
14:24 lambdabot Title: S05
14:24 rakudo_svn r27877 | pmichaud++ | [rakudo]:
14:24 rakudo_svn r27877 | pmichaud++ | * Add refactored implementation of 'map' (RT#54742, bacek++)
14:24 rakudo_svn r27877 | pmichaud++ | * Patch courtesy Vasily Chekalkin <bacek@bacek.com>
14:25 cjfields rakudo doesn't have trans() implemented correctly
14:25 iblechbot joined #perl6
14:26 moritz_ cjfields: is t/spec/S05-transliteration/trans.t correct?
14:27 * cjfields checking the transliteration tests...
14:29 cjfields moritz_: It appears so.  I think my example is wrong (supposed to pass a Pair, at least)
14:30 moritz_ cjfields: there's no contradiction in both being wrong, rakudo doesn't parse the test yet
14:31 cjfields Right, but the method is implemented in rakudo (I think in String)
14:31 * cjfields digging through...
14:33 cjfields yep, in src/pmc/string.pmc, there is a trans() method
14:34 cjfields 'Translate ascii string src with entries from trans_table'
14:36 cjfields I'll ask on #parrot, maybe they would know...
14:37 moritz_ cjfields: I'm trying to get that test working in rakudo
14:37 cjfields k
14:38 polettix joined #perl6
14:42 penk left #perl6
14:48 rdice joined #perl6
14:51 moritz_ S03-operators seems to be a fairly braindead name since all of S03 is about operators
14:52 rakudo_svn r27879 | pmichaud++ | [rakudo]:
14:52 rakudo_svn r27879 | pmichaud++ | * Fix "()" (and "[]") to return an empty list.
14:52 rakudo_svn r27879 | pmichaud++ | * Reported by bacek++, moritz++ .
14:52 Juerd moritz_: SEO ;)
14:54 moritz_ Juerd: ?
14:54 alanhaggai_ joined #perl6
14:54 Juerd moritz_: Search Engine Optimization. A horrible buzzword often mentioned by my clients :(
14:55 moritz_ Juerd: ah *that* SEO - I don't think we need that for Perl 6 ;-)
14:55 Juerd And after I refuse to do more than just making their website sane, they find someone else and pay ridiculous amounts for something that probably doesn't work at all, and if it works, will stop working in a few months.
14:56 Juerd In the mean time my own sites, having plain HTML and very few images, keep scoring well.
14:56 Juerd Where "score" is rank.
14:57 moritz_ most of all you need to have good content (and sane techniques), then the rest comes all by itself
14:58 fullermd But who wants to waste time creating content?  We just want more people coming to the site!
14:58 avar I once sent a danish embedded router company a job application and as "my first test" they demanded I increase their google rating.
15:16 rakudo_svn r27880 | pmichaud++ | [rakudo]:
15:16 rakudo_svn r27880 | pmichaud++ | * Add 'iterator' method to List.
15:16 rakudo_svn r27880 | pmichaud++ | * Fix 'perl' method to be a lot cleaner and simpler.
15:26 rakudo_svn r27881 | pmichaud++ | [rakudo]:
15:26 rakudo_svn r27881 | pmichaud++ | * Fix List.perl() method.
15:32 cmarcelo left #perl6
15:33 lambdabot joined #perl6
15:33 alanhaggai joined #perl6
15:36 moritz_ this is revision 20567 codename "it even works"
15:36 pugs_svnbot r20567 | moritz++ | [irclog] link parrot's RT numbers
15:37 kst` joined #perl6
15:49 armagad_ joined #perl6
16:00 pugs_svnbot r20568 | moritz++ | [irclog] make #perl6 link to its logs in the logs
16:00 pugs_svnbot r20568 | moritz++ | (mostly useful for cross-references between #perl6 and #parrot)
16:01 moritz_ [particle]++ for suggesting
16:02 nothingmuch joined #perl6
16:08 pbuetow joined #perl6
16:09 * moritz_ wonders if he should exclude join messages from the logs
16:09 moritz_ since leaves/ping timeouts/etc. aren't in, they are of limited usefulness anyway
16:09 moritz_ would anybody miss them?
16:10 justatheory joined #perl6
16:12 diakopter moritz_: I see leaves in the logs
16:13 moritz_ diakopter: I know, but not all of them are recorded
16:13 moritz_ diakopter: actually only /leave's but no timeouts (which are much more common), no kicks
16:16 braceta joined #perl6
16:17 rakudo_svn r27884 | particle++ | [rakudo] rename t/passing_spec to t/spectest_regression.data
16:17 rakudo_svn r27884 | particle++ | ~ update makefile template to match
16:24 rakudo_svn r27885 | particle++ | [rakudo] add more passing tests to spectest_regression
16:24 rakudo_svn r27885 | particle++ | Courtesy of Moritz Lenz (moritz++)
16:32 rakudo_svn r27887 | particle++ | [rakudo]
16:32 rakudo_svn r27887 | particle++ | this ugly piece of perl 5 code runs 'make spectest' and looks
16:32 rakudo_svn r27887 | particle++ | for passing test files that are not yet included in the
16:32 rakudo_svn r27887 | particle++ | 'spectest_regression' target. The output is an evil mess, but still useful.
16:32 rakudo_svn r27887 | particle++ |
16:32 rakudo_svn r27887 | particle++ | ~ not cross-platform
16:33 rakudo_svn r27887 | particle++ | ~ needs to be generalized
16:33 rakudo_svn r27887 | particle++ | ~ patches welcome
16:33 rakudo_svn r27887 | particle++ | Courtesy of Moritz Lenz (moritz++)
16:46 avar w 9
16:51 Psyche^ joined #perl6
16:53 Auzon moritz_: It's nice to see when I join/part so I can see what messages I missed
16:55 moritz_ Auzon: ok, I'll leave it in then
16:58 alanhaggai_ joined #perl6
17:02 [particle1 joined #perl6
17:05 hercynium being lazy, I have to ask - where would I find the logs for this channel?
17:06 Auzon It's in the topic.
17:06 hercynium ach - yeah
17:06 Auzon http://irc.pugscode.org/
17:06 lambdabot Title: IRC log for #perl6, 2008-05-28
17:06 TimToady diakopter: btw, to actually answer your earlier question, I don't think every Perl 6 executable has to recognize Perl 5; only those implementations that are intended to be reachable from /usr/bin/perl, really
17:07 hercynium yeah - I'm using Xchat-GNOME and the silly thing hides the end of the topic if it exceeds the window size
17:07 hercynium thx, Auzon and lambdabot
17:08 hercynium at least my ignorance is recorded for posterity ;)
17:09 TimToady some of us prefer our ignorance to be writ large  :)
17:09 moritz_ TimToady: that's why you published perl 1, right? ;-)
17:10 TimToady indeed...
17:11 moritz_ actually I never ran wrote perl 1 code, so I can't really say ;)
17:11 obra TimToady: this reminds me of schwern's original Class::DBI talk: Class::DBI - A Collection of Solved Problems or a Triumph of Multiple Inheritance
17:13 TimToady well, it's really easy to solve one problem while creating a different problem  :)
17:13 * obra grins
17:13 * obra wonders what new problems he's created today
17:14 TimToady for the last eight years I've been doing Studies in Unimplementability  :)
17:15 * obra grins. It looks like the implementors are starting to catch up with you, though. Or they're just wearing you down.
17:15 TimToady with an emphasis in Emergent Properties of Complex Systems
17:21 [particle1 sounds like a doctoral thesis
17:23 [particle] ...or the subtitle for the next state of the onion
17:27 [particle] remember, it doesn't matter how you get there, if you don't know where you're going.
17:30 hercynium particle, now *that* sounds like a good subtitle
17:36 meppl joined #perl6
17:40 fullermd I don't know where we're going, but there's no sense being late.
17:55 FurnaceBoy joined #perl6
18:04 * ruoso preparing the "Perl 6 is just a SMOP" presentation that will take place at the PPW in Braga, June 6....
18:09 pmurias joined #perl6
18:11 eternaleye_ joined #perl6
18:12 ilogger2 joined #perl6
18:17 cjfields joined #perl6
18:18 cjfields joined #perl6
18:34 pmurias ruoso: will you be at yapc::europe?
18:34 ruoso probably not...
18:34 moritz_ ruoso: can you show us the slides when you're done?
18:34 ruoso I was trying to upload it before it's finished :)
18:35 tobeya joined #perl6
18:38 ruoso moritz_, pmurias, http://people.debian.org/~ruoso/SMOP.pdf
18:38 ruoso any input is welcome...
18:38 ruoso I still have more than a week to make any change...
18:38 ruoso and it's still not complet
18:39 ruoso so... please... comment on it... ;)
18:40 moritz_ I like the NOTHINGmuch ;-)
18:40 ruoso hehe
18:42 moritz_ page 47, shouldn't it be s:1st/high/low/ ?
18:43 ruoso moritz_, yeah... actually... I should rephrase that
18:43 * Auzon reads
18:44 ruoso "Because we want low-level optimized implementations to behave transparently as if they were high-level objects."
18:44 ruoso better this way...
18:44 Auzon I like the object art
18:44 ruoso heh
18:45 moritz_ ruoso: I assume you'll add something about MMD methods and implementation?
18:46 ruoso well... I'm afraid of getting too long...
18:46 ruoso and I still didn't get into SMOP itself
18:46 ruoso I'm only explaining why SMOP is how it is
18:47 [particle] slide 54 should read "Something is what it says it is"
18:48 ruoso [particle], thanks... I was really unsure on how to write that...
18:48 [particle] it a good presentation. wish i could be there.
18:51 ruoso the last part will be explaining the basics on the SMOP internals... trying to get some developers ;)
18:51 ruoso [particle], thanks
18:53 diakopter cpan searching is down?
18:57 rakudo_svn r27889 | particle++ | [rakudo] update comment in makefile template
19:03 elmex joined #perl6
19:07 ruoso moritz_, pmurias, [particle], Auzon, I had just uploaded the first finished version... care to take a look?
19:07 Auzon sure.
19:08 Auzon same URL?
19:08 ruoso yes
19:10 Auzon I like the "er... without XS" parts :)
19:10 ruoso :)
19:10 moritz_ and mOOOOse part ;)
19:11 moritz_ ruoso: if your audience mostly knows perl, they'll like your small jokes very much ;)
19:11 ruoso even better... nothingmuch will be there ;)
19:11 moritz_ hehe
19:12 moritz_ btw use use .^can and .^does, but you don't explain what's the difference
19:12 moritz_ at least not on the slides
19:12 * [particle] notices void * in SMOP__* structures
19:12 ruoso I'm having an internal conflict on presenting all p6 features and doing the presentation in 40 minutes ;)
19:13 [particle] i'd rather they have a type name with some semantic meaning
19:13 moritz_ ruoso: I don't expect you to do it all, I just realized it on my second pass ;)
19:13 ruoso [particle], the thing is that each low-level implementation re-defines it as something else...
19:13 [particle] ...that's not a slide problem per se...
19:14 ruoso [particle], the data structure *really* has a void* there
19:14 pmurias ruoso: the ResponerInterface declaration in the right box has 'struct SMOP__Object'
19:14 ruoso pmurias++ thanks...
19:14 [particle] i understand, but VIRTUAL_ABSTRACT_T *data; or whatever may express that more clearly
19:15 pmurias why?
19:15 pmurias void* is a generic pointer
19:15 ruoso would VIRTUAL_ABSTRACT_T *data map simply as void*?
19:15 pmurias and the field is just that
19:16 ruoso or it would define more information?
19:16 [particle] yes #define VIRTUAL_ABSTRACT_T void
19:16 ruoso that seems reasonable
19:16 [particle] just to help us humans understand *why* it's void
19:16 [particle] because you're a sloppy coder?
19:16 [particle] no.
19:17 * ruoso going home now... I should be back later...
19:17 ruoso [particle], would you like to patch that in svn directly? please, do it :)
19:17 ruoso else I should get to it some time in the future :)
19:18 [particle] it may take some time to update pugs, but i can try to beat you :)
19:18 ruoso :)...
19:18 ruoso bbl
19:18 moritz_ #perl6-soc in 10 minutes
19:18 Auzon Yes.
19:19 moritz_ (that was just a general reminder, not particularly directed at Auzon ;)
19:19 Auzon I just wanted to let you know that I'm here and aware of it :)
19:19 moritz_ ok ;)
19:20 pmurias a comment what is stored in the data field would be better then giving void a funny name
19:20 schmalbe joined #perl6
19:20 moritz_ but we can pile buzzwords onto void ;)
19:22 ron_ joined #perl6
19:22 pmurias we can name void Top
19:23 ron_ rakudo: sub muddle () { ladle 'n'; } muddle;
19:23 exp_evalbot rakudo r27890 OUTPUT[Statement not terminated properly at line 1, near "muddle;"␤current instr.: 'parrot;PGE::Util;die' pc 120 (runtime/parrot/library/PGE/Util.pir:82)␤
19:23 pmichaud need a semi there.
19:23 ron_ rakudo: sub muddle () { ladle 'n'; } ; muddle;
19:23 exp_evalbot rakudo r27890 OUTPUT[Could not invoke non-existent sub ladle␤current instr.: 'muddle' pc 61 (EVAL_10:35)␤
19:24 ron_ like yesterday core dumps under ubuntu / cygwin - this time "corrupted double-linked list" under ubuntu
19:25 moritz_ ron_: I think the 'perl6' target is still rather unstable, '../../parrot perl6.pbc' works much more reliable
19:26 ron_ ok will work with that for a while - thx
19:27 sscaffidi joined #perl6
19:27 moritz_ I just made a small script #!/bin/sh\n../../parrot perl6.pbc "$@"
19:27 moritz_ that's much more convenient on the command line
19:28 r0bby joined #perl6
19:56 braceta joined #perl6
19:59 rakudo_svn r27891 | pmichaud++ | [rakudo]:
19:59 rakudo_svn r27891 | pmichaud++ | * Clean up .unshift, .keys, .values
20:09 pmurias TimToady: there is a useless if modifier in Cursor5.pm:677, should i remove it?
20:12 TimToady in what sense is it useless?
20:13 pmurias there is a check for that flag with unless before
20:14 Auzon rakudo: sub fac (Int $n) {my $t = 1; $t *= $n-- while $n}; fac(6);
20:14 exp_evalbot rakudo r27891 RESULT[too few arguments passed (0) - 1 params expected␤current instr.: 'fac' pc 94 (EVAL_12:45)␤
20:14 pmurias so the code would have returned if it wasn't tru
20:14 Auzon rakudo: sub fac (Int $n) {my $t = 1; $t *= $n-- while $n}; my $n = 6; fac($n);
20:14 exp_evalbot rakudo r27891 RESULT[too few arguments passed (0) - 1 params expected␤current instr.: 'fac' pc 109 (EVAL_12:52)␤
20:14 Auzon pugs: sub fac (Int $n) {my $t = 1; $t *= $n-- while $n}; my $n = 6; fac($n);
20:14 exp_evalbot OUTPUT[*** Can't modify constant item: VRef <Scalar:0xb660de10>␤    at /tmp/62ie3StACB line 1, column 30-41␤]
20:14 Auzon pugs: sub fac (Int $n is rw) {my $t = 1; $t *= $n-- while $n}; my $n = 6; fac($n);
20:15 exp_evalbot RESULT[undef]
20:15 TimToady pmurias: yes, you may remove it
20:15 pmurias thanks
20:15 Auzon pugs: sub fac (Int $n is rw) {my $t = 1; $t *= $n-- while $n; $t}; my $n = 6; fac($n);
20:15 exp_evalbot RESULT[\720]
20:16 Auzon pugs: multi sub postfix:<!> (Int $n is rw) {my $t = 1; $t *= $n-- while $n; $t}; say 5!;
20:16 exp_evalbot OUTPUT[*** Can't modify constant item: VInt 5␤    at /tmp/BElVwhLUoL line 1, column 50-61␤]
20:16 pmurias should I replace the powers of 2 constants with 'use constant DEBUG_something' ?
20:16 Auzon pugs: say [*] 1 .. 5;
20:16 exp_evalbot OUTPUT[120␤]
20:17 Auzon pugs: multi sub postfix:<!> (Int $n) {[*] 1 .. $n}; say 5!;
20:17 exp_evalbot OUTPUT[120␤]
20:19 Auzon perl6: multi sub postfix:<!> (Int $n) {[*] 1 .. $n}; say 5!;
20:19 exp_evalbot kp6 r20568: OUTPUT[error in Block at compiled/perl5-kp6-mp6/lib/KindaPerl6/Grammar/Sub.pm line 1457, <> line 1.␤*** Syntax Error in sub 'Main postfix:<!>' near pos=32␤]
20:19 exp_evalbot ..pugs: OUTPUT[120␤]
20:19 exp_evalbot ..rakudo r27891: OUTPUT[Statement not terminated properly at line 1, near ":<!> (Int "␤current instr.: 'parrot;PGE::Util;die' pc 120 (runtime/parrot/library/PGE/Util.pir:82)␤
20:19 exp_evalbot ..elf r20568: OUTPUT[Parse error in: /tmp/hvhTYy1uK6␤panic at line 1 column 32 (pos 32): Missing right brace␤WHERE: lti sub postfix:<!> (Int $n) {[*] 1 .. $n}; say 5!;␤WHERE:                              /\<-- HERE␤  STD_red/prelude.rb:98:in `panic'␤  STD_red/std.rb:255:in `_block_rest'␤
20:19 exp_evalbot ..STD_red/std.rb:242:in `block in block'␤  STD_red/prelude.rb:51:in `call...
20:20 pmurias TimToady: is the policy on Cursor5.pm, ask before changing or change and be reverted?
20:21 ruoso joined #perl6
20:22 TimToady depends on whether your feelings will be hurt by having your changes reverted :)
20:22 TimToady seriously, I don't mind either way
20:22 pmurias i should have prefixed the constants question with a TimToady:
20:23 TimToady my copy tends to get a little out-of-date with the checked in version at times though
20:23 alester joined #perl6
20:23 * ruoso back
20:24 TimToady pmurias: how long ago?
20:24 pmurias 22:16 ;)
20:25 pmurias ruoso: it might make sense to add a comment the data field explaining what it contains
20:25 pugs_svnbot r20569 | moritz++ | [t] added (mis-spelled) file depcreated-syntax.pod (can't rename it without
20:25 pugs_svnbot r20569 | moritz++ |     commiting first, svn--)
20:25 TJCRI left #perl6
20:26 ruoso pmurias, data field?
20:26 pugs_svnbot r20570 | moritz++ | [t] fixed previous commit (renamed file ;)
20:28 pmurias ruoso: in the SMOP__Object and SMOP__Responder
20:29 avar joined #perl6
20:29 ruoso pmurias, you mean in the presentation?
20:29 pmurias yes
20:30 ruoso but at that level, no one knows what it contains...
20:30 pmurias TimToady: "should I replace the powers of 2 constants with 'use constant DEBUG_something'=>power_of_2 ?"
20:31 pmurias ruoso: you told be it contains data the responder uses for GC
20:31 ruoso in the *default* lowlevel implementation...
20:31 bacek__ joined #perl6
20:31 ruoso but it's already in a higher-level then smop_base.h
20:32 ruoso that's the part that can be replaced
20:32 pmurias it might be worth noting it's not the object storage but private place for the RI
20:32 ruoso but it might be the object storage
20:32 ruoso it's not the case in the default implementation
20:32 ruoso but it doesn't need to be that way for everything....
20:33 ruoso the constant identifiers use the void* data as object storage
20:34 pmurias you could mention the objects can actually have additional fields in smop
20:35 ruoso yes.. that's an important point... I usually assume people get the inherited struct thing... but it's important to make an explicit comment...
20:37 pmurias it's obvious for C++ codes
20:37 pugs_svnbot r20571 | pmurias++ | removed useless if modifier
20:37 pmurias * coders
20:37 TimToady pmurias: sorry, phone...
20:40 ruoso TimToady, if you have some time... could you please take a look at the presentation I'm preparing: "Perl 6 is just a SMOP"... http://people.debian.org/~ruoso/SMOP.pdf
20:49 Auzon On S13 (Overloading), the Type Casting section mentions treating an object of a class as a routine, array, or hash. What do |$capture and @@slice contain?
20:54 TimToady |$capture is the underlying way that an ordinary argument list is passed as an object without rebinding its components to a signature
20:56 TimToady *@@slice is the way ordinary subscripts bind a multidimensional list of lists so as not to flatten the top-level Captures like ordinary list context does
20:57 pmurias TimToady: what should / translate to in a constant name?
20:58 TimToady pmurias: given that Cursor5 will eventually be rewritten into Perl 6, I'm not too terribly worried about making it pretty yet.
20:58 TimToady (in fact, the original Cursor.pm was in Perl 6, back when I was trying to get metholate to work under pugs.)
20:59 pmurias i'm planning to use Cursor5 in elf
20:59 TimToady in what way?
20:59 pmurias as a basis for a regex engine
21:00 TimToady well, that's certainly one of the ways that STD5 uses it... :)
21:03 TimToady it would be possible to use the matching part of it without the LTM, though probably pretty slow
21:04 TimToady and the linkage to the LTM is pretty complicated, given the LTM has to know how to calculate sets of longest tokens for particular sublanguages in a JIT fashion
21:05 ispy_ joined #perl6
21:06 TimToady but I figure that LTM being difficult is the price to pay for making Perl 6 very useful...
21:06 TimToady well, one of the prices....
21:07 TimToady pmurias: you mean like in the name mangling that it does for symbols?
21:07 TimToady I think / turns into Slash there
21:07 pmurias i wasn't sure how to name DEBUG_trace_call/return
21:08 TimToady no really good solution for that
21:09 TimToady just drop the /return is maybe the best
21:09 TimToady since a call implies a return anyway
21:09 pmurias k
21:10 pmurias and try_processing_in_STD5.pm?
21:12 rakudo_svn r27892 | pmichaud++ | [rakudo]:
21:12 rakudo_svn r27892 | pmichaud++ | * More cleanups to .unshift, .shift, .pop, .push
21:14 bacek_ joined #perl6
21:14 TimToady pmurias: not sure what you're asking...
21:18 pmurias TimToady: the other flag name had a dot, replaced it with _dot_
21:18 pugs_svnbot r20572 | pmurias++ | [Cursor5] added use constant for the DEBUG flag bits (haven't replaced the numbers yet)
21:20 pmurias will finish it tomorrow as i'm to tired to do it correctly
21:23 * TimToady wanders off for a while... &
21:25 meppl joined #perl6
21:34 Alias_ joined #perl6
21:34 rakudo_svn r27894 | particle++ | [rakudo] allow specification of local test list
21:34 rakudo_svn r27894 | particle++ | ~ 'make localtest' looks for a file named t/localtest.data
21:34 rakudo_svn r27894 | particle++ | ~ localtest.data contains a list of test files and directories
21:34 rakudo_svn r27894 | particle++ |
21:34 rakudo_svn r27894 | particle++ | this allows rakudo developers to specify a list of tests they wish to run locally during development of new features, etc.
21:34 rakudo_svn r27894 | particle++ | 'make localtest' currently assumes the tests should be fudged. this assumption should be removed.
21:34 bacek__ joined #perl6
21:37 japhb joined #perl6
21:37 pugs_svnbot r20573 | Auzon++ | [gsoc_spectest] Simplistic S13 (overloading) typecasting tests (long form).
21:39 aindilis joined #perl6
21:39 Auzon If someone would be kind enough to look over this test and the spec area, I'd be happy to add the short form versions of these. (http://perlcabal.org/syn/S13.html#Type_Casting is the URL; smartlink will come soon)
21:39 lambdabot Title: S13
21:39 Psyche^ joined #perl6
21:41 moritz_ looks fine
21:42 rakudo_svn r27895 | pmichaud++ | [rakudo]:
21:42 rakudo_svn r27895 | pmichaud++ | * Remove .ACCEPTS:  S03 doesn't show a .ACCEPTS for List, and the one
21:42 rakudo_svn r27895 | pmichaud++ |   we have here is likely bogus anyway.
21:42 rakudo_svn r27895 | pmichaud++ | * Rewrite .join:  Parrot has a 'join' opcode, use it instead of
21:42 rakudo_svn r27895 | pmichaud++ |   looping over repeated concatenations.
21:42 rakudo_svn r27895 | pmichaud++ | * Rewrite .reverse using iterators.  Eventually we'll even make this
21:42 rakudo_svn r27895 | pmichaud++ |   lazy.
21:42 Auzon Ok, then I'll copy the file and change the syntax to the short form mentioned. Thanks moritz_++
21:45 Auzon rakudo: module TypeCastSub {method postcircumfix:<( )> (|$capture) {return 'pretending to be a sub'}}; my $thing = TypeCastSub.new(); say $thing();
21:45 exp_evalbot rakudo r27895 OUTPUT[Statement not terminated properly at line 1, near ":<( )> (|$"␤current instr.: 'parrot;PGE::Util;die' pc 120 (runtime/parrot/library/PGE/Util.pir:82)␤
21:45 Auzon 1) Should I fudge that? 2) Should that be a class instead?
21:46 moritz_ a class, yes
21:46 moritz_ method outside of classes are illegal
21:47 * moritz_ should have noticed that
21:47 Auzon rakudo: class TypeCastSub {method postcircumfix:<( )> (|$capture) {return 'pretending to be a sub'}}; my $thing = TypeCastSub.new(); say $thing(); # let's see if this is better
21:47 exp_evalbot rakudo r27895 OUTPUT[Statement not terminated properly at line 1, near ":<( )> (|$"␤current instr.: 'parrot;PGE::Util;die' pc 120 (runtime/parrot/library/PGE/Util.pir:82)␤
21:47 moritz_ Auzon: you can't really fudge that and still have something left for rakudo
21:47 moritz_ Auzon: so just leave it as is
21:48 Auzon Alright.
21:55 pugs_svnbot r20574 | Auzon++ | [gsoc_spectest] s/module/class/ in typecasting-long.t. Added typecasting-short.t to test the same things but with the shorter syntax form.
21:55 bacek__ joined #perl6
21:58 Auzon This is just a copy, using the shorter syntax form. Still testworthy though, and it could probably be expanded to actually do something with the arguments/indexes provided.
21:58 moritz_ aye, but it's fine for a first version
21:58 moritz_ Auzon++
21:59 moritz_ @karma Auzon
21:59 lambdabot Auzon has a karma of 6
21:59 moritz_ lambdabot: you're cheating, aren't you?
21:59 moritz_ perlbot: karma Auzon
21:59 perlbot Karma for Auzon: 31
21:59 moritz_ that's more likely
22:00 moritz_ seems like lambdabot as stopped recording new karma
22:00 [particle] lambdabot--
22:01 moritz_ Auzon: you could test for a modules that overloads all of the three postcircumfix methods
22:01 moritz_ s/modules/class
22:02 Auzon Hm, yeah, and using the different syntax forms just to make it more interesting.
22:02 moritz_ anyway, bed &
22:02 Auzon good night, moritz_.
22:03 elmex joined #perl6
22:11 pmichaud I have a question on t/spec/S29-arrays/delete.t:   http://nopaste.snit.ch/13095
22:11 pmichaud for the last two tests, should deleting the element at index 3 shorten the array to have just 2 elements?
22:12 pmichaud or do we shorten the array _only_ if an element being deleted is the very last one?
22:13 pmichaud (or, I should say, only to the position of the last explicitly deleted element, even if earlier items were deleted)
22:14 bacek_ joined #perl6
22:14 * Auzon looks -- not in the middle of anything
22:16 pmichaud in particular, what is the result of
22:16 pmichaud my @array;  @array[9] = 'foo'; @array.delete(9); say +@array;
22:16 Auzon I believe that it's only shortened if the deleted elements at the end (assuming no shape()).
22:16 pmichaud pugs: my @array;  @array[9] = 'foo'; @array.delete(9); say +@array;
22:16 exp_evalbot OUTPUT[9␤]
22:17 pmichaud fwiw, Perl 5 disagrees.  :-)
22:18 pmichaud $ cat x
22:18 pmichaud my @array; $array[9] = 'foo'; delete $array[9]; print 0+@array, "\n";
22:18 pmichaud $ perl x
22:18 pmichaud 0
22:18 Auzon You can delete on arrays?
22:18 Auzon in Perl 5, that is.
22:18 pmichaud sure, that's the standard mechanism for removing elements from an array.
22:19 pmichaud perldoc -f delete:
22:19 pmichaud delete EXPR
22:19 pmichaud Given an expression that specifies a hash element, array ele‐
22:19 pmichaud ment, hash slice, or array slice, deletes the specified ele‐
22:19 pmichaud ment(s) from the hash or array.  In the case of an array, if
22:19 pmichaud the array elements happen to be at the end, the size of the
22:19 pmichaud array will shrink to the highest element that tests true for
22:19 pmichaud exists() (or 0 if no such element exists).
22:22 meppl good night
22:28 * Auzon is befuddled
22:28 pmichaud (I think the spectest is wrong.)
22:29 Auzon Is that recent in p5?
22:29 pmichaud I don't think so.  delete from an array has been around since p4, I think.
22:30 * pmichaud grabs his pink camel.
22:30 Auzon I guess no one uses it because of pop(), splice(), and undef $array[$i]
22:30 pmichaud okay, it's not in the pink camel.
22:30 pmichaud well, undef does something different.
22:32 pmichaud delete from an array was in Perl 5.6
22:32 pmichaud (according to my 3rd edition camel)
22:39 cjfields joined #perl6
22:50 rakudo_svn r27896 | pmichaud++ | [rakudo]:  More List revisions
22:50 rakudo_svn r27896 | pmichaud++ | * Rework .kv, .exists, and .delete .
22:50 rakudo_svn r27896 | pmichaud++ | * The changes to .delete cause t/spec/S29-array/delete.t to fail,
22:50 rakudo_svn r27896 | pmichaud++ |   but I think the spectest is wrong and this implementation is correct.
22:52 wknight8111 wow, rakudo_svn gives away that karma like candy
22:55 pmichaud no kidding!
22:55 pmichaud I think I'll make longer commit messages from now on :-)
22:55 Auzon I think any multiline commit does this
22:57 Auzon Testing S29 will be fun next week. :)
23:11 cognominal_ joined #perl6
23:16 justatheory joined #perl6
23:21 pmichaud pugs:  my @a = [1,2,3];   say @a.perl;
23:21 exp_evalbot OUTPUT[[[1, 2, 3],]␤]
23:21 pmichaud my @a = 1,2,3;  say @a.perl;
23:21 pmichaud pugs: my @a = 1,2,3;  say @a.perl;
23:21 exp_evalbot OUTPUT[[1, 2, 3]␤]
23:22 pmichaud pugs:  my @a = 1..3; say @a.perl;
23:22 exp_evalbot OUTPUT[[1, 2, 3]␤]
23:22 pmichaud pugs:  my @a = 1..3; my @b = @a; say @b.perl;
23:22 exp_evalbot OUTPUT[[1, 2, 3]␤]
23:23 pmichaud my @a = 1..3;  my @b = @a, @a;  say @b.perl;
23:23 pmichaud pugs: my @a = 1..3;  my @b = @a, @a;  say @b.perl;
23:23 exp_evalbot OUTPUT[[1, 2, 3, 1, 2, 3]␤]
23:23 pmichaud my @a = 1..3; say @a.WHAT;
23:23 pmichaud pugs: my @a = 1..3; say @a.WHAT;
23:23 exp_evalbot OUTPUT[Array␤]
23:24 pmichaud say [1,2,3].WHAT;
23:24 pmichaud pugs: say [1,2,3].WHAT;
23:24 exp_evalbot OUTPUT[Array␤]
23:24 pmichaud (sorry for the non-pugs: spam)
23:25 spinclad ruoso++ NOTHINGmuch++
23:26 pmichaud okay, I'm a bit confused.  What is it that allows @b to flatten but prevents [1,2,3] from flattening?
23:27 pmichaud (I understand that this is the way it's supposed to work -- I'm wondering what the compiler looks for to distinguish the two.)
23:29 cjfields joined #perl6
23:30 pmichaud is it that [1,2,3] is actually a scalar?
23:35 pmichaud okay, that makes sense to me.
23:35 pmichaud thanks, empty channel.  :-)
23:40 aindilis joined #perl6
23:41 Tene pmichaud: the []
23:41 Tene @b is the same as 1, 2, 3 without []
23:41 lambdabot Maybe you meant: b52s babel bf botsnack brain bug . ? @ v
23:42 pmichaud yes, but both @b and [] are "Array"
23:42 Tene Hm.
23:43 pmichaud but (I think) the answer is that [] is a Scalar containing an Array, while @b is an Array.
23:43 Tene Yeah, that sounds right.
23:43 pmichaud so, @b flattens, but [] doesn't (because a Scalar in list context becomes a list containing the scalar)
23:50 spinclad ruoso: re void*:  parameterize it:  struct SMOP__Object<T> { struct SMOP_ResponderInterface *ri; T data; }  :)
23:51 [particle] if only!
23:56 bacek__ joined #perl6
23:58 bacek joined #perl6

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

Perl 6 | Reference Documentation | Rakudo