From c42bd6eeaafef7dc1c196032ebb290a243568d08 Mon Sep 17 00:00:00 2001 From: Joao Matos Date: Wed, 1 Feb 2017 18:19:51 +0000 Subject: [PATCH] Rename the OutputDebug option to GenerateDebugOutput and document it. --- src/Generator/Generators/CLI/CLITemplate.cs | 2 +- src/Generator/Generators/CSharp/CSharpSources.cs | 2 +- src/Generator/Options.cs | 7 ++++++- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/Generator/Generators/CLI/CLITemplate.cs b/src/Generator/Generators/CLI/CLITemplate.cs index ac0cdef4..8f9dd2b6 100644 --- a/src/Generator/Generators/CLI/CLITemplate.cs +++ b/src/Generator/Generators/CLI/CLITemplate.cs @@ -143,7 +143,7 @@ namespace CppSharp.Generators.CLI public void GenerateDebug(Declaration decl) { - if (Options.OutputDebug && !String.IsNullOrWhiteSpace(decl.DebugText)) + if (Options.GenerateDebugOutput && !string.IsNullOrWhiteSpace(decl.DebugText)) WriteLine("// DEBUG: " + decl.DebugText); } diff --git a/src/Generator/Generators/CSharp/CSharpSources.cs b/src/Generator/Generators/CSharp/CSharpSources.cs index 60c89dfb..53dc2c1e 100644 --- a/src/Generator/Generators/CSharp/CSharpSources.cs +++ b/src/Generator/Generators/CSharp/CSharpSources.cs @@ -383,7 +383,7 @@ namespace CppSharp.Generators.CSharp public void GenerateDebug(Declaration decl) { - if (Options.OutputDebug && !string.IsNullOrWhiteSpace(decl.DebugText)) + if (Options.GenerateDebugOutput && !string.IsNullOrWhiteSpace(decl.DebugText)) WriteLine("// DEBUG: " + decl.DebugText); } diff --git a/src/Generator/Options.cs b/src/Generator/Options.cs index 3be38d9e..fc01a7c4 100644 --- a/src/Generator/Options.cs +++ b/src/Generator/Options.cs @@ -34,7 +34,6 @@ namespace CppSharp /// Set to true to enable quiet output mode. /// public bool Quiet; - public bool OutputDebug; /// /// Set to true to enable verbose output mode. @@ -97,6 +96,12 @@ namespace CppSharp public bool GenerateInternalImports; public bool UseHeaderDirectories; + /// + /// If set to true, the generated code will be generated with extra + /// debug output. + /// + public bool GenerateDebugOutput; + /// /// If set to true the CLI generator will use ObjectOverridesPass to create /// Equals, GetHashCode and (if the insertion operator << is overloaded) ToString