summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorEugen Wissner <belka@caraus.de>2018-03-04 10:43:24 +0100
committerEugen Wissner <belka@caraus.de>2018-03-04 10:43:24 +0100
commitb795267e758a3ba4cd0967d83ec113b57c36491e (patch)
treea8887e2176b79b19c19c7a5620bd4cedc92c65b9 /source
parent81cbb96d4563a7b8ec25b28681979076adb973e4 (diff)
downloadtanya-b795267e758a3ba4cd0967d83ec113b57c36491e.tar.gz
Rename ErrorCode.text() to toString()
Diffstat (limited to 'source')
-rw-r--r--source/tanya/os/error.d6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/tanya/os/error.d b/source/tanya/os/error.d
index aac553f..bc4a008 100644
--- a/source/tanya/os/error.d
+++ b/source/tanya/os/error.d
@@ -388,7 +388,7 @@ struct ErrorCode
*
* Returns: String describing the error number.
*/
- string text() const @nogc nothrow pure @safe
+ string toString() const @nogc nothrow pure @safe
{
foreach (e; __traits(allMembers, ErrorNo))
{
@@ -404,13 +404,13 @@ struct ErrorCode
@nogc nothrow pure @safe unittest
{
ErrorCode ec = ErrorCode.fault;
- assert(ec.text == "An invalid pointer address detected");
+ assert(ec.toString() == "An invalid pointer address detected");
}
@nogc nothrow pure @safe unittest
{
ErrorCode ec = cast(ErrorCode.ErrorNo) -1;
- assert(ec.text is null);
+ assert(ec.toString() is null);
}
private ErrorNo value_ = ErrorNo.success;