Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix correspondence between location/c and Location in typed/racket #1414

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

joergen7
Copy link

@joergen7 joergen7 commented Nov 26, 2024

Checklist

  • Bugfix
  • Feature
  • tests included
  • documentation

See also: Issue #1415

In (untyped) racket, the XML collection uses a source struct whose fields start and stop follow the contract location/c. The location/c contract is defined as follows:

(or/c location? symbol? #f)

However, in typed/racket the aforementioned fields are typed as Location which represents only the struct but neither symbols nor false.

This pull request extends the typing of source's start and stop to entail both symbols and false typing them as

(U Location Symbol False)

@joergen7 joergen7 changed the title fix correspondence between location? and Location in typed/racket Fix correspondence between location/c and Location in typed/racket Nov 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant