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

Add support for verifying during compile time that file actually exists? #49

Open
Martinsos opened this issue Jul 19, 2023 · 0 comments

Comments

@Martinsos
Copy link
Member

Martinsos commented Jul 19, 2023

Sometimes we are referencing files on the disk that are bundled with the project, and they should exist during development and later when distributed, so it would be cool if compiler could confirm their existence on the disk.

I imagine that when we do something like [absfile|/some/path|], we could also somehow verify via TH that it exists. Maybe it would be special kind of quoter, smth like [absfile'|/some/path|], where ' indicates it will check for its existence on the disk? What about relative paths, for which we know what they are relative to, how would we do that kind of check?

I am not sure how feasible this really is, especially since location of the file can change from development to distribution, but it would be interesting to explore.

This also sounds quite costly, since during each compilation we would have to check for the files on the disk, I wonder if that is feasible.

@Martinsos Martinsos changed the title Add support for verifying during compile time that file exists? Add support for verifying during compile time that file actually exists? Jul 19, 2023
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

1 participant