diff options
author | David Walter Seikel | 2014-04-03 07:44:22 +1000 |
---|---|---|
committer | David Walter Seikel | 2014-04-03 07:44:22 +1000 |
commit | ba2ba47af54c965aa06629e71a52c9418edc9828 (patch) | |
tree | f27e0c5fc6f47a4e77d6e2690f93ae4fb5fce0ca /ClientHamr | |
parent | Read in any matching .skang files in moduleBegin(). (diff) | |
download | SledjHamr-ba2ba47af54c965aa06629e71a52c9418edc9828.zip SledjHamr-ba2ba47af54c965aa06629e71a52c9418edc9828.tar.gz SledjHamr-ba2ba47af54c965aa06629e71a52c9418edc9828.tar.bz2 SledjHamr-ba2ba47af54c965aa06629e71a52c9418edc9828.tar.xz |
Detect and print LuaJIT version.
Diffstat (limited to '')
-rw-r--r-- | ClientHamr/GuiLua/skang.lua | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/ClientHamr/GuiLua/skang.lua b/ClientHamr/GuiLua/skang.lua index bd05031..20eaae9 100644 --- a/ClientHamr/GuiLua/skang.lua +++ b/ClientHamr/GuiLua/skang.lua | |||
@@ -162,10 +162,12 @@ end | |||
162 | 162 | ||
163 | -- Call this now so that from now on, this is like any other module. | 163 | -- Call this now so that from now on, this is like any other module. |
164 | local _M = moduleBegin('skang', 'David Seikel', 'Copyright 2014 David Seikel', '0.1', '2014-03-27 02:57:00') | 164 | local _M = moduleBegin('skang', 'David Seikel', 'Copyright 2014 David Seikel', '0.1', '2014-03-27 02:57:00') |
165 | -- TODO - While it is possible to get LuaJIT version info, need to load the 'jit' module, which wont work so well if we are not in LuaJIT. | 165 | -- This works coz LuaJIT automatically loads the jit module. |
166 | -- local jit = require 'jit'; jit.version; jit.version_num; jit.os; jit.arch | 166 | if type(jit) == 'table' then |
167 | print('Skang is running under Lua version ' .. _VERSION) | 167 | print('Skang is being run by ' .. jit.version .. ' under ' .. jit.os .. ' on a ' .. jit.arch) |
168 | 168 | else | |
169 | print('Skang is being run by Lua version ' .. _VERSION) | ||
170 | end | ||
169 | 171 | ||
170 | 172 | ||
171 | function printTableStart(table, space, name) | 173 | function printTableStart(table, space, name) |