Perl 6 - the future is here, just unevenly distributed

IRC log for #marpa, 2015-01-13

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

All times shown according to UTC.

Time Nick Message
03:55 ronsavage joined #marpa
06:09 sirdancealot joined #marpa
06:50 jeffreykegler Good night!
07:03 ronsavage Grammar help needed. Repo: https://github.com/ronsavage/X500-DN-Marpa. Problem: 'perl -Ilib scripts/tiny.pl' fails on the last string, q|foo=1 + bar=2, baz=3|. I can't get it to trigger the 2nd alternative to rule rdn at line 133 in Marpa.pm. Using rank => $n and ranking_method => 'high_rule_only' has no effect. TIA.
07:25 rns -sutf1                          ~ [\x01-\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns +sutf1                          ~ [\x01-\x19\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns -sutf1                          ~ [\x01-\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns +sutf1                          ~ [\x01-\x19\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns -sutf1                          ~ [\x01-\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns +sutf1                          ~ [\x01-\x19\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns -sutf1                          ~ [\x01-\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns +sutf1                          ~ [\x01-\x19\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns -sutf1                          ~ [\x01-\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns +sutf1                          ~ [\x01-\x19\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns -sutf1                          ~ [\x01-\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns +sutf1                          ~ [\x01-\x19\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns -sutf1                          ~ [\x01-\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns +sutf1                          ~ [\x01-\x19\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:25 rns ronsavage: Sorry, for the above mess, didn't see paste in my chat client.
07:26 rns Problem is, sutf1 charclass includes space \x20. If it's removed the test passes.
07:27 ronsavage rns: Thanx. I go sutf1 from https://www.ietf.org/rfc/rfc4514.txt.
07:31 rns Well, they say "The following characters are to be escaped ... SPACE ..." above the rule.
07:31 rns but gave no rule grammar for that, on a quick look.
07:35 ronsavage SPACE et c are on https://www.ietf.org/rfc/rfc4512.txt
07:38 rns Yes, but the below lines seems to be a bug in rfc4514 grammar:
07:38 rns stringchar = SUTF1 / UTFMB
07:39 rns SUTF1 = %x01-21 / ...
07:39 rns special = escaped / SPACE / SHARP / EQUALS
07:41 rns or at least need special lexing, that they tried to tell with their comment about escaping required.
07:42 ronsavage Well, specials are preceded by a mandatory escape char, so it's not that simple, but yes, I suspect a typo. At the same time, the chance of a typo should be very, very, low.
07:46 rns FWIW, tiny.pl passes for me with escaped space in foo=1\ + bar=2, baz=3 and sutf1    ~ [\x01-\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f]
07:47 ronsavage Also, that change makes 'John Doe' turn into 'JohnDoe' :-(
07:48 rns Or rather 'John Doe' turn into 'John\ Doe' ?
07:53 ronsavage No. I'm going by the print out of the 2 tests which use 'John Doe'. If you mean the ' ' should be escaped, that is the big question. And yes, your patch makes the last test pass, but disrupts others.
07:55 basiliscos joined #marpa
07:55 rns Hmm, with escaped space in foo=1\ + bar=2, baz=3, tiny.pl produces
07:55 rns Statistics: fail => 0, success => 15, total => 15.
07:56 rns with sutf1 as in 4521
08:23 basiliscos joined #marpa
08:30 ronsavage Understand. But |cn=John Doe, o=Acme, c=US| must not report cn = JohnDoe.
08:36 rns Parsing |cn=John Doe, o=Acme, c=US|.
08:36 rns Parse result: 0 (0 is success)
08:36 rns cn = John Doe.
08:36 rns o = Acme.
08:36 rns c = US.
08:36 rns |          1         2         3         4         5         6         7         8         9
08:36 rns |0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
08:36 rns Parsing |cn=John Doe, o=Acme\, Inc., c=US|.
08:36 rns Parse result: 0 (0 is success)
08:36 rns cn = John Doe.
08:36 rns Parse result: 0 (0 is success)
08:36 rns cn = John Doe.
08:36 rns o = Acme.
08:36 rns Sure and, tiny.pl with escaped space in 'foo...' produces cn = John Doe. But I'm probably missing something.
08:37 rns irc client didn't shown pasted text again, sorry for duplication.
08:40 ronsavage I changed this 1 line: sutf1 ~ [\x01-\x19\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f], and yet I get a different result. I'm confused!
08:40 ronsavage AFK.
08:42 rns With this line sutf1 ~ [\x01-\x19\x21\x23-\x2a\x2d-\x3a\x3d\x3f-\x5b\x5d-\x7f] -- yes, the result is different.
08:44 rns But if you leave sutf1 unchanged and just escape space like this: foo=1\ + bar=2, baz=3 all tests pass and John Doe comes with a space.
08:49 rns AFK.
08:49 rns left #marpa
09:23 jluis joined #marpa
09:29 ronsavage joined #marpa
09:29 ronsavage ok. That's clear. It's 8:30pm here now. Tomorrow I'll look closely at what can and can't change, in the grammar and the samples.
10:16 ronsavage Solved. The solution was to allow whitespace around = and +, and to stop Marpa discarding whitespace. Also, I implemented reserved names as in 4514 [Page 6].
13:12 sirdancealot joined #marpa
17:28 jeffreykegler joined #marpa
18:11 jeffreykegler https://plus.google.com/109324203153530830791/posts/4TVvVUaBRZv
18:11 jeffreykegler The FLOSS weekly announcement of Andrew's talk
18:14 basiliscos joined #marpa
18:20 jeffreykegler Apparently it's both live and recorded -- they do a less formal live version, then edit it for the recorded one.
18:21 jeffreykegler There's a link for attending the live version in the 2nd paragraph on this page: http://twit.tv/show/floss-weekly
18:22 jeffreykegler The direct link is http://live.twit.tv/
18:51 sirdancealot joined #marpa
21:34 lucs joined #marpa
21:34 sivoais joined #marpa
21:34 sirdancealot joined #marpa
21:35 sivoais_ joined #marpa
21:37 basiliscos joined #marpa
21:45 sivoais joined #marpa
21:50 jluis joined #marpa
21:50 hobbs joined #marpa
21:50 btyler_ joined #marpa
21:53 ernimril joined #marpa
21:53 flaviu joined #marpa
21:54 flaviu joined #marpa
21:54 ernimril joined #marpa
21:54 btyler_ joined #marpa
21:54 hobbs joined #marpa
21:54 jluis joined #marpa
21:54 sivoais joined #marpa
21:54 basiliscos joined #marpa
21:54 sirdancealot joined #marpa
21:54 lucs joined #marpa
21:54 shadowpaste joined #marpa
21:57 sivoais joined #marpa
22:06 jluis joined #marpa
22:06 hobbs joined #marpa
22:06 btyler_ joined #marpa
22:07 sivoais joined #marpa
22:12 jeffreykegler joined #marpa
22:19 ronsavage joined #marpa
22:22 jeffreykegler joined #marpa
22:32 sirdancealot joined #marpa

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