Removed special treatment of -property switch

This commit is contained in:
Alexey Prokhin
2012-02-14 20:00:09 +04:00
parent 6687a6624b
commit 8282153738
4 changed files with 5 additions and 9 deletions

View File

@@ -207,7 +207,7 @@ struct Param
ubyte warnings; // enable warnings
ubyte Dversion; // D version number
bool ignoreUnsupportedPragmas; // rather than error on them
char enforcePropertySyntax;
bool enforcePropertySyntax;
char *argv0; // program name
Strings *imppath; // array of char*'s of where to look for import modules

View File

@@ -26,9 +26,10 @@ static cl::opt<bool, true> useDeprecated("d",
cl::location(global.params.useDeprecated));
#if DMDV2
cl::opt<bool> enforcePropertySyntax("property",
cl::opt<bool, true> enforcePropertySyntax("property",
cl::desc("Enforce property syntax"),
cl::ZeroOrMore);
cl::ZeroOrMore,
cl::location(global.params.enforcePropertySyntax));
#endif
static cl::opt<ubyte, true> useDv1(

View File

@@ -20,7 +20,7 @@ namespace opts {
extern cl::list<std::string> runargs;
extern cl::opt<bool> compileOnly;
#if DMDV2
extern cl::opt<bool> enforcePropertySyntax;
extern cl::opt<bool, true> enforcePropertySyntax;
#endif
extern cl::opt<bool> createStaticLib;
extern cl::opt<bool> createSharedLib;

View File

@@ -219,11 +219,6 @@ int main(int argc, char** argv)
printf("config %s\n", path.c_str());
}
// enforcePropertySyntax handled separately because it is a char
#if DMDV2
global.params.enforcePropertySyntax = enforcePropertySyntax ? 1 : 0;
#endif
// Negated options
global.params.link = !compileOnly;
global.params.obj = !dontWriteObj;