Dňa 2011-11-03 0:07, HyperHacker wrote / napísal(a):
sorry for late answer, I didn't note question.
~= is corectly maintained.
lualubit is reworked now for Lua release 5.2.0 http://sourceforge.net/projects/lualubit/files/
and more info is on http://www.sbmintegral.sk/lua (with some potential problems for discuss)
One more argument for bitwise operators:
in MySQL I have table (12044 records) with column
by SQL command
SELECT modop,modop+0 FROM table_name;
I can have textual and numerical representation of flags:
M_ALARM_MIN,M_ARCH_ZME,M_REVRZ_AL 161 ... = (1<<0)|(1<<5)|(1<<7)
With bitwise operators I can deal with data from this column as with unsigned numbers ... 4 bytes each
without: I need for each record table with 8 items ...
Maybe interesting can be colored view of lualubit changes in Lua 5.2.0 sources : http://www.sbmintegral.sk/lua/diff_all_files.html
Simple test of operator corectness is here: http://www.sbmintegral.sk/lua/console_explain.html