Esempio n. 1
0
        void RunTransformsAndGenerateCode(AstBuilder astBuilder, ITextOutput output, DecompilationOptions options, ModuleDefinition module)
        {
            astBuilder.RunTransformations(transformAbortCondition);
            if (options.DecompilerSettings.ShowXmlDocumentation)
            {
                AddXmlDocTransform.Run(astBuilder.CompilationUnit);
            }
            var unit             = astBuilder.CompilationUnit.AcceptVisitor(new CSharpToCppConverterVisitor(new ILSpyEnvironmentProvider()), null);
            var outputFormatter  = new CppTextOutputFormatter(output);
            var formattingPolicy = new CppFormattingOptions();

            unit.AcceptVisitor(new CppOutputVisitor(outputFormatter, formattingPolicy), null);
        }
Esempio n. 2
0
 void RunTransformsAndGenerateCode(AstBuilder astBuilder, ITextOutput output, DecompilationOptions options, ModuleDefinition module)
 {
     astBuilder.RunTransformations(transformAbortCondition);
     if (options.DecompilerSettings.ShowXmlDocumentation)
         AddXmlDocTransform.Run(astBuilder.CompilationUnit);
     var unit = astBuilder.CompilationUnit.AcceptVisitor(new CSharpToCppConverterVisitor(new ILSpyEnvironmentProvider()), null);
     var outputFormatter = new CppTextOutputFormatter(output);
     var formattingPolicy = new CppFormattingOptions();
     unit.AcceptVisitor(new CppOutputVisitor(outputFormatter, formattingPolicy), null);
 }