Olly Betts
f5e2d044df
Remove set but not used variables
...
Highlighted by clang-15 warnings such as:
warning: variable 'index' set but not used [-Wunused-but-set-variable]
2022-06-30 12:52:37 +12:00
Olly Betts
b2c58115d7
Fix previous commit
...
Revert changes inadvertently included, and fix `=` to `==`.
2022-03-20 19:44:23 +13:00
Olly Betts
029ddab8b5
[ci] Try to fix failing appveyor python builds
2022-03-20 18:42:50 +13:00
Olly Betts
55377bdc08
Add DOH Exit() and SetExitHandler()
...
Exit() is a wrapper for exit() by default, but SetExitHandler() allows
specifying a function to call instead.
This means that failures within DOH (e.g. Malloc() failing due to lack
of memory) will now perform cleanup such as removing output files.
This commit also cleans up exit statuses so SWIG should now reliably
exit with status 0 if the run was successful and status 1 if there was
an error (or a warning and -Werror was in effect).
Previously in some situations SWIG would try to exit with the status set
to the number of errors encountered, but that's problematic - for
example if there were 256 errors this would result in exit status 0 on
most platforms. Also some error statuses have special meanings e.g.
those defined by <sysexits.h>.
Also SWIG/Javascript tried to exit with status -1 in a few places (which
typically results in exit status 255).
2022-03-06 12:33:54 +13:00
Olly Betts
b127e11f1e
Fix typos in docs and comments
2022-02-27 18:15:46 +13:00
Olly Betts
abfd630c6d
Remove comment on how to add new target lang
...
This information really doesn't belong in lua.cxx, and is covered better
in Doc/Manual/Extending.html already.
2022-02-15 10:35:17 +13:00
Olly Betts
9ddc9dceb7
Remove support for $source and $target
...
These were officially deprecated in 2001, and attempts to use them have
resulted in a warning (including a pointer to what to update them to)
for most if not all of that time.
Fixes #1984
2021-04-30 10:20:14 +12:00
Michel Zou
ee8d47cec4
Fix few unused variable warnings
2021-03-07 11:20:31 +00:00
luz.paz
6f69830321
follow-up typos
2018-05-17 10:26:00 -04:00
luz.paz
60dfa31a67
Misc. typos
...
found via `codespell` and `grep`
2018-05-17 10:04:23 -04:00
Olly Betts
90f9117e10
Fix various comment and documentation typos
2017-08-13 18:04:33 +12:00
Amarnath Valluri
08d5e19e6e
Lua: Fix possible memory leaks
...
Signed-off-by: Amarnath Valluri <amarnath.valluri@intel.com>
2016-06-16 15:51:50 +03:00
William S Fulton
1d62790928
Fix assertion for some languages when wrapping a C++11 enum class that is private in a class.
...
Also don't wrap private enums for a few languages that attempted to do so.
Closes #594 .
2016-03-31 20:27:36 +01:00
Petre Eftime
0a07cd4c30
Prevent redefinition warnings when compiling with SWIG<module> defined
...
Signed-off-by: Petre Eftime <petre.p.eftime@intel.com>
2015-12-22 14:33:21 +02:00
William S Fulton
be272ff8cd
Add c++11 strongly typed enum support for Lua
2014-11-28 07:47:45 +00:00
Olly Betts
36be36d618
Eliminate needless casting away const from string constants
2014-04-30 12:00:23 +12:00
Olly Betts
618868ce3d
Fix typos
2014-04-29 11:31:29 +12:00
Artem Serebriyskiy
c1ca144ed2
Fixed errors from previous commit.
...
Also in previous commit also fixed warning with unsigned vs signed
comparison
2014-04-23 01:48:10 +04:00
Artem Serebriyskiy
8512bad8c2
Fixing unused variable warnings
...
* Fixing unused variable warning. Generated code should compile
with -Wall -Werror flags
* Fixing forgotten __Module -> SwigModule renaming
2014-04-16 03:37:27 +04:00
Olly Betts
559128e14e
Fix typo in -lua -help output
2014-04-07 23:00:49 +12:00
William S Fulton
45256e0e9e
Lua code refactor
...
Remove the internal api code for -no-old-metatable-bindings.
The code needs to be properly based on features, not api levels.
The code/variable names now reflect the command line option controlling
it.
2014-03-20 19:51:30 +00:00
William S Fulton
703d5b96fe
Fix extern "C"
2014-03-15 02:20:38 +00:00
William S Fulton
d2dc7df061
Compiler fixes for Sun Workshop compiler
2014-03-15 02:02:40 +00:00
Artem Serebriyskiy
ddbf439db9
Working around some of the SWIG internal issues with enums
2014-03-12 18:00:15 +04:00
Artem Serebriyskiy
3028b16cee
Partially disabling old names generation for classes with nspace
2014-03-06 15:24:17 +04:00
Artem Serebriyskiy
869de3e761
Getattribute->GetFlag
2014-03-04 14:33:41 +04:00
Artem Serebriyskiy
e48dee81ea
Disable old-names generation for enums in class in namespace
2014-03-04 13:54:38 +04:00
Artem Serebriyskiy
1da65de2b7
Removing all TODO:REMOVE
2014-03-03 11:29:04 +04:00
Artem Serebriyskiy
1898099620
Fixing enums
2014-03-03 09:54:13 +04:00
Artem Serebriyskiy
cad7f86112
__Static -> SwigStatig, __Module -> SwigModule
2014-03-03 09:27:16 +04:00
Artem Serebriyskiy
23f0df2c0e
Setattr -> SetFlag
2014-03-02 20:15:09 +04:00
William S Fulton
aaa71288b1
Cosmetic changes to lua.cxx after recent changes
2014-02-28 23:15:29 +00:00
William S Fulton
d957d37636
Minor code improvements after Lua changes.
2014-02-28 19:49:53 +00:00
Artem Serebriyskiy
c6dd6b0726
Fixing registerClass. No more wrap: unnecessary attributes
2014-02-25 14:36:03 +04:00
Artem Serebriyskiy
fadc9c8f31
Fixed registerMethod to work like registerVariable
2014-02-25 14:11:53 +04:00
Artem Serebriyskiy
4a94345c9a
Switched to Swig_name_* functions
2014-02-25 12:51:28 +04:00
Artem Serebriyskiy
dac0e989e3
Options in alphabetical order
2014-02-22 19:01:48 +04:00
Artem Serebriyskiy
166b19e860
Members renaming
2014-02-22 18:26:46 +04:00
Artem Serebriyskiy
f12d8aa174
target_name -> lua_name
2014-02-22 18:06:47 +04:00
Artem Serebriyskiy
77a7069f9e
Fixing cmd options, again
2014-02-22 17:56:21 +04:00
Artem Serebriyskiy
ec629beb31
Fixing segfault
2014-02-22 15:46:22 +04:00
Artem Serebriyskiy
b30aa53709
Removed class_parent_nspace
2014-02-19 16:02:49 +04:00
Artem Serebriyskiy
2767f2a55e
Fixes to module options
2014-02-19 14:05:29 +04:00
Artem Serebriyskiy
4eef510e33
Rename methods to make it clear what 'symbols table' they operate on.
2014-02-19 13:34:50 +04:00
Artem Serebriyskiy
e6d0f1327b
Eliminating namespaces_hash and using symbols table instead
2014-02-19 13:34:49 +04:00
Artem Serebriyskiy
14452cad03
Attempt to catch unreproducable bug from Travis CI build
2014-02-19 13:34:49 +04:00
Artem Serebriyskiy
0c6263a0c2
Small bugfixes
2014-02-19 13:34:49 +04:00
Artem Serebriyskiy
705beb6753
Bugfixes for eLua. eLua emulation mode
2014-02-19 13:34:49 +04:00
Artem Serebriyskiy
0ee724ca80
Add compatibility option for old-style inheritance
2014-02-19 13:34:49 +04:00
Artem Serebriyskiy
6d49a57b53
Add support for C-style enums in C mode. And tests.
...
In backward compatible mode C style enums binding are correctly
generated
2014-02-19 13:34:49 +04:00