5 ms·
In your mind, you can expand the code to make it clearer: char *p; p = --(char*)hash_ptr.parm.v.p; *p = fpop(sst);
by NonEUCitizen 5y ago
In your mind, you can expand the code to make it clearer:
char *p;
p = --(char*)hash_ptr.parm.v.p;
*p = fpop(sst);
- sargstuff 5y ago(char) cast looks like being used for address alignment. Need to check what address alignment for target environment is and change the cast to appropriate alignment. aka sparc addresses are not 8 bit aligned! hash_ptr.parm.v.p points to top of sst stack containing an 8 bit aligned pointer address. p == ---(.....) gets address to pop off stack. missing a step/statement. sst needs to be in struc address given by p. aka hash_ptr.parm.v.sst p should then point to the result of fpop(hash_ptr.parm.v.sst
- zoomablemind 5y agofpop() is a typed-pop and yields a float from the value union. This design also uses float storage for any number including integers. So in the code fragment above, it seems that the fpop() number is saved into a character value (apparently with some certitude that it should fit into char type) at some pointer destination in what seems to be an array of chars.