Re: Switch question - yet again!
- Posted by SDPringle Nov 22, 2022
- 8146 views
As you know, internally when a destructor is added to an integer the representation of integer objects use a structure, which contains the reference count and store the integer as a double or long double, and a pointer to the destructor. This gets returned.
I thought it was simply promoting the integer to an atom. Is it using some other structure to carry an integer value with a destructor? Where is this defined?
-Greg
In my own way, I was describing promotion of an integer to an atom. Sometimes code counts on passed values being integers and the bug here would seem to be a failure to check whether it is a native integer or promoted integer to atom in the generated C code (and thus the translator part) or the C language back-end part.