Rizin
unix-like reverse engineering framework and cli tools
Main Page
Related Pages
Modules
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
u
v
w
x
z
Functions
_
a
b
c
d
e
f
g
h
i
l
m
n
p
r
s
t
u
v
w
Variables
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
u
v
w
x
z
Enumerations
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
_
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
x
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
Enumerator
b
d
e
h
i
k
n
p
r
s
w
Properties
Events
Related Functions
Files
File List
File Members
All
$
.
[
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
[
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Variables
$
.
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Enumerations
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
x
y
z
Enumerator
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Macros
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Events
Friends
Macros
Modules
Pages
luac_specs_54.h
Go to the documentation of this file.
1
// SPDX-License-Identifier: LGPL-3.0-only
2
// SPDX-FileCopyrightText: 2021 Heersin <teablearcher@gmail.com>
3
4
#ifndef BUILD_LUAC_54_H
5
#define BUILD_LUAC_54_H
6
7
#include "
librz/bin/format/luac/luac_common.h
"
8
9
/* Macros for bin_luac.c */
10
/* Macros/Typedefs used in luac */
11
typedef
double
LUA_NUMBER
;
12
typedef
ut64
LUA_INTEGER
;
13
14
/* Macro Functions */
15
/* type casts (a macro highlights casts in the code) */
16
#define luac_cast(t, exp) ((t)(exp))
17
#define luac_cast_num(i) luac_cast(double, (i))
18
#define luac_cast_int(i) luac_cast(int, (i))
19
20
/* luac 5.4 spec */
21
/* Header Information */
22
#define LUAC_54_FORMAT_OFFSET 0x05
23
#define LUAC_54_LUAC_DATA_OFFSET 0x06
24
#define LUAC_54_INSTRUCTION_SIZE_OFFSET 0x0C
25
#define LUAC_54_INTEGER_SIZE_OFFSET 0x0D
26
#define LUAC_54_NUMBER_SIZE_OFFSET 0x0E
27
#define LUAC_54_INTEGER_VALID_OFFSET 0x0F
28
#define LUAC_54_NUMBER_VALID_OFFSET 0x17
29
#define LUAC_54_UPVALUES_NUMBER_OFFSET 0x1F
30
31
#define LUAC_54_SIGNATURE_SIZE 4
32
#define LUAC_54_VERSION_SIZE 1
33
#define LUAC_54_FORMAT_SIZE 1
34
#define LUAC_54_LUAC_DATA_SIZE 6
35
#define LUAC_54_INSTRUCTION_SIZE_SIZE 1
36
#define LUAC_54_INTEGER_SIZE_SIZE 1
37
#define LUAC_54_NUMBER_SIZE_SIZE 1
38
#define LUAC_54_INTEGER_VALID_SIZE 8
39
#define LUAC_54_NUMBER_VALID_SIZE 8
40
#define LUAC_54_UPVALUES_NUMBER_SIZE 1
41
42
#define LUAC_54_FORMAT 0
/* this is the official format */
43
#define LUAC_54_DATA "\x19\x93\r\n\x1a\n"
44
#define LUAC_54_INT_VALIDATION luac_cast_int(0x5678)
45
#define LUAC_54_NUMBER_VALIDATION luac_cast_num(370.5)
46
47
#define LUAC_54_HDRSIZE 0x20
48
49
/* Body */
50
#define LUAC_FILENAME_OFFSET 0x20
51
52
#endif
// BUILD_LUAC_54_H
luac_common.h
LUA_INTEGER
ut64 LUA_INTEGER
Definition:
luac_specs_54.h:12
LUA_NUMBER
double LUA_NUMBER
Definition:
luac_specs_54.h:11
ut64
ut64(WINAPI *w32_GetEnabledXStateFeatures)()
librz
bin
format
luac
v54
luac_specs_54.h
Generated by
1.9.1