<feed xmlns='http://www.w3.org/2005/Atom'>
<title>catch3/projects/SelfTest/IntrospectiveTests/String.tests.cpp, branch constexpr_approx</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>Move tests from projects/ to tests/</title>
<updated>2019-12-05T15:00:20+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2019-12-05T15:00:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=0fea081ad1a678b379182930a3ec22a3e275dbf0'/>
<id>0fea081ad1a678b379182930a3ec22a3e275dbf0</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Rewrite includes in tests to use library's include paths</title>
<updated>2019-12-02T11:23:10+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2019-12-02T11:23:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=90e2549cecc2e886d563b7a88e752c9b4104f798'/>
<id>90e2549cecc2e886d563b7a88e752c9b4104f798</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Fixing paths in SelfTest</title>
<updated>2019-11-30T16:41:17+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2019-11-30T16:41:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=443fa0fc8878f4e270ae4f64331ee52b70722fe1'/>
<id>443fa0fc8878f4e270ae4f64331ee52b70722fe1</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Cleanup tests for C++20</title>
<updated>2019-11-04T12:08:10+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2019-11-04T09:42:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=eabb8a6af71e549928b598cdedfa323c35c3c527'/>
<id>eabb8a6af71e549928b598cdedfa323c35c3c527</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Rework StringRef interface and internals</title>
<updated>2019-10-25T11:57:52+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2019-10-21T15:44:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=50cc14c94c972fc743afca92b22ad7bdc63c429a'/>
<id>50cc14c94c972fc743afca92b22ad7bdc63c429a</id>
<content type='text'>
Now it no longer tries to be this weird hybrid between an owning
and non-owning reference, and is only ever non-owning. This is also
reflected in its interface, for example `StringRef::isNullTerminated`
is now public, and `StringRef::c_str()` has the precondition that it
is true.

Overview of the changes:
* The `StringRef::m_data` member has been completely removed, as it
had no more uses.
* `StringRef::isSubstring()` has been made public and renamed to
`StringRef::isNullTerminated()`, so that the name reflects what the
method actually does.
* `StringRef::currentData()` has been renamed to `StringRef::data()`,
to be in line with common C++ containers and container-alikes.
* `StringRef::c_str()` will no longer silently make copies. It instead
has a precondition that `isNullTerminated()` is true.
* If the user needs a null-terminated string, they should use the
`std::string` conversion operator and call `c_str()` on the resulting
`std::string`.
* Some small optimizations in various places.
* Basic functionality is now `constexpr`.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Now it no longer tries to be this weird hybrid between an owning
and non-owning reference, and is only ever non-owning. This is also
reflected in its interface, for example `StringRef::isNullTerminated`
is now public, and `StringRef::c_str()` has the precondition that it
is true.

Overview of the changes:
* The `StringRef::m_data` member has been completely removed, as it
had no more uses.
* `StringRef::isSubstring()` has been made public and renamed to
`StringRef::isNullTerminated()`, so that the name reflects what the
method actually does.
* `StringRef::currentData()` has been renamed to `StringRef::data()`,
to be in line with common C++ containers and container-alikes.
* `StringRef::c_str()` will no longer silently make copies. It instead
has a precondition that `isNullTerminated()` is true.
* If the user needs a null-terminated string, they should use the
`std::string` conversion operator and call `c_str()` on the resulting
`std::string`.
* Some small optimizations in various places.
* Basic functionality is now `constexpr`.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add test for past-the-end substr on StringRef</title>
<updated>2019-09-08T19:07:21+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2019-09-08T19:04:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=dab0296b64483034d7b802a0635fae840ba31727'/>
<id>dab0296b64483034d7b802a0635fae840ba31727</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Make StringRef's operator std::string explicit</title>
<updated>2019-09-08T13:58:10+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2019-09-08T12:49:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=7b865daccc7bba2dcc25a4f0b9ea7348b1b4d61f'/>
<id>7b865daccc7bba2dcc25a4f0b9ea7348b1b4d61f</id>
<content type='text'>
This way it is explicit when there is a `StringRef` -&gt; `std::string`
conversion and makes it easier to look for allocations that could
be avoided.

Doing this has already removed one allocation per registered test
case, as there was a completely pointless `StringRef` -&gt; `std::string`
conversion when parsing tags of a test case.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This way it is explicit when there is a `StringRef` -&gt; `std::string`
conversion and makes it easier to look for allocations that could
be avoided.

Doing this has already removed one allocation per registered test
case, as there was a completely pointless `StringRef` -&gt; `std::string`
conversion when parsing tags of a test case.
</pre>
</div>
</content>
</entry>
<entry>
<title>Split out the rest of string manipulation tests</title>
<updated>2019-09-07T18:22:36+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2019-09-07T18:22:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=6da00c1b64b0826bdc735805a65c7dd2147fdf2b'/>
<id>6da00c1b64b0826bdc735805a65c7dd2147fdf2b</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove the ill-considered StringRef::numberOfCharacters</title>
<updated>2019-09-07T18:13:22+00:00</updated>
<author>
<name>Martin Hořeňovský</name>
</author>
<published>2019-09-07T18:13:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=fe967b1f4122a67ae1b31febf26cf1751917a0eb'/>
<id>fe967b1f4122a67ae1b31febf26cf1751917a0eb</id>
<content type='text'>
It never counted characters, only codepoints. If you think these
are interchangeable, you should not touch non-ascii text.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It never counted characters, only codepoints. If you think these
are interchangeable, you should not touch non-ascii text.
</pre>
</div>
</content>
</entry>
<entry>
<title>StringRef no longer repoints m_start to m_data after c_str() on a substring.</title>
<updated>2019-05-20T23:04:44+00:00</updated>
<author>
<name>Phil Nash</name>
</author>
<published>2019-05-20T23:04:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.progmasoft.com/catch3/commit/?id=96355da34edf51cc813400115984050bd7c50630'/>
<id>96355da34edf51cc813400115984050bd7c50630</id>
<content type='text'>
This fixes an issue where a self-assignment of a StringRef copy would point into internally (and now dangling) data.
(now self-assignment check is no longer needed)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This fixes an issue where a self-assignment of a StringRef copy would point into internally (and now dangling) data.
(now self-assignment check is no longer needed)
</pre>
</div>
</content>
</entry>
</feed>
