You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
max benchmark milliseconds: 100000
sleeping 30,000ns
sleeping 30,000ns
sleeping 30,000ns
The max is 100,000ns, not 1,000,000,000ns as intended, so only three sets of 30,000ns can run of the intended 10 max iterations.
Max Digits
In the Mojo playground, when two or more arguments are used with default values for Int, the max digits is 11, anything more will remove digits at runtime. This problem doesn't occur for F64.
This works fine:
fndefault_val(a: Int=12345678901, b: Int=12345678901):
print(a, b)
default_val()
12345678901 12345678901
Here a has 12 digits and so will only print 10 digits:
fndefault_val_2(a: Int=123456789012, b: Int=12345678901):
print(a, b)
default_val_2()
1234567890 12345678901
Both arguments here have 13 digits, and so will only print 9 digits
fndefault_val_3(a: Int=1234567890123, b: Int=1234567890123):
print(a, b)
default_val_3()
Partial use of default values
It pushes the first two default values that weren't used to position 3 and 4.
You can see this does effect the current implementation of
Benchmark
in the standard library:The max is 100,000ns, not 1,000,000,000ns as intended, so only three sets of 30,000ns can run of the intended 10 max iterations.
Max Digits
In the Mojo playground, when two or more arguments are used with default values for
Int
, the max digits is 11, anything more will remove digits at runtime. This problem doesn't occur forF64
.This works fine:
Here
a
has 12 digits and so will only print 10 digits:Both arguments here have 13 digits, and so will only print 9 digits
System information
The text was updated successfully, but these errors were encountered: