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

report open errors properly #376

Merged
merged 1 commit into from
Jul 3, 2024

Conversation

jlaurens
Copy link
Contributor

@jlaurens jlaurens commented Jul 3, 2024

Some operations require that open or popen succeeds. An assert wrapper is added when necessary.
Without that assert, the error manager reports an attempt to operate on a nil unexpected value.
With that assert, the error manager reports a file system problem.

Summer cleaning:

  • local copies of io... functions
  • extra local declaration removed
  • set file* variables to nil when the file is closed and the variable is used afterwards, ⇒ LLS annotations
  • stick to Lua 5.3 ⇒ no more "*a", "*all"
  • avoid leaving files open
  • consistency: prefer ...:close() instead of close(...)

@josephwright josephwright merged commit 11829b2 into latex3:main Jul 3, 2024
1 check passed
@jlaurens jlaurens deleted the summer-cleaning-open branch July 3, 2024 08:09
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.

None yet

2 participants