Skip to content

Latest commit

 

History

History
203 lines (181 loc) · 11.3 KB

06_std.md

File metadata and controls

203 lines (181 loc) · 11.3 KB

Standard Libraries

This sections gives an overview of the implementation state of the lua system libraries.

Basic library

  • Is compatible to the lua reference. assert Calls System.Diagnostics.Debug.Assert.
  • Not full compatible to the lua reference. collectgarbage Only the parameter "count" and "collect" are supported. "step" and "isrunning" return always "true". "setpause" returns "false". "* Not full compatible to the lua reference. dofile Redirects to DoChunk to load and run a text file. Optional add parameters for the script.
dofile('test.lua', 'a', 1, 'b', 2);

stdin is not supported."

  • Not full compatible to the lua reference. dochunk Redirects to DoChunk.
  • Is compatible to the lua reference. error Throws a {{LuaRuntimeException}}.
  • Is compatible to the lua reference. _G
  • Not full compatible to the lua reference. getmetatable No metatable for userdata, operators are used.
  • Is compatible to the lua reference. ipairs
  • Not full compatible to the lua reference. load The "mode" "b" is not supported.
  • Not full compatible to the lua reference. loadfile The "mode" "b" is not supported.
  • Is compatible to the lua reference. next
  • Is compatible to the lua reference. pairs
  • Is compatible to the lua reference. pcall
  • Is compatible to the lua reference. print Prints on the debug output.
  • Is compatible to the lua reference. rawequal
  • Is compatible to the lua reference. rawget
  • Is compatible to the lua reference. rawlen
  • Is compatible to the lua reference. rawset
  • Is compatible to the lua reference. select
  • Not full compatible to the lua reference. setmetatable No metatable for userdata, operators are used.
  • Is compatible to the lua reference. tonumber
  • Is compatible to the lua reference. tostring
  • Is compatible to the lua reference. type “type” is extended with a second boolean parameter, that replaces “userdata” with the clr-type-name: type(obj, true);
  • Is compatible to the lua reference. _VERSION
  • Is compatible to the lua reference. xpcall

Coroutine library (coroutine)

Coroutines are implemented in the LuaThread class. This class creates a managed thread for every coroutine. The resume-steps can run asynchronous.

  • Is compatible to the lua reference. create
  • Is compatible to the lua reference. resume
  • Is compatible to the lua reference. running
  • Is compatible to the lua reference. status
  • Is compatible to the lua reference. wrap
  • Is compatible to the lua reference. yield
  • Not full compatible to the lua reference. :BeginResume Starts the execution of the next part of the thread.
  • Not full compatible to the lua reference. :EndResume Waits for the end of currently running part.

Package library (package)

  • Not full compatible to the lua reference. require Different implementation, that fits better with the NeoLua framework.
  • Is compatible to the lua reference. config
  • Not implemented. Yet. cpath
  • Not implemented. Yet. loaded
  • Not implemented. Yet. loadlib
  • Is compatible to the lua reference. path
  • Not implemented. Yet. preload
  • Not implemented. Yet. searchers
  • Not implemented. Yet. searchpath

String manipulation (string)

  • Is compatible to the lua reference. byte
  • Is compatible to the lua reference. char
  • Not implemented. Yet. dump
  • Not full compatible to the lua reference. find .net regex syntax with an exchange of the escape symbol % is . But you can set string.__TranslateRegEx to false to use .net regulare expressions.
  • Is compatible to the lua reference. format
  • Not full compatible to the lua reference. gmatch .net regex syntax with an exchange of the escape symbol % is . But you can set string.__TranslateRegEx to false to use .net regulare expressions.
  • Not full compatible to the lua reference. gsub .net regex syntax with an exchange of the escape symbol % is . But you can set string.__TranslateRegEx to false to use .net regulare expressions.
  • Is compatible to the lua reference. len
  • Is compatible to the lua reference. lower
  • Not full compatible to the lua reference. match
  • Not implemented. Yet. pack
  • Not implemented. Yet. packsize
  • Is compatible to the lua reference. rep
  • Is compatible to the lua reference. reverse
  • Is compatible to the lua reference. sub
  • Not implemented. Yet. unpack
  • Is compatible to the lua reference. upper

Table manipulation (table)

  • Is compatible to the lua reference. concat
  • Is compatible to the lua reference. insert
  • Not implemented. Yet. move
  • Is compatible to the lua reference. pack
  • Is compatible to the lua reference. remove
  • Is compatible to the lua reference. sort
  • Is compatible to the lua reference. unpack

Mathematical functions (math)

  • Is compatible to the lua reference. abs
  • Is compatible to the lua reference. acos
  • Is compatible to the lua reference. asin
  • Is compatible to the lua reference. atan
  • Is compatible to the lua reference. atan2
  • Is compatible to the lua reference. ceil
  • Is compatible to the lua reference. cos
  • Is compatible to the lua reference. cosh
  • Is compatible to the lua reference. deg
  • Is compatible to the lua reference. e
  • Is compatible to the lua reference. exp
  • Is compatible to the lua reference. floar
  • Is compatible to the lua reference. fmod
  • Is compatible to the lua reference. frexp
  • Is compatible to the lua reference. huge
  • Is compatible to the lua reference. ldexp
  • Is compatible to the lua reference. log
  • Is compatible to the lua reference. max
  • Is compatible to the lua reference. maxinteger
  • Is compatible to the lua reference. min
  • Is compatible to the lua reference. mininteger
  • Is compatible to the lua reference. modf
  • Is compatible to the lua reference. pi
  • Is compatible to the lua reference. pow
  • Is compatible to the lua reference. rad
  • Is compatible to the lua reference. random
  • Is compatible to the lua reference. randomseed
  • Is compatible to the lua reference. sin
  • Is compatible to the lua reference. sinh
  • Is compatible to the lua reference. sqrt
  • Is compatible to the lua reference. tan
  • Is compatible to the lua reference. tanh
  • Is compatible to the lua reference. tointeger
  • Is compatible to the lua reference. type
  • Is compatible to the lua reference. ult

Bitwise operations (bit32)

  • Is compatible to the lua reference. arshift
  • Is compatible to the lua reference. band
  • Is compatible to the lua reference. bnot
  • Is compatible to the lua reference. bor
  • Is compatible to the lua reference. btest
  • Is compatible to the lua reference. bxor
  • Is compatible to the lua reference. extract
  • Is compatible to the lua reference. replace
  • Is compatible to the lua reference. lrotate
  • Is compatible to the lua reference. lshift
  • Is compatible to the lua reference. rrotate
  • Is compatible to the lua reference. rshift

Input and output (io)

"Works only with ASCII files. The file-handle uses the IDisposable-Pattern."

  • Is compatible to the lua reference. close
  • Is compatible to the lua reference. flush
  • Is compatible to the lua reference. input
  • Is compatible to the lua reference. lines
  • Is compatible to the lua reference. open
  • Is compatible to the lua reference. output
  • Is compatible to the lua reference. popen
  • Is compatible to the lua reference. read
  • Is compatible to the lua reference. tmpfile
  • Not full compatible to the lua reference. tmpfilenew Creates a temporary file, that is deleted, when it is closed.
  • Is compatible to the lua reference. type
  • Is compatible to the lua reference. write
  • Is compatible to the lua reference. :close
  • Is compatible to the lua reference. :flush
  • Is compatible to the lua reference. :lines
  • Is compatible to the lua reference. :read
  • Is compatible to the lua reference. :seek
  • Is compatible to the lua reference. :setvbuf Ignored.
  • Is compatible to the lua reference. :write

Operating system facilities (os)

  • Is compatible to the lua reference. clock Returns TotalProcessorTime in seconds.
  • Is compatible to the lua reference. date
  • Is compatible to the lua reference. difftime
  • Is compatible to the lua reference. execute On windows is no signal-result.
  • Is compatible to the lua reference. exit
  • Is compatible to the lua reference. getenv
  • Is compatible to the lua reference. remove
  • Is compatible to the lua reference. rename
  • Not implemented. Yet. setlocale
  • Is compatible to the lua reference. time
  • Is compatible to the lua reference. tmpname

Debug facilities (debug)

  • Not implemented. Yet. debug
  • Not implemented. Yet. getuservalue
  • Not implemented. Yet. gethook
  • Not implemented. Yet. getinfo
  • Not implemented. Yet. getlocal
  • Not implemented. Yet. getmetatable
  • Not implemented. Yet. getregistry
  • Is compatible to the lua reference. getupvalue Works on closures and classes.
  • Not implemented. Yet. setuservalue
  • Not implemented. Yet. sethook
  • Not implemented. Yet. setlocal
  • Not implemented. Yet. setmetatable
  • Is compatible to the lua reference. setupvalue Works on closures and classes.
  • Not implemented. Yet. traceback
  • Not full compatible to the lua reference. upvalueid Do not trust the returned integer. The return value is only good for comparison.
  • Not full compatible to the lua reference. upvaluejoin Only works on closures (Lambda's). For example, the upvalues of the function that is returned by load are not join-able.