We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents c55b4a5 + 4f74896 commit e6ceb91Copy full SHA for e6ceb91
src/goto-programs/json_goto_trace.cpp
@@ -114,16 +114,12 @@ void convert(
114
if(expr.id() == ID_symbol)
115
{
116
const symbolt &symbol = ns.lookup(expr.get(ID_identifier));
117
- // Don't break sharing unless need to write to it
118
- const irept::named_subt &comments =
119
- static_cast<const exprt &>(expr).get_comments();
120
- if(comments.count(ID_C_base_name) != 0)
+ if(expr.find(ID_C_base_name).is_not_nil())
121
INVARIANT(
122
- comments.at(ID_C_base_name).id() == symbol.base_name,
+ expr.find(ID_C_base_name).id() == symbol.base_name,
123
"base_name comment does not match symbol's base_name");
124
else
125
- expr.get_comments().emplace(
126
- ID_C_base_name, irept(symbol.base_name));
+ expr.add(ID_C_base_name, irept(symbol.base_name));
127
}
128
129
};
0 commit comments