summaryrefslogtreecommitdiffstats
path: root/lib/tolua++/src/bin/lua/namespace.lua
diff options
context:
space:
mode:
authorJulian Laubstein <julianlaubstein@yahoo.de>2015-11-05 10:56:20 +0100
committerJulian Laubstein <julianlaubstein@yahoo.de>2015-11-05 10:56:20 +0100
commit51e5e6e9a8ed689c044256859f16f1b1f57585b7 (patch)
tree3a0d2409a61622edcc3ec5953a28fb3c13cc8705 /lib/tolua++/src/bin/lua/namespace.lua
parentMerge pull request #2601 from Gargaj/patch-1 (diff)
parentOutsourced all libraries into submodules (diff)
downloadcuberite-51e5e6e9a8ed689c044256859f16f1b1f57585b7.tar
cuberite-51e5e6e9a8ed689c044256859f16f1b1f57585b7.tar.gz
cuberite-51e5e6e9a8ed689c044256859f16f1b1f57585b7.tar.bz2
cuberite-51e5e6e9a8ed689c044256859f16f1b1f57585b7.tar.lz
cuberite-51e5e6e9a8ed689c044256859f16f1b1f57585b7.tar.xz
cuberite-51e5e6e9a8ed689c044256859f16f1b1f57585b7.tar.zst
cuberite-51e5e6e9a8ed689c044256859f16f1b1f57585b7.zip
Diffstat (limited to 'lib/tolua++/src/bin/lua/namespace.lua')
m---------lib/tolua++0
-rw-r--r--lib/tolua++/src/bin/lua/namespace.lua52
2 files changed, 0 insertions, 52 deletions
diff --git a/lib/tolua++ b/lib/tolua++
new file mode 160000
+Subproject 9181fc9ef73fa1c052f968d68dc60538f144a47
diff --git a/lib/tolua++/src/bin/lua/namespace.lua b/lib/tolua++/src/bin/lua/namespace.lua
deleted file mode 100644
index 6ca80e6e3..000000000
--- a/lib/tolua++/src/bin/lua/namespace.lua
+++ /dev/null
@@ -1,52 +0,0 @@
--- tolua: namespace class
--- Written by Waldemar Celes
--- TeCGraf/PUC-Rio
--- Jul 2003
--- $Id: $
-
--- This code is free software; you can redistribute it and/or modify it.
--- The software provided hereunder is on an "as is" basis, and
--- the author has no obligation to provide maintenance, support, updates,
--- enhancements, or modifications.
-
-
--- Namespace class
--- Represents a namesapce definition.
--- Stores the following fields:
--- name = class name
--- {i} = list of members
-classNamespace = {
- classtype = 'namespace',
- name = '',
-}
-classNamespace.__index = classNamespace
-setmetatable(classNamespace,classModule)
-
--- Print method
-function classNamespace:print (ident,close)
- print(ident.."Namespace{")
- print(ident.." name = '"..self.name.."',")
- local i=1
- while self[i] do
- self[i]:print(ident.." ",",")
- i = i+1
- end
- print(ident.."}"..close)
-end
-
--- Internal constructor
-function _Namespace (t)
- setmetatable(t,classNamespace)
- append(t)
- return t
-end
-
--- Constructor
--- Expects the name and the body of the namespace.
-function Namespace (n,b)
- local c = _Namespace(_Container{name=n})
- push(c)
- c:parse(strsub(b,2,strlen(b)-1)) -- eliminate braces
- pop()
-end
-