summaryrefslogtreecommitdiff
path: root/share/swig/2.0.11/lua/carrays.i
diff options
context:
space:
mode:
authorVince Harron <vharron@google.com>2015-06-02 18:58:48 -0700
committerVince Harron <vharron@google.com>2015-06-02 18:58:48 -0700
commitb46a6ee1ee38582dd3af57ebe1b6d5e4158c34e0 (patch)
treeb342a62eea47f607a7c0846c731bf151c1503359 /share/swig/2.0.11/lua/carrays.i
parent6c85ed3bdac5c6dd65ad8cef83fc4fc7ef99a6c9 (diff)
downloadlinux-x86-studio-1.3-dev.tar.gz
Diffstat (limited to 'share/swig/2.0.11/lua/carrays.i')
-rw-r--r--share/swig/2.0.11/lua/carrays.i8
1 files changed, 8 insertions, 0 deletions
diff --git a/share/swig/2.0.11/lua/carrays.i b/share/swig/2.0.11/lua/carrays.i
new file mode 100644
index 0000000..1bc45d8
--- /dev/null
+++ b/share/swig/2.0.11/lua/carrays.i
@@ -0,0 +1,8 @@
+/* Small change to the standard carrays.i
+renaming the field to __getitem & __setitem
+for operator[] access
+*/
+%rename(__getitem) *::getitem; // the v=X[i] (get operator)
+%rename(__setitem) *::setitem; // the X[i]=v (set operator)
+
+%include <../carrays.i>