From 5a269a5392cab37344a5c9e3f13739d2e1b3e957 Mon Sep 17 00:00:00 2001 From: Marcelo Matus Date: Wed, 4 Jan 2006 07:44:12 +0000 Subject: [PATCH] more options clean-up git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@8208 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- SWIG/CHANGES.current | 4 ++-- SWIG/Source/Modules/main.cxx | 33 ++++++++++++++++----------------- 2 files changed, 18 insertions(+), 19 deletions(-) diff --git a/SWIG/CHANGES.current b/SWIG/CHANGES.current index f2c407c5b..e1c242c05 100644 --- a/SWIG/CHANGES.current +++ b/SWIG/CHANGES.current @@ -223,7 +223,7 @@ Version 1.3.28 (unreleased). 12/29/2005: mmatus - - Add the copyctor feature/directive to enable the automatic + - Add the copyctor feature/directive/option to enable the automatic generation of copy constructors. Use as in: %copyctor A; @@ -244,7 +244,7 @@ Version 1.3.28 (unreleased). that will enable the automatic generation for all the classes. That is also equivalent to - swig -features copyctor -c++ ... + swig -copyctor -c++ ... Notes: diff --git a/SWIG/Source/Modules/main.cxx b/SWIG/Source/Modules/main.cxx index dbd549c8d..e46777c2d 100644 --- a/SWIG/Source/Modules/main.cxx +++ b/SWIG/Source/Modules/main.cxx @@ -49,15 +49,15 @@ static const char *usage1 = (const char*)"\ \nGeneral Options\n\ -c++ - Enable C++ processing\n\ -co - Check out of the SWIG library\n\ - -directors - Turn on director mode for all the classes, mainly for testing \n\ + -directors - Turn on director mode for all the classes, mainly for testing\n\ -dirprot - Turn on wrapping of protected members for director classes\n\ -D - Define a symbol (for conditional compilation)\n\ -E - Preprocess only, does not generate wrapper code\n\ - -external-runtime [file] - Export the swig runtime stack \n\ + -external-runtime [file] - Export the swig runtime stack\n\ -fcompact - Compile in compact mode\n\ - -features list - Set a list of global features, where the syntax list is \n\ - -features directors,autodoc=1 \n\ - if not explicit value is given to the feature, a '1' is used \n\ + -features list - Set a list of global features, where the syntax list is\n\ + -features directors,autodoc=1\n\ + if not explicit value is given to the feature, a '1' is used\n\ -fvirtual - Compile in virtual elimination mode\n\ -fastdispatch - Enable fast dispatch mode, which produces faster overload dispatcher code\n\ -nofastdispatch - Disable fast dispatch mode (default)\n\ @@ -72,9 +72,9 @@ static const char *usage1 = (const char*)"\ -cpperraswarn - Treat the CPP #error statement as #warning instead\n\ -nocpperraswarn - Don't treat the CPP #error statement as #warning, i.e., crash as CPP\n\ -l - Include SWIG library file \n\ - -M - List all dependencies \n\ + -M - List all dependencies\n\ -MD - Is equivalent to `-M -MF ', except `-E' is not implied\n\ - -MF - Generate dependencies into and continue generating wrappers \n\ + -MF - Generate dependencies into and continue generating wrappers\n\ -MM - List dependencies, but omit files in SWIG library\n\ -MMD - Like `-MD', but omit files in SWIG library\n\ "; @@ -82,23 +82,24 @@ static const char *usage1 = (const char*)"\ static const char *usage2 = (const char*)"\ -makedefault - Create default constructors/destructors (the default)\n\ -module - Set module name to \n\ - -nocontract - Turn off contract checking \n\ - -nodefault - Do not generate constructors, destructor or copy constructors (dangerous, don't use it)\n\ + -nocontract - Turn off contract checking\n\ + -nodefault - Do not generate default constructors nor default destructors\n\ -nodefaultctor - Do not generate implicit default constructors\n\ - -nodefaultdtor - Do not generate implicit default destructors (dangerous, use %nodefaultdtor instead)\n\ + -nodefaultdtor - Do not generate implicit default destructors\n\ + -copctor - Generate copy constructor automatically when is possible\n\ -nodirprot - Do not wrap director protected members\n\ -noexcept - Do not wrap exception specifiers\n\ -addextern - Add extra extern declarations\n\ -nopreprocess - Skip the preprocessor step\n\ - -notemplatereduce - Disable reduction of the typedefs in templates \n\ + -notemplatereduce - Disable reduction of the typedefs in templates\n\ -o - Set name of the output file to \n\ -oh - Set name of the output header file to \n\ -outdir - Set language specific files output directory\n\ -small - Compile in virtual elimination & compact mode\n\ -swiglib - Report location of SWIG library and exit\n\ - -templatereduce - Reduce all the typedefs in templates \n\ + -templatereduce - Reduce all the typedefs in templates\n\ -v - Run in verbose mode\n\ - -fakeversion - Make swig to fake a different version \n\ + -fakeversion - Make swig to fake a different version\n\ -version - Print SWIG version number\n\ -Wall - Enable all warning messages\n\ -Wallkw - Enable keyword warnings for all the supported languages\n\ @@ -478,11 +479,9 @@ void SWIG_getoptions(int argc, char *argv[]) } else if ((strcmp(argv[i],"-nodefaultdtor") == 0)) { SWIG_setfeature("feature:nodefaultdtor","1"); Swig_mark_arg(i); -#if 0 - } else if ((strcmp(argv[i],"-nocopyctor") == 0)) { - SWIG_setfeature("feature:nocopyctor","1"); + } else if ((strcmp(argv[i],"-copyctor") == 0)) { + SWIG_setfeature("feature:copyctor","1"); Swig_mark_arg(i); -#endif } else if (strcmp(argv[i],"-noexcept") == 0) { NoExcept = 1; Swig_mark_arg(i);