Perl 6 - the future is here, just unevenly distributed

IRC log for #marpa, 2014-12-23

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

All times shown according to UTC.

Time Nick Message
00:42 ronsavage joined #marpa
00:45 ronsavage Sorry - I was raving. It's the Marpa Google Group, not G+. $many x $apologies;
00:47 jeffreykegler joined #marpa
01:01 ronsavage And thanx for the feedback.
02:04 ronsavage rns: I've been re-reading https://groups.google.com/forum/#!topic/marpa-parser/2TZn5nolyzk. Did you ever do any work on a Marpa-based parser for regexps?
02:27 flaviu If anyone doesn't read the mailing list, I'll be using http://flaviut.github.io/marpa-site-temp/ as the temporary location for the web site I'm working on.
03:52 ronsavage joined #marpa
05:35 jeffreykegler joined #marpa
06:21 rns joined #marpa
06:26 rns ronsavage: re http://irclog.perlgeek.de/marpa/2014-12-23#i_9842844 — yes, some; I was trying to do it as an application for a general CFG-to-CFG translator (given 2 BNFs and a translation table) but was overhelmed with the task and stuck at proof of concept stage — https://github.com/rns/MarpaX-Regex/blob/master/t/translation.t.
06:26 rns Learned quite a lot about doing Marpa SLIF semantics via ASTs walking, though. :)
06:31 rns flaviu: re http://irclog.perlgeek.de/marpa/2014-12-23#i_9842883 — great, I filed some PRs.
06:41 rns ronsavage: Marpa-based parser for regexp — Jean-Damien (as always!) has one for javascript regexps as part of his ECMAScript parser http://blogs.perl.org/users/jean-damien_durand/2014/02/a-marpa-use-case-javascript-regexp-implementation.html
06:52 ronsavage rns: Thanx. If you feel overwhelmed I can safely give up before I start!
06:57 rns joined #marpa
07:00 rns ronsavage: :) not necessarily; I delved into overgeneralization and pattern (not CFG) based translation would work better.
07:00 rns ... or so I think.
07:09 ronsavage rns: Hmmmmm. OK. But I don't pretend my skills are as developed as yours.
07:20 rns Thanx for kind words. Funny thing, I felt the same way about you looking to what you do with Graphviz.
11:21 lwa joined #marpa
12:25 lwa joined #marpa
12:26 hobbified joined #marpa
12:26 flaviu joined #marpa
12:27 lucs joined #marpa
12:28 btyler_ joined #marpa
13:59 flaviu rns: Thanks!
16:09 jeffreykegler joined #marpa
17:51 koo6 joined #marpa
17:51 koo5 joined #marpa
20:53 jeffreykegler joined #marpa
21:18 flaviu I'm reading https://github.com/jeffreykegler/kollos/blob/master/about.md, but I'm not sure I understand what it is. Does it mean that C can be used to easily create a parser, not just perl?
21:18 flaviu Or is it's intent to replace Perl with lua?
21:23 ronsavage flaviu: As I understand it, Lua will be embedded in the C code. This means our grammars (SLIFs) will be parsed by Lua inside C, rather than via slow calls to Perl. Of course, I could be raving again :-)
21:23 ronsavage "via" meaning "with the help of".
21:24 flaviu ok, that makes sense.
21:24 flaviu Sounds exciting!
21:26 flaviu This source file is interesting: https://github.com/jeffreykegler/kollos/blob/master/components/json/json.c
21:26 flaviu It'd be useful as an example of how to use libmarpa.
21:28 jeffreykegler Kollos (=Marpa+Lua) is the response to the next to have a Turing-complete equivalent of the SLIF ...
21:29 jeffreykegler so that you can specify actions, what to do on events, etc., etc.
21:29 jeffreykegler Marpa::R2 actually has a small VM inside it to implement semantics, but it's not Turing-complete and it's not very good -- it's something that grew up gradually.
21:30 jeffreykegler So Lua becomes Marpa's internal extension language.  It's good at this because it's extremely lightweight -- it is actually smaller than Marpa.
21:31 jeffreykegler Perl is out of the question as an extension language because it is just too big and cumbersome, and comes with too much overhead.
21:32 flaviu I was under the impression that Kollos was a high level Marpa API. It looks like I misunderstood.
21:33 jeffreykegler Yes, Kollos will replace the SLIF with something called the LUIF -- so it will be at the same level as the SLIF ...
21:33 jeffreykegler Don't know if that's what you mean by high-level.
21:33 flaviu By high level I mean that it is possible to give it a BNF grammer, and it outputs the parse result.
21:34 jeffreykegler Kollos's LUIF interface will be high-level, then, in that sense.
21:34 jeffreykegler It will be an improved SLIF.
21:35 flaviu Ok. In https://github.com/jeffreykegler/kollos/blob/master/about.md you mention that it will replace the "Perl/XS wrapper", but I get the impression that that is a thin wrapper.
21:36 jeffreykegler The Perl/XS wrapper, alas, is far from thin.
21:36 jeffreykegler It contains most of the SLIF logic, coded in C, inside Perl/XS.  It's not a pretty thing.
21:38 jeffreykegler Perl/XS is designed with thin wrappers in mind -- it is very good at supporting stuff like the SLIF, too, but it'still best to try not to do too much in Perl's XS layer.
21:39 flaviu Ok, I understand.
21:39 jeffreykegler But there is no real intent to replace Perl with Lua.  You *will* be able to use Kollos on its own, without Perl, but Lua does not try to be a full featured language.
21:40 jeffreykegler flaviu: Thanks for the Github PR.
21:40 jeffreykegler I'll look at it in a bit.
21:41 flaviu Not a problem -- it's your own words :)
21:41 flaviu But the advantage of Kollos seems that it will be easy to create wrappers from other languages to it.
21:42 jeffreykegler flaviu: Exactly!
21:42 flaviu So the user will be able to use their favorite language with Marpa, without re-implementing the logic of interacting with libmarpa.
21:42 jeffreykegler Exactly!
21:43 jeffreykegler And Lua's advantage is that it's the kind of tiny little language you can sneak into other languages, without expected that to be a problem.
21:43 jeffreykegler In fact, AFAICT Lua is unique in addressing that problem space.
21:44 Aria Yeah, lua, a few forths, a scheme or two, and that's about it.
21:44 Aria Oh, and a couple weird slow js interpreters
21:44 jeffreykegler Of course, users will also be able to use Libmarpa, the C library directly, without Kollos.  That's what's done in the json.c file you noticed above.
21:44 flaviu Aria: Guile is the one that comes to mind.
21:45 jeffreykegler Guile and scheme are *not* small.
21:45 Aria I was thinking of rep
21:46 jeffreykegler And, as for Forth, I and Linus were fans long ago with it first came out, and Linus's comments are right on the mark ...
21:46 jeffreykegler In an interview, he talked about how fascinating Forth was, and how he loved to work out it's possibilities, but concludes by saying ...
21:46 jeffreykegler "But bascially it was useless."
21:47 Aria Heh. Yeah.
21:47 jeffreykegler I liked Forth, and I hate to say this directly, but Linus is more direct, and I have to admit the remark hits home.
21:48 jeffreykegler I did consider Guile seriously as an alternative to Lua, ...
21:48 jeffreykegler but it is just really, really big.
21:48 flaviu I've seen the NAIF, does it also work on top of the Perl/XS wrapper?
21:49 jeffreykegler Yes, the NAIF works on top of the Perl/XS wrapper ...
21:50 jeffreykegler and one of the reasons that I've got to move away from it, is that the Perl/XS wrapper has to support both.
21:50 jeffreykegler I don't think there are a lot of NAIF users out there, but I am committed to supporting their legacy code.
21:51 jeffreykegler There's also a THIF, which is a true "thin" Perl/XS wrapper.
21:51 jeffreykegler By the way, these days I am hacking away at Kollos, and I like Lua the closer I get to it.
21:52 jeffreykegler Lua is the Marpa-extension language I would have designed, if I was smart enough.
21:54 jeffreykegler More re Forth: some time ago, I did look at Lang5, a Forth derivative, as the the possible Marpa extension language ...
21:54 jeffreykegler my fascination with Forth's approach remains, but bottom line ...
21:55 jeffreykegler I think the Forth approach ought to work, I'd like it to work, I'm fascinated with it, but ...
21:55 jeffreykegler it does not really work.
21:55 Aria Yeah. Not for mere mortals.
21:55 Aria nevermind muggles
21:56 jeffreykegler Guile also has a "mere mortal" problem ... Stallman et al are convinced that mature programmers prefer a LISP-ish syntax but ...
21:56 jeffreykegler I'm 61 and by that definition, I'm not a mature programmer yet.
21:58 jeffreykegler RMS claims he finds LISP-ish syntax natural, and he has earned the right to be taken at his word, but I cannot imagine becoming comfortable with it ...
21:58 jeffreykegler and even if I did, I cannot imagine the Marpa community becoming comfortable with it.
21:59 flaviu No need to justify why you're not using Guile, the only reason I mentioned it is because it was the first thing in my head.
21:59 flaviu I can't say I like lisp syntax either.
22:01 jeffreykegler Some of the most brilliant programmers out there *do* like LISP-ish syntax -- Steve Yegge is also a fan, and he's very bright and far from a bigot.
22:30 jeffreykegler joined #marpa
23:22 koo5 joined #marpa
23:36 jeffreykegler ronsavage: re your cross-refenced modules list.  Marpa::HTML is deprecated.  Refer them to Marpa::R2::HTML (which is part of Marpa::R2).
23:36 ronsavage As an experiment I'm re-writing Text::Balanced as Text::Balanced::Marpa, using rns' tiny grammar for arbitrary nesting of double-quoted strings. See quoted.strings.02.pl in MarpaX::Demo::SampleScripts. I've extended the grammar to "...", {...}, <...>, (...) and [...]. I'll add single quotes later. Now I'm just turning a single test script into a module. Perhaps some users will want only "..." say, and thus will need an option to not treat t
23:37 jeffreykegler ronsavage: re Text::Balanced::Marpa.  Very, very cool.
23:38 jeffreykegler This has been a real "target of opportunity" for Marpa for a while.
23:40 ronsavage jeffreykegler: Fixed. Thanx.
23:44 ronsavage If anyone has ideas about how to store the result, start typing (here). I'm thinking an arrayref (for the N (potentially) output strings) of hashrefs (keys would be delims and text).
23:44 ronsavage I have no plans to make it a drop-in replacement for the original module.

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