1 write to Arguments
Microsoft.CodeAnalysis (1)
CommandLine\CommonCompiler.cs (1)
136this.Arguments = parser.Parse(allArgs, buildPaths.WorkingDirectory, buildPaths.SdkDirectory, additionalReferenceDirectories);
86 references to Arguments
Microsoft.CodeAnalysis (69)
CommandLine\CommonCompiler.cs (69)
140this.EmbeddedSourcePaths = GetEmbeddedSourcePaths(Arguments); 216var pathResolver = new CompilerRelativePathResolver(FileSystem, Arguments.ReferencePaths, Arguments.BaseDirectory); 231Arguments.ResolveMetadataReferences(commandLineReferenceResolver, diagnostics, this.MessageProvider, resolved); 233if (Arguments.IsScriptRunner) 273return EncodedStringText.Create(data, _fallbackEncoding, Arguments.Encoding, Arguments.ChecksumAlgorithm, canBeEmbedded: EmbeddedSourcePaths.Contains(file.Path)); 278return EncodedStringText.Create(data, _fallbackEncoding, Arguments.Encoding, Arguments.ChecksumAlgorithm, canBeEmbedded: EmbeddedSourcePaths.Contains(file.Path)); 407return EmbeddedText.FromBytes(filePath, bytes, Arguments.ChecksumAlgorithm); 411return EmbeddedText.FromStream(filePath, stream, Arguments.ChecksumAlgorithm); 424if (Arguments.EmbeddedFiles.IsEmpty) 429var embeddedTreeMap = new Dictionary<string, SyntaxTree>(Arguments.EmbeddedFiles.Length); 430var embeddedFileOrderedSet = new OrderedSet<string>(Arguments.EmbeddedFiles.Select(e => e.Path)); 717Debug.Assert(Arguments.ErrorLogOptions?.Path != null); 720var errorLog = OpenFile(Arguments.ErrorLogOptions.Path, 738if (Arguments.ErrorLogOptions.SarifVersion == SarifVersion.Sarif1) 770if (Arguments.ErrorLogOptions?.Path != null) 824!Arguments.ParseOptions.HasFeature(Feature.EnableGeneratorCache) || 825string.IsNullOrWhiteSpace(Arguments.OutputFileName); 835driver ??= CreateGeneratorDriver(generatedFilesBaseDirectory, parseOptions, generators, analyzerConfigOptionsProvider, additionalTexts, Arguments.ChecksumAlgorithm); 852Debug.Assert(!string.IsNullOrWhiteSpace(Arguments.OutputFileName)); 862sb.Builder.Append(Arguments.GetOutputFilePath(Arguments.OutputFileName)); 878Debug.Assert(!Arguments.IsScriptRunner); 882if (Arguments.DisplayVersion) 888if (Arguments.DisplayLangVersions) 894if (Arguments.DisplayLogo) 899if (Arguments.DisplayHelp) 905if (ReportDiagnostics(Arguments.Errors, consoleOutput, errorLogger, compilation: null)) 917var touchedFilesLogger = (Arguments.TouchedFilesPath != null) ? new TouchedFileLogger() : null; 923if (Arguments.AnalyzerConfigPaths.Length > 0) 925if (!TryGetAnalyzerConfigSet(Arguments.AnalyzerConfigPaths, diagnostics, out analyzerConfigSet)) 933sourceFileAnalyzerConfigOptions = Arguments.SourceFiles.SelectAsArray(f => analyzerConfigSet.GetOptionsForSourcePath(f.Path)); 948ResolveAnalyzersFromArguments(diagnosticInfos, MessageProvider, compilation.Options, Arguments.SkipAnalyzers, out var analyzers, out var generators); 1010if (Arguments.ReportAnalyzer) 1015if (Arguments.ReportInternalsVisibleToAttributes) 1080if (Arguments.AnalyzerConfigPaths.Length > 0) 1164var explicitGeneratedOutDir = Arguments.GeneratedFilesOutputDirectory; 1166var baseDirectory = hasExplicitGeneratedOutDir ? explicitGeneratedOutDir! : Arguments.OutputDirectory; 1167(compilation, generatorTimingInfo) = RunGenerators(compilation, baseDirectory, Arguments.ParseOptions, generators, analyzerConfigProvider, additionalTextFiles, diagnostics); 1169bool hasAnalyzerConfigs = !Arguments.AnalyzerConfigPaths.IsEmpty; 1170var generatedSyntaxTrees = compilation.SyntaxTrees.Skip(Arguments.SourceFiles.Length).ToList(); 1260var finalPeFilePath = Arguments.GetOutputFilePath(outputName); 1261var finalPdbFilePath = Arguments.GetPdbFilePath(outputName); 1262var finalXmlFilePath = Arguments.DocumentationPath; 1269var emitOptions = Arguments.EmitOptions. 1271WithPdbFilePath(PathUtilities.NormalizePathPrefix(finalPdbFilePath, Arguments.PathMap)); 1276if (Arguments.ParseOptions.HasFeature(Feature.PdbPathDeterminism) && !string.IsNullOrEmpty(emitOptions.PdbFilePath)) 1281if (Arguments.SourceLink != null) 1284Arguments.SourceLink, 1294Arguments.SourceLink, 1300if (Arguments.ParseOptions.HasFeature(Feature.DebugDeterminism)) 1308Arguments.PathMap, 1311Arguments.ManifestResources); 1325Arguments.ManifestResources, 1341Arguments.EmitPdb, 1399using (var win32ResourceStreamOpt = GetWin32Resources(FileSystem, MessageProvider, Arguments, compilation, diagnostics)) 1460var pdbStreamProviderOpt = Arguments.EmitPdbFile ? new CompilerEmitStreamProvider(this, finalPdbFilePath) : null; 1462string? finalRefPeFilePath = Arguments.OutputRefFilePath; 1548if (Arguments.ErrorLogPath == null) 1557reportAnalyzer: Arguments.ReportAnalyzer || errorLogger != null, 1577if (Arguments.TouchedFilesPath != null) 1586string readFilesPath = Arguments.TouchedFilesPath + ".read"; 1587string writtenFilesPath = Arguments.TouchedFilesPath + ".write"; 1628foreach (var file in Arguments.AdditionalFiles) 1764return Arguments.PreferredUILang ?? CultureInfo.CurrentUICulture; 1835var filePath = Path.Combine(Arguments.OutputDirectory, Arguments.OutputFileName + ".key");
Microsoft.CodeAnalysis.CSharp (1)
CommandLine\CSharpCompiler.cs (1)
36protected internal new CSharpCommandLineArguments Arguments { get { return (CSharpCommandLineArguments)base.Arguments; } }
Microsoft.CodeAnalysis.Scripting (14)
Hosting\CommandLine\CommandLineRunner.cs (14)
56if (Compiler.Arguments.ErrorLogOptions?.Path != null) 76Debug.Assert(Compiler.Arguments.IsScriptRunner); 78var sourceFiles = Compiler.Arguments.SourceFiles; 80if (Compiler.Arguments.DisplayVersion) 86if (Compiler.Arguments.DisplayLangVersions) 92if (sourceFiles.IsEmpty && Compiler.Arguments.DisplayLogo) 96if (!Compiler.Arguments.DisplayHelp) 102if (Compiler.Arguments.DisplayHelp) 125var emitDebugInformation = !Compiler.Arguments.InteractiveMode; 128var scriptOptions = GetScriptOptions(Compiler.Arguments, scriptPathOpt, Compiler.MessageProvider, diagnosticsInfos, emitDebugInformation); 130var errors = Compiler.Arguments.Errors.Concat(diagnosticsInfos.Select(Diagnostic.Create)); 139if (Compiler.Arguments.InteractiveMode) 203globals.Args.AddRange(Compiler.Arguments.ScriptArguments); 225globals.Args.AddRange(Compiler.Arguments.ScriptArguments);
VBCSCompiler (2)
src\roslyn\src\Compilers\Server\VBCSCompiler\CompilerRequestHandler.cs (2)
143if (!AnalyzerConsistencyChecker.Check(request.WorkingDirectory, compiler.Arguments.AnalyzerReferences, AnalyzerAssemblyLoader, Logger, out List<string>? errorMessages)) 153bool utf8output = compiler.Arguments.Utf8Output;