-
Notifications
You must be signed in to change notification settings - Fork 244
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
support unsigned int type #2459
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some validation of input values, so fail gracefully if giving negative values from the client.
@@ -48,3 +48,6 @@ opt-level = 3 | |||
codegen-units = 1 | |||
opt-level = 'z' # Optimize for size. | |||
#strip="symbols" | |||
|
|||
[patch."https://github.com/prisma/quaint"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
reminder to remove this before merging
@@ -273,6 +273,7 @@ impl<'a> LowerDmlToAst<'a> { | |||
PrismaValue::Float(value) => ast::Expression::NumericValue(value.to_string(), ast::Span::empty()), | |||
PrismaValue::Int(value) => ast::Expression::NumericValue(value.to_string(), ast::Span::empty()), | |||
PrismaValue::BigInt(value) => ast::Expression::NumericValue(value.to_string(), ast::Span::empty()), | |||
PrismaValue::UnsignedInt(value) => ast::Expression::NumericValue(value.to_string(), ast::Span::empty()), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
UInt
, but choose whatever you wish.
68d22eb
to
7c4f5e7
Compare
The QE has no idea about native types, we can't validate that. |
this work is based off the work in the quaint project prisma/quaint#335
It is not ready to be merged until the quaint PR has been merged.
At this stage we don't really support unsigned integers so we try and convert it to a signed int. An error is returned if that fails.