Moderately low-hanging fruit: Statistics Language

2014-01-15 Thread Paul Bennett
See the pre-print and slides here: http://ashishagarwal.org/2011/10/04/pdf-type-theory/ Basically, the author describes a DSL for describing statistical distributions, and programming techniques for turning those descriptions into random number generators. This is something I've been looking for,

Re: Moderately low-hanging fruit: Statistics Language

2014-01-15 Thread Paul Bennett
On Wed, Jan 15, 2014 at 5:28 AM, Paul Bennett wrote: > See the pre-print and slides here: > > http://ashishagarwal.org/2011/10/04/pdf-type-theory/ > > Basically, the author describes a DSL for describing statistical > distributions, and programming techniques for turning those &

Re: A new blog post: Significant newlines? Or semicolons?

2014-02-25 Thread Paul Bennett
On Feb 25, 2014 8:08 PM, "Jeffrey Kegler" wrote: > > Do not do either one. > I concur. FWIW, I think my current version of Marpa.tmLanguage does rely on some whitespace to figure out the highlighting rules, because it's easier to do the regexes. I'll add it to The Big List Of Stuff To Fix. Oh, a

Re: A new blog post: Significant newlines? Or semicolons?

2014-02-25 Thread Paul Bennett
On Feb 25, 2014 8:25 PM, "Jeffrey Kegler" wrote: > > @Paul: While you're online, I've a question for you. You spoke of a Python port at one time. Did you have in mind Python 2 or 3? -- jeffrey > My preference would be both / either / let-the-user-choose. Since (when I pick the project back up)

Back on the SGML trail ...

2014-02-26 Thread Paul Bennett
I've had a sleepless night, so I've been tinkering with code. Among my efforts is the latest MarpaX::SGML at https://github.com/PWBENNETT/MarpaX-SGML Forewarning: I tend to do a lot of what Abelson and Sussman refer to as "programming by wishful thinking". Don't expect this code to run, and if it

Re: Back on the SGML trail ...

2014-03-09 Thread Paul Bennett
On Wed, Feb 26, 2014 at 12:05 PM, Jeffrey Kegler wrote: > Looking at it, I noticed there seems to be no test suite. Test suites are > worth the trouble. Test suites for SGML parsing are are _hard_. I've tried getting one going using "vanilla" Docbook, and I can't quite get my thoughts in place t

I may be teaching my colleagues Marpa

2014-05-08 Thread Paul Bennett
Yesterday, I was approached at work about the possibility of leading a seminar on Marpa . I feel thrills of excitement and of terror in equal proportion, but I'm going to start penciling together a few slides and see how it goes. I wonder whether any of the luminaries in the field (e.g. Ron, JD, a

Re: I may be teaching my colleagues Marpa

2014-06-18 Thread Paul Bennett
By the sound of it, I'll have plenty to draw on, or even just use, for my lessons (and it's turning into multiple lessons for sure) at work. This project really has some of the best community members of anything I've been involved in. You all rock like rockstars! For the record, my two more-or-le

Re: I may be teaching my colleagues Marpa

2014-06-18 Thread Paul Bennett
On Wed, Jun 18, 2014 at 12:01 PM, Jeffrey Kegler wrote: > Thanks for doing this. Reading even unfinished presentations is helpful to > me, because I come to Marpa from the viewpoint of 1970's parsing theory, and > so what most people need explaining and what does not is very hard for me to > figu

Re: I may be teaching my colleagues Marpa

2014-06-19 Thread Paul Bennett
On Wed, Jun 18, 2014 at 8:01 PM, Jeffrey Kegler wrote: > Grune & Jacobs suggest that "::=" be read as "may be replaced by". I'll > often read it as "produces". All, I've taken a number of your suggestions on board (as well as some other thoughts). The URL for the presentation-in-progress remain

Yet another ambitious project

2014-07-17 Thread Paul Bennett
Hi all, I've started working here https://gist.github.com/PWBENNETT/8435996 on a practical grammar for the language described here http://ashishagarwal.org/2011/10/04/pdf-type-theory/ Trouble is, I don't (yet) understand the math in the above paper well enough to know whether I'm actually on the

Re: Yet another ambitious project

2014-07-20 Thread Paul Bennett
On Sun, Jul 20, 2014 at 10:06 AM, Ruslan Shvedov wrote: > Hi Paul, here are my 2cents on this, in no particular order > > C style #include's — aren't they supposed to be processed before parsing the > program? The grammar has actions for include's, but I honestly can't see how > you are going to i

Re: Yet another ambitious project

2014-07-20 Thread Paul Bennett
>> In the paper's if X then Y else Z, X seems to be a (bound) variable (not >> sure if/how they convert it to boolean, perhaps by whether it has PDF or >> not), while it is a comparison in the grammar. > > The name "comparison" is just a notational thing for my convenience. > Oh, but yes. Yes, inde

Re: Yet another ambitious project

2014-07-21 Thread Paul Bennett
On Jul 21, 2014 1:04 AM, "Ruslan Shvedov" wrote: > > A couple of nits on the updated grammar: > > 1 > >> Expression ::= Value > > > and, later, > >> Value: >>> >>> ... >>> >>> | Expression action => eval >>> >>> ... > > > This alternative looks redundant. Well, I'm not entirely sure at this point

Re: Python port of Libmarpa?

2014-11-09 Thread Paul Bennett
Well, how about that? I was just going to SWIG the low-level C code, and build a method-compatible API suite on top. I'll have to check out this guy's work for sure. On Sun, Nov 9, 2014 at 9:55 PM, Jeffrey Kegler wrote: > [ Warning: family unfriendly repo name ] > > If you've been following the I

Re: OPML: Another XML-based markup language

2014-11-12 Thread Paul Bennett
On Tue, Nov 11, 2014 at 5:09 PM, Ron Savage wrote: > https://en.wikipedia.org/wiki/OPML Interesting, and I suspect JD will have things to say. For me, it's just a sad reminder that my SGML implementation hasn't been worked on in far too long. I really need to get into a room with JD, a couple o

Re: Emacs marpa-mode

2015-11-21 Thread Paul Bennett
On Fri, Nov 20, 2015 at 4:33 PM, Jeffrey Kegler wrote: > Kind of nice the way that the colors distinguish G1 and L0 rules. I haven't played with my TextMate / SublimeText highligher for Marpa in a long time. I agree it's a nice touch. I'm looking at implementing the exact same thing right now. P

Re: Emacs marpa-mode

2015-11-21 Thread Paul Bennett
On Sat, Nov 21, 2015 at 2:09 PM, Paul Bennett wrote: > I'm looking at implementing the exact same thing right now. https://gist.github.com/PWBENNETT/0e860d907fc59554f1ce -- Paul -- You received this message because you are subscribed to the Google Groups "marpa parser" gro

Re: Emacs marpa-mode

2015-11-21 Thread Paul Bennett
On Sat, Nov 21, 2015 at 3:17 PM, Paul Bennett wrote: > https://gist.github.com/PWBENNETT/0e860d907fc59554f1ce Ooh, I don't support comments with that. Working on it. -- Paul -- You received this message because you are subscribed to the Google Groups "marpa parser" gro

Re: Emacs marpa-mode

2015-11-21 Thread Paul Bennett
On Sat, Nov 21, 2015 at 3:35 PM, Paul Bennett wrote: > > Ooh, I don't support comments with that. Working on it. > Here, and in its semi-proper location instead of as a gist ... https://github.com/PWBENNETT/MarpaX-SGML/blob/master/Marpa.tmLanguage -- Paul -- You receive

Re: Emacs marpa-mode

2015-11-21 Thread Paul Bennett
On Sat, Nov 21, 2015 at 3:42 PM, Paul Bennett wrote: > https://github.com/PWBENNETT/MarpaX-SGML/blob/master/Marpa.tmLanguage And here it is in action: https://drive.google.com/file/d/0B21ee_I1WzbwNFlVdXE5T2dMQnM/view?usp=sharing Apologies for the many emails. I'm growing too accus

SLIF style guide / best practices?

2015-11-21 Thread Paul Bennett
Is there such a document? My specific scenario... I have a grammar broken up into chunks (corresponding more or less with similarity of meaning in the official SGML spec) at https://github.com/PWBENNETT/MarpaX-SGML/tree/master/lib/MarpaX/SGML/Grammar My specific question... Within each file, is

Re: SLIF style guide / best practices?

2015-11-22 Thread Paul Bennett
On Nov 22, 2015 4:10 PM, "Ron Savage" wrote: > > I always try to write the ::= rules top-down, and then list the ~ rules alphabetically. This has turned out very well, for me at least. > Sounds sensible. In my (admittedly gargantuan) grammar linked above, do any of you have specific examples of w

ANNOUNCE: Gloria has begun

2016-02-05 Thread Paul Bennett
Work has finally begun in earnest on my log analyzer that I promised to work on "one day" back when I started to get into Marpa . There's not much to see yet, aside from one work-in-progress "input config" file. Input config spec coming soon -- as soon as I've nailed down what input specs need to

Re: Java 8 Parser

2016-10-15 Thread Paul Bennett
On Oct 15, 2016 13:01, "Jeffrey Kegler" wrote: > > Re #4, why not implement Perl regexes? A full syntax of Perl regexes is gruesomely complex, and much of it is symptoms rather than features. Somewhere deep within perldoc there's a howto on making your own \p{} named properties, which AFAICT are

To mark the occasion, a short composition

2016-10-24 Thread Paul Bennett
:discard ~ whitespace ~ [\p{Separator}]+ S ::= H B J H ::= 'Very' H | 'Happy' B ::= 'Birthday,' J ::= 'Illustrious Idiosyncrat' | 'Jeffrey' -- P/PW/PWBENNETT -- You received this message because you are subscribed to the Google Groups "marpa parser" group. To unsubscribe from this grou

Switching between grammars in one parse

2017-02-21 Thread Paul Bennett
I'm writing a tinylang. One of the things the lang needs is a token "XPath", which parses as per the w3c XPath spec, which is highly different to the rest of the language spec. I plan to approach it by writing two grammars. It seems the words for me to grep the pod for are "pause" and "expect" if I

Re: Switching between grammars in one parse

2017-02-21 Thread Paul Bennett
Any good examples of mixing grammars? In my "main" grammar I have :discard ~ whitespace (etc), but in the XPath spec whitespace seems to be significant. I'm obviously behind the times ... I guess I could use "..." around my XPath expressions and treat them as blind strings handled by the semantics

Wrapping other parser engines

2018-02-13 Thread Paul Bennett
e Greater Good, so to speak. Thanks for your guidance, -- Paul Bennett P/PW/PWBENNETT -- You received this message because you are subscribed to the Google Groups "marpa parser" group. To unsubscribe from this group and stop receiving emails from it, send an email to marpa-parser+unsu