diff options
author | 2014-07-09 17:29:13 -0700 | |
---|---|---|
committer | 2014-07-09 17:29:13 -0700 | |
commit | fcbf0190bcee4b0f704d4c1bc646acefaaed492c (patch) | |
tree | 52543a441f9ce2cd7691661ac4a3ce57265cc531 /Source | |
parent | 6eec3f506008f7522f9dadbc06a4e871a5faa1ae (diff) | |
parent | e6994bfa0d98f4b08722c0ee805ee01f2ce0263d (diff) |
Merge
Diffstat (limited to 'Source')
-rw-r--r-- | Source/DafnyExtension/DafnyDriver.cs | 7 | ||||
-rw-r--r-- | Source/DafnyExtension/ProgressMargin.cs | 9 |
2 files changed, 9 insertions, 7 deletions
diff --git a/Source/DafnyExtension/DafnyDriver.cs b/Source/DafnyExtension/DafnyDriver.cs index ea21f12b..8c0f3235 100644 --- a/Source/DafnyExtension/DafnyDriver.cs +++ b/Source/DafnyExtension/DafnyDriver.cs @@ -182,18 +182,19 @@ namespace DafnyLanguage class DafnyErrorInformationFactory : ErrorInformationFactory
{
- public override ErrorInformation CreateErrorInformation(IToken tok, string msg, string requestId, string category = null)
+ public override ErrorInformation CreateErrorInformation(IToken tok, string msg, string requestId, string originalRequestId, string category = null)
{
- return new DafnyErrorInformation(tok, msg, requestId, category);
+ return new DafnyErrorInformation(tok, msg, requestId, originalRequestId, category);
}
}
class DafnyErrorInformation : ErrorInformation
{
- public DafnyErrorInformation(IToken tok, string msg, string requestId, string category = null)
+ public DafnyErrorInformation(IToken tok, string msg, string requestId, string originalRequestId, string category = null)
: base(tok, msg)
{
RequestId = requestId;
+ OriginalRequestId = originalRequestId;
Category = category;
AddNestingsAsAux(tok);
}
diff --git a/Source/DafnyExtension/ProgressMargin.cs b/Source/DafnyExtension/ProgressMargin.cs index 3da47538..360ee209 100644 --- a/Source/DafnyExtension/ProgressMargin.cs +++ b/Source/DafnyExtension/ProgressMargin.cs @@ -340,13 +340,14 @@ namespace DafnyLanguage if (!_disposed)
{
errorInfo.BoogieErrorCode = null;
- if (errorInfo.RequestId != null && RequestIdToSnapshot.ContainsKey(errorInfo.RequestId))
+ var recycled = errorInfo.OriginalRequestId != requestId ? " (recycled)" : "";
+ if (errorInfo.OriginalRequestId != null && RequestIdToSnapshot.ContainsKey(errorInfo.OriginalRequestId))
{
- var s = RequestIdToSnapshot[errorInfo.RequestId];
- errorListHolder.AddError(new DafnyError(errorInfo.Tok.filename, errorInfo.Tok.line - 1, errorInfo.Tok.col - 1, ErrorCategory.VerificationError, errorInfo.FullMsg, s, errorInfo.Model.ToString(), System.IO.Path.GetFullPath(_document.FilePath) == errorInfo.Tok.filename), errorInfo.ImplementationName, requestId);
+ var s = RequestIdToSnapshot[errorInfo.OriginalRequestId];
+ errorListHolder.AddError(new DafnyError(errorInfo.Tok.filename, errorInfo.Tok.line - 1, errorInfo.Tok.col - 1, ErrorCategory.VerificationError, errorInfo.FullMsg + recycled, s, errorInfo.Model.ToString(), System.IO.Path.GetFullPath(_document.FilePath) == errorInfo.Tok.filename), errorInfo.ImplementationName, errorInfo.OriginalRequestId);
foreach (var aux in errorInfo.Aux)
{
- errorListHolder.AddError(new DafnyError(aux.Tok.filename, aux.Tok.line - 1, aux.Tok.col - 1, ErrorCategory.AuxInformation, aux.FullMsg, s, null, System.IO.Path.GetFullPath(_document.FilePath) == aux.Tok.filename), errorInfo.ImplementationName, requestId);
+ errorListHolder.AddError(new DafnyError(aux.Tok.filename, aux.Tok.line - 1, aux.Tok.col - 1, ErrorCategory.AuxInformation, aux.FullMsg, s, null, System.IO.Path.GetFullPath(_document.FilePath) == aux.Tok.filename), errorInfo.ImplementationName, errorInfo.OriginalRequestId);
}
}
}
|