diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2010-10-27 14:50:32 -0200 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2010-10-27 14:50:32 -0200 |
commit | 572e5e6b282418b134e4d3712e2ab8058e13a2c9 (patch) | |
tree | 3c6599cbd20f995c5a7855291370f14893ae6bd8 | |
parent | 6098e06e09e82409710c52eeaefb11395345e194 (diff) | |
download | lua-572e5e6b282418b134e4d3712e2ab8058e13a2c9.tar.gz lua-572e5e6b282418b134e4d3712e2ab8058e13a2c9.tar.bz2 lua-572e5e6b282418b134e4d3712e2ab8058e13a2c9.zip |
new names for bit functions (mimicking assembler)
-rw-r--r-- | lbitlib.c | 22 |
1 files changed, 11 insertions, 11 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lbitlib.c,v 1.7 2010/10/25 14:32:36 roberto Exp roberto $ | 2 | ** $Id: lbitlib.c,v 1.8 2010/10/25 20:31:11 roberto Exp roberto $ |
3 | ** Standard library for bitwise operations | 3 | ** Standard library for bitwise operations |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -134,16 +134,16 @@ static int b_ror (lua_State *L) { | |||
134 | 134 | ||
135 | 135 | ||
136 | static const luaL_Reg bitlib[] = { | 136 | static const luaL_Reg bitlib[] = { |
137 | {"band", b_and}, | 137 | {"AND", b_and}, |
138 | {"btest", b_test}, | 138 | {"TEST", b_test}, |
139 | {"bor", b_or}, | 139 | {"OR", b_or}, |
140 | {"bxor", b_xor}, | 140 | {"XOR", b_xor}, |
141 | {"bnot", b_not}, | 141 | {"NOT", b_not}, |
142 | {"lshift", b_lshift}, | 142 | {"SHL", b_lshift}, |
143 | {"arshift", b_arshift}, | 143 | {"SAR", b_arshift}, |
144 | {"rshift", b_rshift}, | 144 | {"SHR", b_rshift}, |
145 | {"rol", b_rol}, | 145 | {"ROL", b_rol}, |
146 | {"ror", b_ror}, | 146 | {"ROR", b_ror}, |
147 | {NULL, NULL} | 147 | {NULL, NULL} |
148 | }; | 148 | }; |
149 | 149 | ||