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

fail if an unknown pragma or unsupported pragma feature is found #105

Open
BebeSparkelSparkel opened this issue Jul 24, 2024 · 2 comments
Open
Labels
enhancement New feature or request

Comments

@BebeSparkelSparkel
Copy link

If cabal-gild finds an unsupported pragma in the cabal file it should fail and report the unsupported pragma.

The flag --ignore-unsupported-pragmas should be added to ignore these pragmas and continue processing the cabal file.

This would have been useful for understanding why #96 was failing.

This should be added to all major versions.

@tfausak
Copy link
Owner

tfausak commented Jul 24, 2024

I like the idea of failing by default but providing a flag for turning them into warnings to allow for forwards compatibility.

Note that this wouldn't have necessarily helped with #96 because */foo is a valid filename that also happens to be a glob. Older versions certainly could suggest that this probably isn't doing what you intended, but it's not wrong per se.

@BebeSparkelSparkel
Copy link
Author

The warning flag is a better idea, so --warn-unsupported-pragmas flag.

@tfausak tfausak added the enhancement New feature or request label Jul 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants