scylladb-zpp-2024-javascript-driver / scylladb-javascript-driver

Apache License 2.0
6 stars 0 forks source link

Null values should be convertible to numeric types #79

Open adespawn opened 1 week ago

adespawn commented 1 week ago

According to should allow parameters without hints test, null values should be able to convert to i32.

Identify other such types and add support for such conversion.

adespawn commented 1 week ago

unset should also be treated the same: https://github.com/scylladb-zpp-2024-javascript-driver/scylladb-javascript-driver/blob/bad25f7a837a434efa6aa3a0c50157c18e62ce46/test/integration/not-supported/client-execute-tests.js#L592-L629

wprzytula commented 4 days ago

I believe this formulation can be misleading. nullable values of type T are represented in the Rust driver as Option<T>, with None representing the null value. It's not that null should be convertible to i32, but rather to Option<i32>.