Shop OBEX P1 Docs P2 Docs Learn Events
"union" — Parallax Forums

"union"

MuncherMuncher Posts: 38
edited 2006-06-19 00:15 in Propeller 1
1) is it possible to put a variable in spin at a certain place in memory, and 2) if so, is it possible to have two variables located at the same address?

Example:

long pixel
byte argb[noparse][[/noparse]3] @pixel

Thanks,
Muncher

Comments

  • cgraceycgracey Posts: 14,133
    edited 2006-06-19 00:15
    Right now, the compiler doesn't have any allowance for having multiple types at the same address. It's all possible, though. Maybe we'll implement this. Many times, I've needed a byte buffer at a long boundary. It would have been handy to have what you're talking about. I'll look into this tomorrow. Thanks for the suggestion.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔


    Chip Gracey
    Parallax, Inc.
Sign In or Register to comment.