Skip to content

Commit 8e44191

Browse files
author
Daniel Kroening
committed
use proper constructor for code_expressiont
1 parent 47f5405 commit 8e44191

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/goto-programs/remove_function_pointers.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -420,9 +420,8 @@ void remove_function_pointerst::remove_function_pointer(
420420

421421
// We preserve the original dereferencing to possibly catch
422422
// further pointer-related errors.
423-
code_expressiont code_expression;
423+
code_expressiont code_expression(function);
424424
code_expression.add_source_location()=function.source_location();
425-
code_expression.expression()=function;
426425
target->code.swap(code_expression);
427426
target->type=OTHER;
428427

0 commit comments

Comments
 (0)