argcargv.i cosmetic updates

This commit is contained in:
William S Fulton 2022-05-15 18:32:53 +01:00
commit e4cdf9d98f
6 changed files with 25 additions and 32 deletions

View file

@ -1,17 +1,16 @@
/* ------------------------------------------------------------
* --- Argc & Argv ---
* ------------------------------------------------------------
*
* Use it as follow:
*
* %apply (int ARGC, char **ARGV) { (size_t argc, const char **argv) }
* extern int mainApp(size_t argc, const char **argv);
*
* then in the lua:
*
* args = { "arg0", "arg1" }
* mainApp(args);
*
* SWIG library containing argc and argv multi-argument typemaps
Use it as follows:
%apply (int ARGC, char **ARGV) { (size_t argc, const char **argv) }
extern int mainApp(size_t argc, const char **argv);
then from lua:
args = { "arg0", "arg1" }
mainApp(args);
* ------------------------------------------------------------ */
%{