3 ms·
But this isn't an `any -> any` case. They passed in a default value, as a string, which is the correct type for a default value for this column. Even with very
by bluepnume 2y ago
But this isn't an `any -> any` case. They passed in a default value, as a string, which is the correct type for a default value for this column. Even with very strong typing they wouldn't have got a type error here right?
- jowea 2y agoYou could make a special primary key column creation function that rejects static values.
- tazjin 2y agoYou don't even have to reject/forbid them, just make their use explicit.
- Nullabillity 2y agoYou can forbid static values and require it to be a function. Generally, static languages will just culturally be less likely to have this kind of invisible "T | (() -> T)" overload.