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 SchemaCompiler filterPrimaryKey #1915

Merged
merged 3 commits into from
Feb 28, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Test/SchemaCompilerSpec.hs
Original file line number Diff line number Diff line change
Expand Up @@ -460,4 +460,4 @@ getInstanceDecl instanceName full =
takeInstanceDecl (line:rest)
| isEmpty line = []
| otherwise = line : takeInstanceDecl rest
takeInstanceDecl [] = error "never encountered newline?"
takeInstanceDecl [] = [] -- EOF reached
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would like to draw attention to this change here

In the test cases the instance I am looking for is the last one in the generated code, which resulted in an error, even tho i think it's totally fine. That this results in an error looked like a simple oversight to me so I changed it - the tests still pass... However a second opinion would be great in cause this actually had a deeper reason.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me 👍