-
Notifications
You must be signed in to change notification settings - Fork 11
/
stdlib.sublime-completions
138 lines (136 loc) · 10.5 KB
/
stdlib.sublime-completions
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
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
{
"scope" : "source.luae - string",
"completions":
[
// Constants
"_G",
"_VERSION",
{ "trigger": "package_cpath", "contents": "package.cpath" },
{ "trigger": "package_loaded", "contents": "package.loaded" },
{ "trigger": "package_loaders", "contents": "package.loaders" },
{ "trigger": "package_path", "contents": "package.path" },
{ "trigger": "package_preload", "contents": "package.preload" },
{ "trigger": "math_pi", "contents": "math.pi" },
{ "trigger": "math_huge", "contents": "math.huge" },
// No-arg functions
{ "trigger": "coroutine_running()", "contents": "coroutine.running()" },
{ "trigger": "io_flush()", "contents": "io.flush()" },
{ "trigger": "io_tmpfile()", "contents": "io.tmpfile()" },
{ "trigger": "os_clock()", "contents": "os.clock()" },
{ "trigger": "os_tmpname()", "contents": "os.tmpname()" },
{ "trigger": "debug_debug()", "contents": "debug.debug()" },
{ "trigger": "debug_getregistry()", "contents": "debug.getregistry()" },
// The rest
{ "trigger": "assert( v, message )", "contents": "assert( ${1:v}, ${2:message} )" },
{ "trigger": "collectgarbage( opt, arg )", "contents": "collectgarbage( ${1:opt}, ${2:arg} )" },
{ "trigger": "dofile( filename )", "contents": "dofile( ${1:filename} )" },
{ "trigger": "error( message, level )", "contents": "error( ${1:message}, ${2:level} )" },
{ "trigger": "getfenv( f )", "contents": "getfenv( ${1:f} )" },
{ "trigger": "getmetatable( object )", "contents": "getmetatable( ${1:object} )" },
{ "trigger": "ipairs( t )", "contents": "ipairs( ${1:t} )" },
{ "trigger": "load( func, chunkname )", "contents": "load( ${1:func}, ${2:chunkname} )" },
{ "trigger": "loadfile( filename )", "contents": "loadfile( ${1:filename} )" },
{ "trigger": "loadstring( string, chunkname )", "contents": "loadstring( ${1:string}, ${2:chunkname} )" },
{ "trigger": "next( table, index )", "contents": "next( ${1:table}, ${2:index} )" },
{ "trigger": "pairs( t )", "contents": "pairs( ${1:t} )" },
{ "trigger": "pcall( f, arg1, ... )", "contents": "pcall( ${1:f}, ${2:arg1}, ${3:...} )" },
{ "trigger": "print( ... )", "contents": "print( ${1:...} )" },
{ "trigger": "rawequal( v1, v2 )", "contents": "rawequal( ${1:v1}, ${2:v2} )" },
{ "trigger": "rawget( table, index )", "contents": "rawget( ${1:table}, ${2:index} )" },
{ "trigger": "rawset( table, index, value )", "contents": "rawset( ${1:table}, ${2:index}, ${3:value} )" },
{ "trigger": "select( index, ... )", "contents": "select( ${1:index}, ${2:...} )" },
{ "trigger": "setfenv( f, table )", "contents": "setfenv( ${1:f}, ${2:table} )" },
{ "trigger": "setmetatable( table, metatable )", "contents": "setmetatable( ${1:table}, ${2:metatable} )" },
{ "trigger": "tonumber( e, base )", "contents": "tonumber( ${1:e}, ${2:base} )" },
{ "trigger": "tostring( e )", "contents": "tostring( ${1:e} )" },
{ "trigger": "type( v )", "contents": "type( ${1:v} )" },
{ "trigger": "unpack( list, i, j )", "contents": "unpack( ${1:list}, ${2:i}, ${3:j} )" },
{ "trigger": "xpcall( f, err )", "contents": "xpcall( ${1:f}, ${2:err} )" },
{ "trigger": "coroutine_create( f )", "contents": "coroutine.create( ${1:f} )" },
{ "trigger": "coroutine_resume( co, val1, ... )", "contents": "coroutine.resume( ${1:co}, ${2:val1}, ${3:...} )" },
{ "trigger": "coroutine_status( co )", "contents": "coroutine.status( ${1:co} )" },
{ "trigger": "coroutine_wrap( f )", "contents": "coroutine.wrap( ${1:f} )" },
{ "trigger": "coroutine_yield( ... )", "contents": "coroutine.yield( ${1:...} )" },
{ "trigger": "module( name, ... )", "contents": "module( ${1:name}, ${2:...} )" },
{ "trigger": "require( modname )", "contents": "require( ${1:modname} )" },
{ "trigger": "package_loadlib( libname, funcname )", "contents": "package.loadlib( ${1:libname}, ${2:funcname} )" },
{ "trigger": "package_seeall( module )", "contents": "package.seeall( ${1:module} )" },
{ "trigger": "string_byte( s, i, j )", "contents": "string.byte( ${1:s}, ${2:i}, ${3:j} )" },
{ "trigger": "string_char( ... )", "contents": "string.char( ${1:...} )" },
{ "trigger": "string_dump( function )", "contents": "string.dump( ${1:func} )" },
{ "trigger": "string_find( s, pattern, init, plain )", "contents": "string.find( ${1:s}, ${2:pattern}, ${3:init}, ${4:plain} )" },
{ "trigger": "string_format( formatstring, ... )", "contents": "string.format( ${1:formatstring}, ${2:...} )" },
{ "trigger": "string_gmatch( s, pattern )", "contents": "string.gmatch( ${1:s}, ${2:pattern} )" },
{ "trigger": "string_gsub( s, pattern, repl, n )", "contents": "string.gsub( ${1:s}, ${2:pattern}, ${3:repl}, ${4:n} )" },
{ "trigger": "string_len( s )", "contents": "string.len( ${1:s} )" },
{ "trigger": "string_lower( s )", "contents": "string.lower( ${1:s} )" },
{ "trigger": "string_match( s, pattern, init )", "contents": "string.match( ${1:s}, ${2:pattern}, ${3:init} )" },
{ "trigger": "string_rep( s, n )", "contents": "string.rep( ${1:s}, ${2:n} )" },
{ "trigger": "string_reverse( s )", "contents": "string.reverse( ${1:s} )" },
{ "trigger": "string_sub( s, i, j )", "contents": "string.sub( ${1:s}, ${2:i}, ${3:j} )" },
{ "trigger": "string_upper( s )", "contents": "string.upper( ${1:s} )" },
{ "trigger": "table_concat( table, sep, i, j )", "contents": "table.concat( ${1:table}, ${2:sep}, ${3:i}, ${4:j} )" },
{ "trigger": "table_insert( table, pos, value )", "contents": "table.insert( ${1:table}, ${2:pos}, ${3:value} )" },
{ "trigger": "table_maxn( table )", "contents": "table.maxn( ${1:table} )" },
{ "trigger": "table_remove( table, pos )", "contents": "table.remove( ${1:table}, ${2:pos} )" },
{ "trigger": "table_sort( table, comp )", "contents": "table.sort( ${1:table}, ${2:comp} )" },
{ "trigger": "math_abs( x )", "contents": "math.abs( ${1:x} )" },
{ "trigger": "math_acos( x )", "contents": "math.acos( ${1:x} )" },
{ "trigger": "math_asin( x )", "contents": "math.asin( ${1:x} )" },
{ "trigger": "math_atan( x )", "contents": "math.atan( ${1:x} )" },
{ "trigger": "math_atan2( y, x )", "contents": "math.atan2( ${1:y}, ${2:x} )" },
{ "trigger": "math_ceil( x )", "contents": "math.ceil( ${1:x} )" },
{ "trigger": "math_cos( x )", "contents": "math.cos( ${1:x} )" },
{ "trigger": "math_cosh( x )", "contents": "math.cosh( ${1:x} )" },
{ "trigger": "math_deg( x )", "contents": "math.deg( ${1:x} )" },
{ "trigger": "math_exp( x )", "contents": "math.exp( ${1:x} )" },
{ "trigger": "math_floor( x )", "contents": "math.floor( ${1:x} )" },
{ "trigger": "math_fmod( x, y )", "contents": "math.fmod( ${1:x}, ${2:y} )" },
{ "trigger": "math_frexp( x )", "contents": "math.frexp( ${1:x} )" },
{ "trigger": "math_ldexp( m, e )", "contents": "math.ldexp( ${1:m}, ${2:e} )" },
{ "trigger": "math_log( x )", "contents": "math.log( ${1:x} )" },
{ "trigger": "math_log10( x )", "contents": "math.log10( ${1:x} )" },
{ "trigger": "math_max( x, ... )", "contents": "math.max( ${1:x}, ${2:...} )" },
{ "trigger": "math_min( x, ... )", "contents": "math.min( ${1:x}, ${2:...} )" },
{ "trigger": "math_modf( x )", "contents": "math.modf( ${1:x} )" },
{ "trigger": "math_pow( x, y )", "contents": "math.pow( ${1:x}, ${2:y} )" },
{ "trigger": "math_rad( x )", "contents": "math.rad( ${1:x} )" },
{ "trigger": "math_random( m, n )", "contents": "math.random( ${1:m}, ${2:n} )" },
{ "trigger": "math_randomseed( x )", "contents": "math.randomseed( ${1:x} )" },
{ "trigger": "math_sin( x )", "contents": "math.sin( ${1:x} )" },
{ "trigger": "math_sinh( x )", "contents": "math.sinh( ${1:x} )" },
{ "trigger": "math_sqrt( x )", "contents": "math.sqrt( ${1:x} )" },
{ "trigger": "math_tan( x )", "contents": "math.tan( ${1:x} )" },
{ "trigger": "math_tanh( x )", "contents": "math.tanh( ${1:x} )" },
{ "trigger": "io_close( file )", "contents": "io.close( ${1:file} )" },
{ "trigger": "io_input( file )", "contents": "io.input( ${1:file} )" },
{ "trigger": "io_lines( filename )", "contents": "io.lines( ${1:filename} )" },
{ "trigger": "io_open( filename, mode )", "contents": "io.open( ${1:filename}, ${2:mode} )" },
{ "trigger": "io_output( file )", "contents": "io.output( ${1:file} )" },
{ "trigger": "io_popen( prog, mode )", "contents": "io.popen( ${1:prog}, ${2:mode} )" },
{ "trigger": "io_read( ... )", "contents": "io.read( ${1:...} )" },
{ "trigger": "io_type( obj )", "contents": "io.type( ${1:obj} )" },
{ "trigger": "io_write( ... )", "contents": "io.write( ${1:...} )" },
{ "trigger": "os_date( format, time )", "contents": "os.date( ${1:format}, ${2:time} )" },
{ "trigger": "os_difftime( t2, t1 )", "contents": "os.difftime( ${1:t2}, ${2:t1} )" },
{ "trigger": "os_execute( command )", "contents": "os.execute( ${1:command} )" },
{ "trigger": "os_exit( code )", "contents": "os.exit( ${1:code} )" },
{ "trigger": "os_getenv( varname )", "contents": "os.getenv( ${1:varname} )" },
{ "trigger": "os_remove( filename )", "contents": "os.remove( ${1:filename} )" },
{ "trigger": "os_rename( oldname, newname )", "contents": "os.rename( ${1:oldname}, ${2:newname} )" },
{ "trigger": "os_setlocale( locale, category )", "contents": "os.setlocale( ${1:locale}, ${2:category} )" },
{ "trigger": "os_time( table )", "contents": "os.time( ${1:table} )" },
{ "trigger": "debug_getfenv( o )", "contents": "debug.getfenv( ${1:o} )" },
{ "trigger": "debug_gethook( thread )", "contents": "debug.gethook( ${1:thread} )" },
{ "trigger": "debug_getinfo( thread, function, what )", "contents": "debug.getinfo( ${1:thread}, ${2:func}, ${3:what} )" },
{ "trigger": "debug_getlocal( thread, level, local )", "contents": "debug.getlocal( ${1:thread}, ${2:level}, ${3:local} )" },
{ "trigger": "debug_getmetatable( object )", "contents": "debug.getmetatable( ${1:object} )" },
{ "trigger": "debug_getupvalue( func, up )", "contents": "debug.getupvalue( ${1:func}, ${2:up} )" },
{ "trigger": "debug_setfenv( object, table )", "contents": "debug.setfenv( ${1:object}, ${2:table} )" },
{ "trigger": "debug_sethook( thread, hook, mask, count )", "contents": "debug.sethook( ${1:thread}, ${2:hook}, ${3:mask}, ${4:count} )" },
{ "trigger": "debug_setlocal( thread, level, local, value )", "contents": "debug.setlocal( ${1:thread}, ${2:level}, ${3:local}, ${4:value} )" },
{ "trigger": "debug_setmetatable( object, table )", "contents": "debug.setmetatable( ${1:object}, ${2:table} )" },
{ "trigger": "debug_setupvalue( func, up, value )", "contents": "debug.setupvalue( ${1:func}, ${2:up}, ${3:value} )" },
{ "trigger": "debug_traceback( thread, message, level )", "contents": "debug.traceback( ${1:thread}, ${2:message}, ${3:level} )" },
]
}