New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expr possible #337

Merged
merged 2 commits into from Mar 17, 2016

Conversation

Projects
None yet
2 participants
@commial
Member

commial commented Mar 17, 2016

Introduce possible_values, which outs the possible values of an Expr associated with its constraints.

For instance:

possible_values(
# ((cond1?(0x1,0x2))+(cond2?(0x3,0x4))
  Expr...
)
(0x2+0x3) with constraints:
    <cond2 != 0>
    <cond1 == 0>
(0x2+0x4) with constraints:
    <cond1 == 0>
    <cond2 == 0>
(0x1+0x4) with constraints:
    <cond1 != 0>
    <cond2 == 0>
(0x1+0x3) with constraints:
    <cond1 != 0>
    <cond2 != 0>

Thanks to @serpilliere

commial added some commits Mar 17, 2016

Introduce `possible_values` helper
Retrieve values of an Expr with their associated constraint. Thanks to
@serpilliere

serpilliere added a commit that referenced this pull request Mar 17, 2016

@serpilliere serpilliere merged commit 22e01a8 into cea-sec:master Mar 17, 2016

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@commial commial deleted the commial:expr_possible branch Mar 17, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment