lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

I do use quite a lot bitwise operators in C++.
In Lua 5.1, bit operations missed me a lot so I wrote a bit library
(instead of searching for an existent one).
So I am happy that a standard bit32 library now appears in Lua 5.2.

However, I am clearly against introducing new operators and new VM op
codes for bit operations:
- Lua has very few punctuation operators, privileging key words.
- Lua lacked bitwise operations during 18 years; I doubt that they
became suddenly so important to change the grammar for them
- Lua always favors small implementation code when possible. New
opcodes and operators are harder to introduce, and cannot be
- Even MATLAB doesn't have operators for bit operations
- If you want speed, use LuaJIT