summaryrefslogtreecommitdiff
path: root/cpp/src/slice2cpp/Main.cpp
diff options
context:
space:
mode:
authorMark Spruiell <mes@zeroc.com>2002-01-22 21:05:19 +0000
committerMark Spruiell <mes@zeroc.com>2002-01-22 21:05:19 +0000
commitaf80ebed14a45803dede0c5c3a934a5227717ab7 (patch)
treebd5d9e6bc895e17e4da2b6912e3a24d46ecc6f66 /cpp/src/slice2cpp/Main.cpp
parentadded nillable (diff)
downloadice-af80ebed14a45803dede0c5c3a934a5227717ab7.tar.bz2
ice-af80ebed14a45803dede0c5c3a934a5227717ab7.tar.xz
ice-af80ebed14a45803dede0c5c3a934a5227717ab7.zip
adding --impl option
Diffstat (limited to 'cpp/src/slice2cpp/Main.cpp')
-rw-r--r--cpp/src/slice2cpp/Main.cpp14
1 files changed, 13 insertions, 1 deletions
diff --git a/cpp/src/slice2cpp/Main.cpp b/cpp/src/slice2cpp/Main.cpp
index 631cb029763..d8a9ea8d2a1 100644
--- a/cpp/src/slice2cpp/Main.cpp
+++ b/cpp/src/slice2cpp/Main.cpp
@@ -29,6 +29,7 @@ usage(const char* n)
"--include-dir DIR Use DIR as the header include directory.\n"
"--output-dir DIR Create files in the directory DIR.\n"
"--dll-export SYMBOL Use SYMBOL for DLL exports.\n"
+ "--impl Generate sample implementations.\n"
"-d, --debug Print debug messages.\n"
;
}
@@ -41,6 +42,7 @@ main(int argc, char* argv[])
string include;
string output;
string dllExport;
+ bool impl = false;
bool debug = false;
int idx = 1;
@@ -141,6 +143,15 @@ main(int argc, char* argv[])
}
argc -= 2;
}
+ else if (strcmp(argv[idx], "--impl") == 0)
+ {
+ impl = true;
+ for (int i = idx ; i + 1 < argc ; ++i)
+ {
+ argv[i] = argv[i + 1];
+ }
+ --argc;
+ }
else if (argv[idx][0] == '-')
{
cerr << argv[0] << ": unknown option `" << argv[idx] << "'" << endl;
@@ -214,7 +225,8 @@ main(int argc, char* argv[])
}
else
{
- Gen gen(argv[0], base, include, includePaths, dllExport, output);
+ Gen gen(argv[0], base, include, includePaths, dllExport, output,
+ impl);
if (!gen)
{
unit->destroy();