Skip to content

Commit b67ae26

Browse files
author
thk123
committed
Add can_cast_type for symbol_typet
1 parent 9981fab commit b67ae26

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/util/std_types.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,12 @@ inline symbol_typet &to_symbol_type(typet &type)
151151
return static_cast<symbol_typet &>(type);
152152
}
153153

154+
template <>
155+
inline bool can_cast_type<symbol_typet>(const typet &type)
156+
{
157+
return type.id() == ID_symbol;
158+
}
159+
154160
/*! \brief Base type of C structs and unions, and C++ classes
155161
*/
156162
class struct_union_typet:public typet

0 commit comments

Comments
 (0)