File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
src/main/java/api/messages Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -58,6 +58,11 @@ public interface MultiPiece {
5858 public static class Piece implements MultiPiece {
5959 private String text ;
6060 private GoblintLocation loc ;
61+ private context context ;
62+
63+ public static class context {
64+ private Integer tag ;
65+ }
6166
6267 /**
6368 * Converts the Single (Piece type of) Goblint messages from the
@@ -70,7 +75,8 @@ public static class Piece implements MultiPiece {
7075 */
7176 public List <AnalysisResult > convert (List <Tag > tags , String severity , boolean explode ) {
7277 GoblintPosition pos = getLocation (loc );
73- String msg = joinTags (tags ) + " " + text ;
78+ String ctx = context == null || context .tag == null ? "" : " in context " + context .tag ;
79+ String msg = joinTags (tags ) + " " + text + ctx ;
7480 GoblintMessagesAnalysisResult result = new GoblintMessagesAnalysisResult (pos , msg , severity );
7581 return List .of (result );
7682 }
You can’t perform that action at this time.
0 commit comments