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

Type-check SAWCore prelude at compile time #446

Closed
atomb opened this issue May 20, 2019 · 1 comment
Closed

Type-check SAWCore prelude at compile time #446

atomb opened this issue May 20, 2019 · 1 comment

Comments

@atomb
Copy link
Contributor

atomb commented May 20, 2019

Currently, the SAWCore prelude is type-checked at startup, which can make it tedious to determine whether changes to the prelude are type-correct. Doing the type checking at compile time, which is possible with Template Haskell (and was done with earlier versions of SAWCore), would make development easier. It would also slightly improve the startup time of the SAWScript REPL (see #394).

@brianhuffman
Copy link
Contributor

The saw-core prelude actually is type-checked at compile time; it has been since GaloisInc/saw-core#27. So if there is a type error we actually do get a compile-time failure. It just doesn't save the result of type checking, so the saw-core type checker also needs to run upon REPL startup. As of GaloisInc/saw-core#35, the saw-core prelude is at least parsed at compile time, which is the most expensive part.

As we get compile-time saw-core type errors and also reasonable start-up performance, I don't think we need to do anything else about this issue at the moment.

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

No branches or pull requests

2 participants