It may be that at the time the parser-tools were developed, we were
not yet using a struct for srclocs. I think today we would not do what
the parser tools are doing.

Robby


On Thu, Dec 8, 2016 at 12:44 PM, Matthew Butterick <[email protected]> wrote:
> Forgive the possibly noobish question.
>
> Racket's name for a precise place in a source file is called a source
> location [1] — sometimes abbreviated `srcloc` — and has four possible
> fields: line, column, position, and span.
>
> The `parser-tools/lex` library also dabbles in source locations, but IIUC
> calls them "positions" rather than "locations" [2]. Moreover, what is known
> as the "position" field in a Racket source location is called an "offset" in
> `parser-tools/lex`. [also 2]
>
> So is it fair to say that `parser-tools/lex` is using names that are
> inconsistent with Racket (and, in the case of "position", contradictory)?
>
>
> [1]
> http://docs.racket-lang.org/reference/exns.html?q=srcloc#%28def._%28%28lib._racket%2Fprivate%2Fbase..rkt%29._srcloc%29%29
>
> [2]
> http://docs.racket-lang.org/parser-tools/Lexers.html#%28def._%28%28lib._parser-tools%2Flex..rkt%29._position%29%29
>
> --
> You received this message because you are subscribed to the Google Groups
> "Racket Developers" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/racket-dev/B26F0406-4DA6-42F9-83DE-9C2D4BE9C90A%40mbtype.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/racket-dev/CAL3TdOMR5RpM9NExS1OHZA2AaeC1USb7m5ppAE04W%3DHiYh1kbg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to