summaryrefslogtreecommitdiff
path: root/py/objnone.c
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2020-01-08 23:58:40 +1100
committerDamien George <damien.p.george@gmail.com>2020-01-13 01:01:45 +1100
commit6f0c83f6e186eb163c4209f211ab1c959d255e81 (patch)
tree9ae7b25171c8338adb4479b4c4a88448745bdc33 /py/objnone.c
parentecdb30ea64af18bad44439b6718ddd5b26e7b3f9 (diff)
py/obj.h: Redefine qstr object encoding to add immediate obj encoding.
This commit adjusts the definition of qstr encoding in all object representations by taking a single bit from the qstr space and using it to distinguish between qstrs and a new kind of literal object: immediate objects. In other words, the qstr space is divided in two pieces, one half for qstrs and the other half for immediate objects. There is still enough room for qstr values (29 bits in representation A on a 32-bit architecture, and 19 bits in representation C) and the new immediate objects can be used for things like None, False and True.
Diffstat (limited to 'py/objnone.c')
0 files changed, 0 insertions, 0 deletions