Skip to content

DefExc: unit tests use polymorphic equality #1686

Closed
@michael-schwarz

Description

@michael-schwarz

While looking at #1536, I replaced

  let of_excl_list t l =
    let r = size t in (* elements in l are excluded from the full range of t! *)
    `Excluded (List.fold_right S.add l (S.empty ()), r)

with

  let of_excl_list t l =
    let r = size t in (* elements in l are excluded from the full range of t! *)
    `Excluded (S.of_list l, r)

in defExcDomain.ml. This causes the following test failure

File "tests/unit/cdomains/intDomainTest.ml", line 184, characters 1-1:
Error: :0:intDomainTest:5:test_meet (in the code).

expected: Not {0, 1}([-63,63]) but got: Not {0, 1}([-63,63])
------------------------------------------------------------------------------

This strikes me as a problem in the tests, it should not matter how the set is constructed.

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions