public ScriptMetadataGenerator(TextWriter writer, IMetadataCompilerOptions options, SymbolSet symbols) { Debug.Assert(writer != null); Writer = new ScriptTextWriter(writer); Options = options; this.symbols = symbols; }
private bool Compile() { IMetadataCompilerOptions options = CreateOptions(out ITaskItem scriptTaskItem); scripts.Add(scriptTaskItem); MetadataCompiler compiler = new MetadataCompiler(this); return(compiler.Compile(options) && !hasErrors); }
public bool Compile(IMetadataCompilerOptions options) { this.options = options ?? throw new ArgumentNullException(nameof(options)); if (options.DebugMode) { Debugger.Launch(); } hasErrors = false; symbols = new SymbolSet(); symbols.ScriptName = options.AssemblyName; ScriptReferenceProvider.Instance.Reset(); ImportMetadata(); GenerateMetadata(); if (hasErrors) { return(false); } return(true); }