I wrote an article last week about using bit fields and masks to store values in just one variable, like a chess piece and its color.
This week, I've updated the program to use enum to solve the same problem. The code is much easier to read:
https://www.both.org/?p=9244
Using enum is another method to keep handy.
=> More informations about this toot | View the thread | More toots from freedosproject@fosstodon.org
text/gemini
This content has been proxied by September (ba2dc).