Skip to content

Commit ec7e041

Browse files
committed
Revert "Check all struct members for possible need for renaming"
This reverts commit 480f19e.
1 parent ea539ed commit ec7e041

File tree

3 files changed

+2
-47
lines changed

3 files changed

+2
-47
lines changed

regression/cbmc/vla1/main.c

Lines changed: 0 additions & 30 deletions
This file was deleted.

regression/cbmc/vla1/test.desc

Lines changed: 0 additions & 8 deletions
This file was deleted.

src/goto-symex/goto_symex_state.cpp

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -618,9 +618,6 @@ void goto_symex_statet::rename_address(
618618
}
619619
}
620620

621-
/// Return true if, and only if, the \p type or one of its subtypes requires SSA
622-
/// renaming. Renaming is necessary when symbol expressions occur within the
623-
/// type, which is the case for arrays of non-constant size.
624621
static bool requires_renaming(const typet &type, const namespacet &ns)
625622
{
626623
if(type.id() == ID_array)
@@ -638,12 +635,8 @@ static bool requires_renaming(const typet &type, const namespacet &ns)
638635
for(auto &component : components)
639636
{
640637
// be careful, or it might get cyclic
641-
if(
642-
component.type().id() != ID_pointer &&
643-
requires_renaming(component.type(), ns))
644-
{
645-
return true;
646-
}
638+
if(component.type().id() != ID_pointer)
639+
return requires_renaming(component.type(), ns);
647640
}
648641

649642
return false;

0 commit comments

Comments
 (0)