<feed xmlns='http://www.w3.org/2005/Atom'>
<title>catch3/src/catch2/interfaces/catch_interfaces_capture.hpp, branch v3.15.3</title>
<subtitle>Progmasoft Catch3: an independently maintained C++17 test framework with a parallel runner, property checks, snapshots and structured results.</subtitle>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/'/>
<entry>
<title>Turn IResultCapture::lastAssertionPassed into a free function</title>
<updated>2026-04-07T12:33:39+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2026-04-07T11:35:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=77eae8bd2a2c8c3135d30649aa7c51b5bfc0e61e'/>
<id>77eae8bd2a2c8c3135d30649aa7c51b5bfc0e61e</id>
<content type='text'>
The thread-safety changes in assertions &amp; messages turned whether
the last assertion passed or failed into thread-local state,
instead of being member of the `RunContext`. However, this change
was not reflected in the API `CHECKED_IF`/`CHECKED_ELSE` used,
which in turn required `catch_test_macro_impl.hpp` to include
`catch_interfaces_capture.hpp` for it.

Thanks to the combination of this commit and the previous similar
commit for the message stack handling, the main include path does
not need to include `catch_interfaces_capture.hpp` anymore.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The thread-safety changes in assertions &amp; messages turned whether
the last assertion passed or failed into thread-local state,
instead of being member of the `RunContext`. However, this change
was not reflected in the API `CHECKED_IF`/`CHECKED_ELSE` used,
which in turn required `catch_test_macro_impl.hpp` to include
`catch_interfaces_capture.hpp` for it.

Thanks to the combination of this commit and the previous similar
commit for the message stack handling, the main include path does
not need to include `catch_interfaces_capture.hpp` anymore.
</pre>
</div>
</content>
</entry>
<entry>
<title>Turn IResultCapture::{push,pop}*Message into free functions</title>
<updated>2026-04-07T12:28:11+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2026-04-07T11:09:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=3ab0d7cef3313d91e652a89870c89b0c42760f9e'/>
<id>3ab0d7cef3313d91e652a89870c89b0c42760f9e</id>
<content type='text'>
The thread-safety changes in assertions &amp; messages turned the message
stacks into thread-local state, instead of it being member of `RunContext`.
The relevant {push,pop}(Un)ScopedMessage functions were turned from member
functions into static functions, but this left `catch_message.hpp` with
dependency on `IResultCapture`'s definition for the functions, and thus
it still had to include `catch_interfaces_capture.hpp`.

With this change, `catch_message.hpp` no longer needs
`catch_interfaces_capture.hpp`.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The thread-safety changes in assertions &amp; messages turned the message
stacks into thread-local state, instead of it being member of `RunContext`.
The relevant {push,pop}(Un)ScopedMessage functions were turned from member
functions into static functions, but this left `catch_message.hpp` with
dependency on `IResultCapture`'s definition for the functions, and thus
it still had to include `catch_interfaces_capture.hpp`.

With this change, `catch_message.hpp` no longer needs
`catch_interfaces_capture.hpp`.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add UNSCOPED_CAPTURE</title>
<updated>2026-01-11T13:53:08+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2026-01-08T13:35:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=2580eadc4230eedf1b66841bdd27a8aacc2412a5'/>
<id>2580eadc4230eedf1b66841bdd27a8aacc2412a5</id>
<content type='text'>
Closes #2954
Closes #3010
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Closes #2954
Closes #3010
</pre>
</div>
</content>
</entry>
<entry>
<title>Inline the `getResultCapture` helper into header.</title>
<updated>2025-09-27T11:24:46+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2025-09-23T13:23:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=756ae05d307168eaa27bd904dbd8e591a6406889'/>
<id>756ae05d307168eaa27bd904dbd8e591a6406889</id>
<content type='text'>
We still keep the error check in the function, but hide it in an
outlined function inside a .cpp file, to promote inlining of the
retrieval part.

In the future, we should explore two things

1) Skipping over the context retrieval here, allowing direct access.
   I currently do not see a way to do this while keeping the
   "greppability" of mutable vs immutable accesses that is there now,
   but it would help a lot when inlining is not enabled.
2) Removing the error check, to make the function trivially inlinable,
   and without branches.

**runtime difference**

| --------- | Debug | Release |
|:----------|------:|--------:|
| Slow path |  0.98 |    1.07 |
| Fast path |  1.04 |    1.08 |

We lost bit of performance on the assertion slow path in debug mode,
but together with the previous commit, it comes out at net zero.
For other combinations, we see 5-10% perf improvement across the
two commits.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We still keep the error check in the function, but hide it in an
outlined function inside a .cpp file, to promote inlining of the
retrieval part.

In the future, we should explore two things

1) Skipping over the context retrieval here, allowing direct access.
   I currently do not see a way to do this while keeping the
   "greppability" of mutable vs immutable accesses that is there now,
   but it would help a lot when inlining is not enabled.
2) Removing the error check, to make the function trivially inlinable,
   and without branches.

**runtime difference**

| --------- | Debug | Release |
|:----------|------:|--------:|
| Slow path |  0.98 |    1.07 |
| Fast path |  1.04 |    1.08 |

We lost bit of performance on the assertion slow path in debug mode,
but together with the previous commit, it comes out at net zero.
For other combinations, we see 5-10% perf improvement across the
two commits.
</pre>
</div>
</content>
</entry>
<entry>
<title>Make message push/pop static</title>
<updated>2025-09-23T09:46:26+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2025-09-23T09:01:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=434bf55d4727ab1d1aef244ef16823a0ed1e6b4a'/>
<id>434bf55d4727ab1d1aef244ef16823a0ed1e6b4a</id>
<content type='text'>
Since the change to make the message macros thread-safe, and thus
thread-local, there is no need to handle messages through instance
of `RunContext`.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Since the change to make the message macros thread-safe, and thus
thread-local, there is no need to handle messages through instance
of `RunContext`.
</pre>
</div>
</content>
</entry>
<entry>
<title>Move MessageInfos into the run context</title>
<updated>2025-08-26T10:37:52+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2025-08-26T10:36:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=227af796b4ede6258f9b1ff8b69cd1f03d32f662'/>
<id>227af796b4ede6258f9b1ff8b69cd1f03d32f662</id>
<content type='text'>
Together with the previous change, this means that `ScopedMessage`
only needs to keep around a single unsigned int.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Together with the previous change, this means that `ScopedMessage`
only needs to keep around a single unsigned int.
</pre>
</div>
</content>
</entry>
<entry>
<title>Use only the ID of a message when removing it from context</title>
<updated>2025-08-26T10:07:41+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2025-08-26T10:07:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=33adb4c779feaa3a98bb45ec1ebaf2864bb110b7'/>
<id>33adb4c779feaa3a98bb45ec1ebaf2864bb110b7</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove assertionPassed fast path from the capture interface</title>
<updated>2025-07-20T16:32:25+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2025-07-20T16:31:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=ce128f584c293b17362d838a8dc65bc81ffc8dff'/>
<id>ce128f584c293b17362d838a8dc65bc81ffc8dff</id>
<content type='text'>
As it is an internal helper for RunContext to speed-up handling of
succesfull assertions, I have no idea why it was added to the
interface back when it was first implemented.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As it is an internal helper for RunContext to speed-up handling of
succesfull assertions, I have no idea why it was added to the
interface back when it was first implemented.
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove superfluous include</title>
<updated>2024-09-13T14:39:55+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2024-09-13T12:43:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=e97ebe62e700dad37fe460644e121ec462e75596'/>
<id>e97ebe62e700dad37fe460644e121ec462e75596</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Avoid needless copy of string in runContext::handleMessage</title>
<updated>2024-09-13T14:39:51+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2024-09-13T11:42:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=412cad546a89cda9eaa8ef77d8161b719182cc9e'/>
<id>412cad546a89cda9eaa8ef77d8161b719182cc9e</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
