forked from tarantool/tarantool
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.luacheckrc
117 lines (112 loc) · 2.63 KB
/
.luacheckrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
std = "luajit"
globals = {"box", "_TARANTOOL", "tonumber64", "utf8"}
ignore = {
-- Accessing an undefined field of a global variable <debug>.
"143/debug",
-- Accessing an undefined field of a global variable <os>.
"143/os",
-- Accessing an undefined field of a global variable <string>.
"143/string",
-- Accessing an undefined field of a global variable <table>.
"143/table",
-- Unused argument <self>.
"212/self",
-- Redefining a local variable.
"411",
-- Redefining an argument.
"412",
-- Shadowing a local variable.
"421",
-- Shadowing an upvalue.
"431",
-- Shadowing an upvalue argument.
"432",
-- Unused variable with `_` prefix.
"212/_.*",
-- Unused loop variable with `_` prefix.
"213/_.*",
}
include_files = {
"**/*.lua",
}
exclude_files = {
"build/**/*.lua",
"test-run/**/*.lua",
"test/app/*.test.lua",
"test/box/*.test.lua",
"test/engine/*.test.lua",
"test/engine_long/*.test.lua",
"test/replication/*.test.lua",
"test/sql/**/*.lua",
"test/swim/*.test.lua",
"test/var/**/*.lua",
"test/vinyl/*.test.lua",
"test/wal_off/*.test.lua",
"test/xlog/*.test.lua",
"test/static/corpus/luaL_loadbuffer/*.lua",
"third_party/**/*.lua",
".rocks/**/*.lua",
".git/**/*.lua",
}
files["test/sql-tap/**/*.lua"] = {
ignore = {
-- Line is too long.
-- https://github.com/tarantool/tarantool/issues/5181
"631"
}
}
files["src/lua/help.lua"] = {
-- Globals defined for interactive mode.
globals = {"help", "tutorial"},
}
files["src/lua/init.lua"] = {
-- Miscellaneous global function definition.
globals = {"dostring"},
}
files["test/box/box.lua"] = {
globals = {
"cfg_filter",
"sorted",
"iproto_request",
}
}
files["test/box-tap/session.test.lua"] = {
globals = {
"session",
"space",
"f1",
"f2",
},
}
files["test/box-tap/extended_error.test.lua"] = {
globals = {
"error_access_denied",
"error_new",
"error_new_stacked",
"error_throw",
"error_throw_stacked",
"error_throw_access_denied",
"forbidden_function",
},
}
files["test/swim/box.lua"] = {
globals = {
"listen_port",
"listen_uri",
"uuid",
"uri",
}
}
files["test/replication/replica_quorum.lua"] = {
globals = {
"INSTANCE_URI",
"nonexistent_uri",
},
}
-- Defined functions is unused in preamble,
-- but could be used by generated Lua programs.
files["test/fuzz/luaL_loadbuffer/preamble.lua"] = {
ignore = {
"211",
},
}