Skip to content

Commit 1f198d4

Browse files
committed
Fixed ambiguity in mem_fun.
Goto_programt received an additional insert_before in a recent commit. This made this reference to it ambiguous. Fixed using a static_cast.
1 parent 09de035 commit 1f198d4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/cegis/cegis-util/program_helper.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -348,8 +348,8 @@ goto_programt::targett insert_after_preserving_source_location(
348348
goto_programt::targett insert_before_preserving_source_location(
349349
goto_programt &body, goto_programt::targett pos)
350350
{
351-
const auto op=std::bind1st(std::mem_fun(&goto_programt::insert_before),
352-
&body);
351+
typedef goto_programt::targett(goto_programt::*ftype)(goto_programt::targett);
352+
const auto op=std::bind1st(std::mem_fun(static_cast<ftype>(&goto_programt::insert_before)), &body);
353353
return insert_preserving_source_location(pos, op);
354354
}
355355

0 commit comments

Comments
 (0)