You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The comments and print statement suggest that the expected behavior is as it is, but the behavior (as the comments also suggest) is undefined behavior.
There's several problems with this test:
The test fails, even though the behavior is as expected.
It's undefined behavior, so there is no guarantee what the test does.
Even if the runtime is supposed to support specific behavior when one tries to recursively init a local static, any code that contains this construct exhibits undefined behavior and is therefore already faulty.
Here's an example running the test:
$ dbt run "//libsupcxx/tests/Test05" cc-toolchain=linux-x86_64-libsupcxx
Running libsupcxx/tests/Test05:
Getting the meaning of life!
Computing the meaning of life!
Answer to the Ultimate Question of Life, the Universe, and Everything: 42
Getting the meaning of life!
Answer to the Ultimate Question of Life, the Universe, and Everything: 42
recursiveInit(0)!
recursiveInit(1)!
FAILED: libsupcxx/tests/Test05#run
The text was updated successfully, but these errors were encountered:
Test05 currently fails with a crash.
The comments and print statement suggest that the expected behavior is as it is, but the behavior (as the comments also suggest) is undefined behavior.
There's several problems with this test:
Here's an example running the test:
The text was updated successfully, but these errors were encountered: