Skip to content

Commit b459eb2

Browse files
authored
Merge pull request #3311 from tautschnig/vs-shadow-2
Do not shadow local variable type [blocks: #2310]
2 parents e31f51d + 4dac92b commit b459eb2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/util/simplify_expr_pointer.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -668,11 +668,11 @@ bool simplify_exprt::simplify_object_size(exprt &expr)
668668

669669
if(size.is_not_nil())
670670
{
671-
typet type=expr.type();
671+
const typet &expr_type = expr.type();
672672

673-
if(size.type()!=type)
673+
if(size.type() != expr_type)
674674
{
675-
size.make_typecast(type);
675+
size.make_typecast(expr_type);
676676
simplify_node(size);
677677
}
678678

0 commit comments

Comments
 (0)