-
Notifications
You must be signed in to change notification settings - Fork 2.1k
* Redesign CompilationResult so that it does not throw when CompiledType is accessed #2045
Conversation
{ | ||
CompilationFailures = new[] { compilationFailure }; | ||
} | ||
|
||
/// <inheritdoc /> | ||
public IEnumerable<ICompilationFailure> CompilationFailures { get; } | ||
|
||
private static string FormatMessage(ICompilationFailure compilationFailure) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We changed Diagnostics \ Helios to not print compilation messages. So we can do better with showing exception messages in the debugger now.
cc @dougbu |
/// <summary> | ||
/// Creates a new instance of <see cref="CompilationResult"/>. | ||
/// Creates a new instance of <see cref="CompilationResult"/> that represents a success in compilation. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"that represents" (contains exactly two noise words) -> "for"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- and end with "a successful compilation"
- similarly, "for a failed compilation" below
⌚ |
Updated. I'll change the file names for |
private Type _type; | ||
|
||
/// <summary> | ||
// <summary> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typo: ///
|
/// </summary> | ||
public class CompilationFailure : ICompilationFailure | ||
public class RazorCompilationFailure : ICompilationFailure |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rename file too
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I could go either way on this naming. There isn't really any functionality in this class that makes this "razor" specific.
⌚ |
…ype is accessed. * Update to use ICompilationException interface from Microsoft.Framework.Runtime * Update to use RoslynCompilationException Fixes #955
Updated. |
|
Fixes #955