No idea why this call to float was here.

Fix large precision comparisions (even for ints).

Closes #166
This commit is contained in:
Julian Berman
2014-06-01 22:37:48 -04:00
parent bea28e9512
commit 0865bfbd4c

View File

@@ -94,10 +94,10 @@ def maximum(validator, maximum, instance, schema):
return return
if schema.get("exclusiveMaximum", False): if schema.get("exclusiveMaximum", False):
failed = float(instance) >= maximum failed = instance >= maximum
cmp = "greater than or equal to" cmp = "greater than or equal to"
else: else:
failed = float(instance) > maximum failed = instance > maximum
cmp = "greater than" cmp = "greater than"
if failed: if failed: