MCPcopy Create free account
hub / github.com/SqliteModernCpp/sqlite_modern_cpp / select

Function select

tests/std_optional.cc:18–26  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

16}
17
18void select(database& db, bool should_be_null) {
19 db << "select id,val from test" >> [&](long long, std::optional<int> val) {
20 if(should_be_null) {
21 if(val) exit(EXIT_FAILURE);
22 } else {
23 if(!val) exit(EXIT_FAILURE);
24 }
25 };
26}
27
28int main() {
29 try {

Callers 1

mainFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected