treeform / chroma

Everything you want to do with colors, in Nim.
MIT License
104 stars 12 forks source link

chroma-0.1.1 causing a compile-time error when attempting to compile to JS using Fidget examples (macOS) #16

Closed jlucasa closed 4 years ago

jlucasa commented 4 years ago

Title says it all. When running nim js bars.nim I get the following error:

/Users/jamen/.nimble/pkgs/chroma-0.1.1/chroma/distance.nim(10, 32)
/usr/local/Cellar/nim/1.2.6/nim/lib/pure/math.nim(1014, 16) ^
/usr/local/Cellar/nim/1.2.6/nim/lib/system/arithmetics.nim(499, 9) *=
/usr/local/Cellar/nim/1.2.6/nim/lib/system/arithmetics.nim(499, 9) Error: unhandled exception: value out of range

I confirmed that this error does not occur on chroma-0.1.0 (there is no distance.nim). This seems to be specific to macOS since Nim Playground doesn't reproduce this issue.

treeform commented 4 years ago

Fixed https://github.com/treeform/chroma/commit/84e4ec0cdf6b70d66632ac3a352d763d11ac9474

thank you for reporting!