Skip to content

Commit bafbb51

Browse files
authored
Merge pull request #3329 from tautschnig/vs-shadow-8
Do not shadow symbol with writable copy of it [blocks: #2310]
2 parents bdce85b + 58b0ea5 commit bafbb51

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/linking/static_lifetime_init.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -99,9 +99,9 @@ void static_lifetime_init(
9999
{
100100
// C standard 6.9.2, paragraph 5
101101
// adjust the type to an array of size 1
102-
symbolt &symbol=*symbol_table.get_writeable(identifier);
103-
symbol.type=type;
104-
symbol.type.set(ID_size, from_integer(1, size_type()));
102+
symbolt &writable_symbol = *symbol_table.get_writeable(identifier);
103+
writable_symbol.type = type;
104+
writable_symbol.type.set(ID_size, from_integer(1, size_type()));
105105
}
106106

107107
if(type.id()==ID_incomplete_struct ||

0 commit comments

Comments
 (0)