graphql-parser icon indicating copy to clipboard operation
graphql-parser copied to clipboard

i64 is used for integers when i32 should be used

Open mathstuf opened this issue 3 years ago • 2 comments

This code says that the spec doesn't have a size for numbers, but it does:

The Int scalar type represents a signed 32-bit numeric non-fractional value. Response formats that support a 32-bit integer or a number type should use that type to represent this scalar.

See: graphql-rust/graphql-client#266

mathstuf avatar Jun 25 '21 15:06 mathstuf

This is true for inputs and outputs. But I'm still not sure it is true for literals.

tailhook avatar Oct 08 '21 14:10 tailhook

I made a feature for this so it's not breaking and thus doesn't need to wait for a major version. Someone could even add deprecation notice or on move to v1.0.0 just switch it to default to i32 and still offer the i64 as a feature to make the transition easier for people. #65

ittorchbearer avatar Apr 28 '22 19:04 ittorchbearer