• Advertisement
Sign in to follow this  

Feature Request about floating constants

This topic is 2377 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello! Thanks for this great library. But I have some request.

1. I want to use floating constant in script as my original type directly.
For example, "0.1" in script can be regarded as of my type, such as fixed-point number, not float or double.

I now use my special type "dec", fixed-point number, storeing 2^16times of original value to the primitive type "int".
Flags are asOBJ_VALUE | asOBJ_POD | asOBJ_APP_PRIMITIVE.
When register my function "func(dec, ...)", "func(double, ...)" is needed for convenience.
It is verbose, so I want not to do so.

Is it possible that embedded constants in binary code is of original type?
In other words, converting string to original type is done while Build().


2. I want to use hexadecimal floating constants in script, which is seen in C99 feature, etc.

I hope hex float could be also regarded as my own type.


Thank you. I wish you understand me.

Share this post


Link to post
Share on other sites
Advertisement
Sign in to follow this  

  • Advertisement