Closed peterdesmet closed 6 years ago
Same for defining an unspecified float, would that be:
decimalLatitude:
numberformat: '.'
"I hope that specification can be removed"
Why getting rid of the type
specification? Do we want (and can we) capture all the use-cases of having integer or floats using the numberformat
specification, taking into account we add the your two suggestions:
postalcode:
numberformat: x # How can you define an integer of unspecified length?
decimalLatitude:
numberformat: '.'
Let's say we exclude the type
option, then it should be clear that for the min
/max
rules, a coercing towards floats is required before the comparison of the value can be done. Moreover, the comparison is always as float?
So, should we specifically require a numberformat
specification when a min
or max
specification is provided?
The necessity of type
to handle min
and max
rules has been removed from the code in pywhip
, still need to check the extension on the numberformat
.
This is in the whip statements, closing here.
The syntax still lists
type
at https://github.com/inbo/whip/blame/master/docs/syntax.md#L398, but that is not defined. I hope that specification can be removed, but than the question remains how that example can be redefined:@stijnvanhoey, maybe as: