Open soulofmischief opened 3 years ago
Hmm, ok, thanks. It's true that most of those stdio things are passed straight through to LLVM, so I'll look into it from there.
Sorry I haven't had a chance to look at this yet - I'm just currently 'between Windows boxes' and don't have an easy way to test. Will get back on it asap.
No worries, I'm making do for now.
After being frustrated with the existing JSON parsing bindings I wrote bindings for cJSON and wrote an example extempore program which uses curl and cJSON to pull hourly forecast data from the National Weather Service API and create generative music using the results.
I am planning to merge this upstream but bindings using toString
on floats/doubles are broken and I'd like to incorporate them and remove my hacky macros.
Environment: 64-bit Windows 10 Built from latest Extempore master
Problem:
toString
is not working for doubles or floats. It usessprintf %f
under the hood. Tinkering with sprintf directly reveals that doubles and floats returnf
instead of1.0
.Example:
(toString 1.0)
returns'f'
instead of'1.0'
It seems sprintf directly binds to a C lib in
llvmti.xtm
? I'm not sure. I am not familiar enough with LLVM to understand how to venture beyond this point without guidance.