Skip to content

Multi-operand constructor for code_ifthenelset #3504

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

Merged
merged 2 commits into from
Dec 18, 2018

Conversation

tautschnig
Copy link
Collaborator

This enables RAII rather then incremental construction.

  • Each commit message has a non-empty body, explaining why the change was made.
  • Methods or procedures I have added are documented, following the guidelines provided in CODING_STANDARD.md.
  • n/a The feature or user visible behaviour I have added or modified has been documented in the User Guide in doc/cprover-manual/
  • Regression or unit tests are included, or existing tests cover the modified code (in this case I have detailed which ones those are in the commit message).
  • n/a My commit message includes data points confirming performance improvements (if claimed).
  • My PR is restricted to a single feature or bugfix.
  • n/a White-space or formatting changes outside the feature-related changed lines are in commits of their own.

Copy link
Contributor

@allredj allredj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✔️
Passed Diffblue compatibility checks (cbmc commit: 967a422).
Build URL: https://travis-ci.com/diffblue/test-gen/builds/93291442

function_body.add(conditional);
const code_ifthenelset conditional(
init_complete.symbol_expr(), code_returnt());
function_body.add(std::move(conditional));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need for the temporary conditional any longer?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

True, but I still left it in place as the line otherwise got long-ish. But if anyone thinks it should rather be removed then I'll happily do so.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BTW, the combination of 'const' and std::move won't do anything.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

@kroening kroening assigned tautschnig and unassigned smowton Dec 15, 2018
@tautschnig tautschnig force-pushed the constructors-ifthenelse branch from 967a422 to 371c809 Compare December 17, 2018 14:26
@tautschnig tautschnig removed their assignment Dec 17, 2018
@tautschnig tautschnig force-pushed the constructors-ifthenelse branch from 371c809 to 8427934 Compare December 17, 2018 15:40
Copy link
Contributor

@allredj allredj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✔️
Passed Diffblue compatibility checks (cbmc commit: 8427934).
Build URL: https://travis-ci.com/diffblue/test-gen/builds/94994551

@tautschnig tautschnig merged commit 5f55c33 into diffblue:develop Dec 18, 2018
@tautschnig tautschnig deleted the constructors-ifthenelse branch December 18, 2018 13:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants