39 references to Default
Microsoft.CodeAnalysis.CSharp.Scripting.UnitTests (3)
ScriptOptionsTests.cs (3)
22
var options = ScriptOptions.
Default
.WithLanguageVersion(LanguageVersion.CSharp8);
29
var options = ScriptOptions.
Default
.WithLanguageVersion(LanguageVersion.CSharp8);
36
var options = ScriptOptions.
Default
.WithParseOptions(new VisualBasicParseOptions(kind: SourceCodeKind.Script, languageVersion: VisualBasic.LanguageVersion.Latest));
Microsoft.CodeAnalysis.InteractiveHost (1)
Interactive\Core\InteractiveHost.Service.cs (1)
134
scriptOptions: ScriptOptions.
Default
.WithMetadataResolver(new ScriptMetadataResolver(referenceResolver)),
Microsoft.CodeAnalysis.Scripting (1)
Script.cs (1)
57
return new Script<T>(compiler, new ScriptBuilder(assemblyLoaderOpt ?? new InteractiveAssemblyLoader()), sourceText, optionsOpt ?? ScriptOptions.
Default
, globalsTypeOpt, previousOpt: null);
Microsoft.CodeAnalysis.Scripting.TestUtilities (1)
ScriptTestBase.cs (1)
37
ScriptOptions = ScriptOptions.
Default
Microsoft.CodeAnalysis.Scripting.UnitTests (32)
ScriptOptionsTests.cs (32)
25
var options = ScriptOptions.
Default
.
40
var options = ScriptOptions.
Default
.WithReferences(ImmutableArray<MetadataReference>.Empty);
63
var empty = ScriptOptions.
Default
.WithReferences(ImmutableArray<MetadataReference>.Empty);
82
var options = ScriptOptions.
Default
.WithReferences(ImmutableArray<MetadataReference>.Empty);
106
var options = ScriptOptions.
Default
.
120
var options = ScriptOptions.
Default
;
141
var options = ScriptOptions.
Default
;
162
var scriptOptions = ScriptOptions.
Default
.WithImports(["System", "System.IO"]);
170
Assert.True(ScriptOptions.
Default
.WithEmitDebugInformation(true).EmitDebugInformation);
171
Assert.False(ScriptOptions.
Default
.WithEmitDebugInformation(false).EmitDebugInformation);
172
Assert.False(ScriptOptions.
Default
.EmitDebugInformation);
178
var options = ScriptOptions.
Default
.WithEmitDebugInformation(true);
185
var options = ScriptOptions.
Default
.WithFileEncoding(Encoding.ASCII);
192
var options = ScriptOptions.
Default
.WithFileEncoding(Encoding.ASCII);
199
Assert.True(ScriptOptions.
Default
.WithAllowUnsafe(true).AllowUnsafe);
200
Assert.False(ScriptOptions.
Default
.WithAllowUnsafe(false).AllowUnsafe);
201
Assert.True(ScriptOptions.
Default
.AllowUnsafe);
209
var options = ScriptOptions.
Default
.WithAllowUnsafe(allowUnsafe);
218
var scriptOptions = ScriptOptions.
Default
.WithAllowUnsafe(allowUnsafe);
226
Assert.True(ScriptOptions.
Default
.WithCheckOverflow(true).CheckOverflow);
227
Assert.False(ScriptOptions.
Default
.WithCheckOverflow(false).CheckOverflow);
228
Assert.False(ScriptOptions.
Default
.CheckOverflow);
236
var options = ScriptOptions.
Default
.WithCheckOverflow(checkOverflow);
245
var scriptOptions = ScriptOptions.
Default
.WithCheckOverflow(checkOverflow);
255
Assert.Equal(ScriptOptions.
Default
.WithOptimizationLevel(optimizationLevel).OptimizationLevel, optimizationLevel);
256
Assert.Equal(OptimizationLevel.Debug, ScriptOptions.
Default
.OptimizationLevel);
264
var options = ScriptOptions.
Default
.WithOptimizationLevel(optimizationLevel);
273
var scriptOptions = ScriptOptions.
Default
.WithOptimizationLevel(optimizationLevel);
286
Assert.Equal(ScriptOptions.
Default
.WithWarningLevel(warningLevel).WarningLevel, warningLevel);
287
Assert.Equal(4, ScriptOptions.
Default
.WarningLevel);
298
var options = ScriptOptions.
Default
.WithWarningLevel(warningLevel);
310
var scriptOptions = ScriptOptions.
Default
.WithWarningLevel(warningLevel);
Microsoft.CodeAnalysis.VisualBasic.Scripting.UnitTests (1)
ScriptTests.vb (1)
77
Assert.Empty(ScriptOptions.
Default
.Imports)