mirror of
https://github.com/boostorg/contract.git
synced 2026-02-27 04:52:22 +00:00
committing all decl_function stuff, before going back to virtual_
This commit is contained in:
18
test/free_function/post_post-error.cpp
Normal file
18
test/free_function/post_post-error.cpp
Normal file
@@ -0,0 +1,18 @@
|
||||
|
||||
// Test double post error (for free func, but same for all contracts).
|
||||
|
||||
#include <boost/contract/free_function.hpp>
|
||||
#include <boost/contract/var.hpp>
|
||||
|
||||
void f() {
|
||||
boost::contract::var contract = boost::contract::free_function()
|
||||
.postcondition([] {})
|
||||
.postcondition([] {}) // Error (double post).
|
||||
;
|
||||
}
|
||||
|
||||
int main() {
|
||||
f();
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user