Re: Comparison against backslash obtained via .substring

2024-11-03 Thread onf
Hi Branden, thank you for having patience with me :) I have joined all the replies here. On Sun Nov 3, 2024 at 4:36 AM CET, G. Branden Robinson wrote: > At 2024-11-03T03:56:23+0100, onf wrote: > > Ugh, I should have taken more time to reply -- I missed the fact that > > groff doesn't consider DEL

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread G. Branden Robinson
Hi onf, At 2024-11-03T03:56:23+0100, onf wrote: > On Sun Nov 3, 2024 at 2:53 AM CET, onf wrote: > > changing the escape character hasn't occured to me, that's clever! > > Unfortunately it doesn't work -- groff won't allow me to set the > > escape character to a control one, and I cannot use some o

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread G. Branden Robinson
Hi onf, At 2024-11-03T03:25:01+0100, onf wrote: > On Sat Nov 2, 2024 at 4:15 AM CET, Dave Kemper wrote: > > Parsing strings that contain escapes is something that an open groff > > bug report (http://savannah.gnu.org/bugs/?62264) seeks to make more > > consistent. Does the mechanism proposed in t

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread onf
On Sun Nov 3, 2024 at 2:53 AM CET, onf wrote: > changing the escape character hasn't occured to me, that's clever! > Unfortunately it doesn't work -- groff won't allow me to set the > escape character to a control one, and I cannot use some obscure > unicode glyph because it must be ASCII... I coul

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread G. Branden Robinson
Hi onf, At 2024-11-03T02:53:14+0100, onf wrote: > changing the escape character hasn't occured to me, that's clever! > Unfortunately it doesn't work -- groff won't allow me to set the > escape character to a control one, It does, but it has to be a valid input character. groff(7): On a ma

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread onf
Hi Dave, On Sat Nov 2, 2024 at 4:15 AM CET, Dave Kemper wrote: > Parsing strings that contain escapes is something that an open groff > bug report (http://savannah.gnu.org/bugs/?62264) seeks to make more > consistent. Does the mechanism proposed in that report sound like it > would solve the prob

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread onf
Hi Branden, On Sat Nov 2, 2024 at 10:16 AM CET, G. Branden Robinson wrote: > There's an example of this in groff's "an.tmac" file. > > It's not a model of elegance, but it works. > > https://git.savannah.gnu.org/cgit/groff.git/tree/tmac/an.tmac?id=5011cd1d5a647d977f74ccaad21e5abe004fe30e#n529 > >

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread G. Branden Robinson
Hi onf & Dave, At 2024-11-01T22:15:58-0500, Dave Kemper wrote: > Parsing strings that contain escapes is something that an open groff > bug report (http://savannah.gnu.org/bugs/?62264) seeks to make more > consistent. Does the mechanism proposed in that report sound like it > would solve the prob

Re: Comparison against backslash obtained via .substring

2024-11-01 Thread Dave Kemper
Hi onf, Parsing strings that contain escapes is something that an open groff bug report (http://savannah.gnu.org/bugs/?62264) seeks to make more consistent. Does the mechanism proposed in that report sound like it would solve the problem you're facing? (By default, the savannah bug tracker displ

Comparison against backslash obtained via .substring

2024-11-01 Thread onf
Hi all, I have a bunch of macros which take flags like -c, -nr etc. I wrote a getopt-like parser macro which works something like this: caller: .getopt:setup c nr: .getopt:parse \\$@ .shift \\n[getopt:nshift] getopt:parse: .has-prefix - "\\$1" .while \\n[has-prefix?] \{\ . \" ... .