MCPcopy Create free account
hub / github.com/andreasfertig/cppinsights / main

Function main

tests/LambdaImplicitCaptureTest.cpp:3–11  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1#include <cstdio>
2
3int main()
4{
5 int x = 22;
6
7 auto z = [x]() mutable { ++x; return x; } ();
8
9 // we expext x: 22, z: 23
10 printf("x: %d z: %d\n", x, z);
11}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected