Skip to content

Commit 9c213ef

Browse files
committed
Support Visual Studio Code
1 parent a1afe01 commit 9c213ef

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@ bld/
2424
# Visual Studio 2015 cache/options directory
2525
.vs/
2626

27+
# Visual Studio Code profile directory
28+
.vscode/
29+
2730
# MSTest test Results
2831
[Tt]est[Rr]esult*/
2932
[Bb]uild[Ll]og.*

core/IncrementalCompiler/Compiler.cs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -195,8 +195,9 @@ private MetadataReference CreateReference(string file)
195195

196196
private SyntaxTree ParseSource(string file, CSharpParseOptions parseOption)
197197
{
198-
var text = File.ReadAllText(Path.Combine(_options.WorkDirectory, file));
199-
return CSharpSyntaxTree.ParseText(text, parseOption, file, Encoding.UTF8);
198+
var fileFullPath = Path.Combine(_options.WorkDirectory, file);
199+
var text = File.ReadAllText(fileFullPath);
200+
return CSharpSyntaxTree.ParseText(text, parseOption, fileFullPath, Encoding.UTF8);
200201
}
201202

202203
private void Emit(CompileResult result)
@@ -206,7 +207,9 @@ private void Emit(CompileResult result)
206207

207208
// emit to memory
208209

209-
var r = _options.DebugSymbolFile == DebugSymbolFileType.Mdb ? _compilation.EmitWithMdb(_outputDllStream, _outputDebugSymbolStream) : _compilation.Emit(_outputDllStream, _outputDebugSymbolStream);
210+
var r = _options.DebugSymbolFile == DebugSymbolFileType.Mdb
211+
? _compilation.EmitWithMdb(_outputDllStream, _outputDebugSymbolStream)
212+
: _compilation.Emit(_outputDllStream, _outputDebugSymbolStream);
210213

211214
// memory to file
212215

0 commit comments

Comments
 (0)