diff options
| author | Martin Hořeňovský | 2018-02-17 20:41:50 +0100 |
|---|---|---|
| committer | Martin Hořeňovský | 2018-02-17 20:41:50 +0100 |
| commit | 4e57661919e07d8f9e7fcefe73db31a96ab18867 (patch) | |
| tree | 48081c9df1ca617478e97aa0a5af6a76870d9f59 /include/internal/catch_stringref.cpp | |
| parent | 5a8f9c84dd01293eee7008097b2b29c3f9784753 (diff) | |
| download | catch3-4e57661919e07d8f9e7fcefe73db31a96ab18867.tar.gz | |
StringRef will not take ownership when writing itself to stream
This also fixes some tests that were previously failing unnoticed - WTF?
Diffstat (limited to 'include/internal/catch_stringref.cpp')
| -rw-r--r-- | include/internal/catch_stringref.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/internal/catch_stringref.cpp b/include/internal/catch_stringref.cpp index b0b2f8e1..604e8465 100644 --- a/include/internal/catch_stringref.cpp +++ b/include/internal/catch_stringref.cpp @@ -112,7 +112,7 @@ namespace Catch { } auto operator << ( std::ostream& os, StringRef const& str ) -> std::ostream& { - return os << str.c_str(); + return os.write(str.m_start, str.m_size); } } // namespace Catch |