@@ -731,6 +731,30 @@ TEST_CASE(
731731 REQUIRE (test.sent_commands == expected_commands);
732732}
733733
734+ TEST_CASE (
735+ " smt2_incremental_decision_proceduret function pointer support." ,
736+ " [core][smt2_incremental]" )
737+ {
738+ auto test = decision_procedure_test_environmentt::make ();
739+ const code_typet function_type{{}, void_type ()};
740+ const symbolt function{" opaque" , function_type, ID_C};
741+ test.symbol_table .insert (function);
742+ const address_of_exprt function_pointer{function.symbol_expr ()};
743+ const equal_exprt equals_null{
744+ function_pointer, null_pointer_exprt{pointer_typet{function_type, 32 }}};
745+
746+ test.sent_commands .clear ();
747+ test.procedure .set_to (equals_null, false );
748+
749+ const std::vector<smt_commandt> expected_commands{
750+ smt_assert_commandt{smt_core_theoryt::make_not (smt_core_theoryt::equal (
751+ smt_bit_vector_theoryt::concat (
752+ smt_bit_vector_constant_termt{2 , 8 },
753+ smt_bit_vector_constant_termt{0 , 24 }),
754+ smt_bit_vector_constant_termt{0 , 32 }))}};
755+ REQUIRE (test.sent_commands == expected_commands);
756+ }
757+
734758TEST_CASE (
735759 " smt2_incremental_decision_proceduret multi-ary with_exprt introduces "
736760 " correct number of indexes." ,
0 commit comments