Skip to content
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

copy constructors for exception classes #8391

Merged
merged 1 commit into from
Sep 12, 2024
Merged

Conversation

kroening
Copy link
Member

C++11 15.1 §5 requires that objects that are thrown have an accessible copy/move constructor and a destructor.

This adds an explicit copy constructor to a few classes where the compiler cannot build the default copy constructor.

  • 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).
  • 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.

C++11 15.1 §5 requires that objects that are thrown have an accessible
copy/move constructor and a destructor.

This adds an explicit copy constructor to a few classes where the compiler
cannot build the default copy constructor.
@kroening kroening marked this pull request as ready for review July 20, 2024 13:47
Copy link

codecov bot commented Jul 20, 2024

Codecov Report

Attention: Patch coverage is 50.00000% with 3 lines in your changes missing coverage. Please review.

Project coverage is 78.32%. Comparing base (2523f2c) to head (00690d0).
Report is 76 commits behind head on develop.

Files with missing lines Patch % Lines
src/solvers/smt2/smt2_tokenizer.h 33.33% 2 Missing ⚠️
src/util/typecheck.h 66.66% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #8391      +/-   ##
===========================================
- Coverage    78.32%   78.32%   -0.01%     
===========================================
  Files         1726     1726              
  Lines       188506   188525      +19     
  Branches     18249    18249              
===========================================
+ Hits        147646   147654       +8     
- Misses       40860    40871      +11     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Collaborator

@tautschnig tautschnig left a comment

Choose a reason for hiding this comment

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

Just curious: is there some compiler warning (or compiler variant?) that we should be enabling to see these reported in CI?

@kroening
Copy link
Member Author

Just curious: is there some compiler warning (or compiler variant?) that we should be enabling to see these reported in CI?

Yes, Visual Studio issues a warning, we just didn't look at it.

@kroening kroening merged commit a29e933 into develop Sep 12, 2024
39 of 41 checks passed
@kroening kroening deleted the exception-constructors branch September 12, 2024 23:53
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.

4 participants