diff --git a/std/algorithm.d b/std/algorithm.d index 5100c4202..ad31a00f7 100644 --- a/std/algorithm.d +++ b/std/algorithm.d @@ -4799,8 +4799,8 @@ unittest { debug(std_algorithm) scope(success) writeln("unittest @", __FILE__, ":", __LINE__, " done."); - string h = "/homes/aalexand/d/dmd/bin/../lib/libphobos.a(dmain2.o)" - "(.gnu.linkonce.tmain+0x74): In function `main' undefined reference" + string h = "/homes/aalexand/d/dmd/bin/../lib/libphobos.a(dmain2.o)"~ + "(.gnu.linkonce.tmain+0x74): In function `main' undefined reference"~ " to `_Dmain':"; string[] ns = ["libphobos", "function", " undefined", "`", ":"]; foreach (n ; ns) { @@ -7008,7 +7008,7 @@ minCount(alias pred = "a < b", Range)(Range range) alias RetType = Tuple!(T, size_t); static assert (is(typeof(RetType(range.front, 1))), - format("Error: Cannot call minCount on a %s, because it is not possible " + format("Error: Cannot call minCount on a %s, because it is not possible "~ "to copy the result value (a %s) into a Tuple.", Range.stringof, T.stringof)); enforce(!range.empty, "Can't count elements from an empty range"); @@ -7071,7 +7071,7 @@ minCount(alias pred = "a < b", Range)(Range range) } else static assert(false, - format("Sorry, can't find the minCount of a %s: Don't know how " + format("Sorry, can't find the minCount of a %s: Don't know how "~ "to keep track of the smallest %s element.", Range.stringof, T.stringof)); } @@ -10389,7 +10389,7 @@ bool isSorted(alias less = "a < b", Range)(Range r) if (isForwardRange!(Range)) if (!binaryFun!less(r[i + 1], r[i])) continue; assert( !binaryFun!less(r[i], r[i + 1]), - text("Predicate for isSorted is not antisymmetric. Both" + text("Predicate for isSorted is not antisymmetric. Both", " pred(a, b) and pred(b, a) are true for a=", r[i], " and b=", r[i+1], " in positions ", i, " and ", i + 1)); @@ -10408,7 +10408,7 @@ bool isSorted(alias less = "a < b", Range)(Range r) if (isForwardRange!(Range)) // Check for antisymmetric predicate assert( !binaryFun!less(r.front, ahead.front), - text("Predicate for isSorted is not antisymmetric. Both" + text("Predicate for isSorted is not antisymmetric. Both", " pred(a, b) and pred(b, a) are true for a=", r.front, " and b=", ahead.front, " in positions ", i, " and ", i + 1)); diff --git a/std/bitmanip.d b/std/bitmanip.d index 8144cbf0c..202c08a06 100644 --- a/std/bitmanip.d +++ b/std/bitmanip.d @@ -103,7 +103,7 @@ private template createAccessors( { // getter enum result = "@property @safe "~T.stringof~" "~name~"() pure nothrow const { auto result = " - "("~store~" & " + ~"("~store~" & " ~ myToString(maskAllElse) ~ ") >>" ~ myToString(offset) ~ ";" ~ (T.min < 0 @@ -116,9 +116,9 @@ private template createAccessors( ~"assert(v >= "~name~"_min); " ~"assert(v <= "~name~"_max); " ~store~" = cast(typeof("~store~"))" - " (("~store~" & ~cast(typeof("~store~"))"~myToString(maskAllElse)~")" - " | ((cast(typeof("~store~")) v << "~myToString(offset)~")" - " & "~myToString(maskAllElse)~"));}\n" + ~" (("~store~" & ~cast(typeof("~store~"))"~myToString(maskAllElse)~")" + ~" | ((cast(typeof("~store~")) v << "~myToString(offset)~")" + ~" & "~myToString(maskAllElse)~"));}\n" // constants ~"enum "~T.stringof~" "~name~"_min = cast("~T.stringof~")" ~myToString(minVal)~"; " diff --git a/std/concurrency.d b/std/concurrency.d index 6335e5301..ba88b15d4 100644 --- a/std/concurrency.d +++ b/std/concurrency.d @@ -626,7 +626,7 @@ private void _send(T...)( MsgType type, Tid tid, T vals ) void receive(T...)( T ops ) in { - assert(mbox !is null, "Cannot receive a message until a thread was spawned " + assert(mbox !is null, "Cannot receive a message until a thread was spawned "~ "or thisTid was passed to a running thread."); } body @@ -708,7 +708,7 @@ private template receiveOnlyRet(T...) receiveOnlyRet!(T) receiveOnly(T...)() in { - assert(mbox !is null, "Cannot receive a message until a thread was spawned " + assert(mbox !is null, "Cannot receive a message until a thread was spawned "~ "or thisTid was passed to a running thread."); } body @@ -775,7 +775,7 @@ unittest bool receiveTimeout(T...)( Duration duration, T ops ) in { - assert(mbox !is null, "Cannot receive a message until a thread was spawned " + assert(mbox !is null, "Cannot receive a message until a thread was spawned "~ "or thisTid was passed to a running thread."); } body diff --git a/std/conv.d b/std/conv.d index 35156646d..ad866d948 100644 --- a/std/conv.d +++ b/std/conv.d @@ -2403,7 +2403,7 @@ Target parse(Target, Source)(ref Source p) { case '-': sexp++; goto case; case '+': p.popFront(); enforce(!p.empty, - new ConvException("Error converting input" + new ConvException("Error converting input"~ " to floating point")); break; default: {} @@ -2421,7 +2421,7 @@ Target parse(Target, Source)(ref Source p) ndigits = 1; } exp += (sexp) ? -e : e; - enforce(ndigits, new ConvException("Error converting input" + enforce(ndigits, new ConvException("Error converting input"~ " to floating point")); if (msdec) diff --git a/std/csv.d b/std/csv.d index 45744118f..da4a032a6 100644 --- a/std/csv.d +++ b/std/csv.d @@ -396,7 +396,7 @@ auto csvReader(Contents = string, // Test standard iteration over input. unittest { - string str = `one,"two ""quoted"""` ~ "\n\"three\nnew line\",""\nfive,six"; + string str = `one,"two ""quoted"""` ~ "\n\"three\nnew line\",\nfive,six"; auto records = csvReader(str); int count; @@ -700,7 +700,7 @@ unittest return text[0]; } } - auto ir = InputRange("Name,Occupation,Salary\r"d + auto ir = InputRange("Name,Occupation,Salary\r"d~ "Joe,Carpenter,300000\nFred,Blacksmith,400000\r\n"d); foreach(record; csvReader(ir, cast(string[])null)) @@ -1178,7 +1178,7 @@ public: if(_input.rowLength != 0) if(_input.col != _input.rowLength) throw new CSVException( - format("Row %s's length %s does not match " + format("Row %s's length %s does not match "~ "previous length of %s.", _input.row, _input.col, _input.rowLength)); return; @@ -1187,7 +1187,7 @@ public: if(_input.rowLength != 0) if(_input.col > _input.rowLength) throw new CSVException( - format("Row %s's length %s does not match " + format("Row %s's length %s does not match "~ "previous length of %s.", _input.row, _input.col, _input.rowLength)); } diff --git a/std/digest/crc.d b/std/digest/crc.d index c900eb90b..112a2e15f 100644 --- a/std/digest/crc.d +++ b/std/digest/crc.d @@ -296,7 +296,7 @@ unittest digest = crc32Of("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"); assert(digest == cast(ubyte[])x"d2e6c21f"); - digest = crc32Of("1234567890123456789012345678901234567890" + digest = crc32Of("1234567890123456789012345678901234567890"~ "1234567890123456789012345678901234567890"); assert(digest == cast(ubyte[])x"724aa97c"); diff --git a/std/digest/digest.d b/std/digest/digest.d index 9f4b65c6d..46f28e0e8 100644 --- a/std/digest/digest.d +++ b/std/digest/digest.d @@ -883,7 +883,7 @@ class WrapperDigest(T) if(isDigest!T) : Digest } body { - enum string msg = "Buffer needs to be at least " ~ digestLength!(T).stringof ~ " bytes " + enum string msg = "Buffer needs to be at least " ~ digestLength!(T).stringof ~ " bytes " ~ "big, check " ~ typeof(this).stringof ~ ".length!"; asArray!(digestLength!T)(buf, msg) = _digest.finish(); return buf[0 .. digestLength!T]; @@ -919,7 +919,7 @@ class WrapperDigest(T) if(isDigest!T) : Digest } body { - enum string msg = "Buffer needs to be at least " ~ digestLength!(T).stringof ~ " bytes " + enum string msg = "Buffer needs to be at least " ~ digestLength!(T).stringof ~ " bytes " ~ "big, check " ~ typeof(this).stringof ~ ".length!"; asArray!(digestLength!T)(buf, msg) = _digest.peek(); return buf[0 .. digestLength!T]; diff --git a/std/digest/md.d b/std/digest/md.d index 9f4dcbdd8..571022bb8 100644 --- a/std/digest/md.d +++ b/std/digest/md.d @@ -467,7 +467,7 @@ unittest digest = md5Of("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"); assert(digest == cast(ubyte[])x"d174ab98d277d9f5a5611c2c9f419d9f"); - digest = md5Of("1234567890123456789012345678901234567890" + digest = md5Of("1234567890123456789012345678901234567890"~ "1234567890123456789012345678901234567890"); assert(digest == cast(ubyte[])x"57edf4a22be3c955ac49da2e2107b67a"); diff --git a/std/digest/ripemd.d b/std/digest/ripemd.d index 67d471efe..27211233e 100644 --- a/std/digest/ripemd.d +++ b/std/digest/ripemd.d @@ -629,7 +629,7 @@ unittest digest = ripemd160Of("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"); assert(digest == cast(ubyte[])x"b0e20b6e3116640286ed3a87a5713079b21f5189"); - digest = ripemd160Of("1234567890123456789012345678901234567890" + digest = ripemd160Of("1234567890123456789012345678901234567890"~ "1234567890123456789012345678901234567890"); assert(digest == cast(ubyte[])x"9b752e45573d4b39f4dbd3323cab82bf63326bfb"); diff --git a/std/digest/sha.d b/std/digest/sha.d index f7c418051..838f77605 100644 --- a/std/digest/sha.d +++ b/std/digest/sha.d @@ -528,7 +528,7 @@ unittest digest = sha1Of("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"); assert(digest == cast(ubyte[])x"761c457bf73b14d27e9e9265c46f4b4dda11f940"); - digest = sha1Of("1234567890123456789012345678901234567890" + digest = sha1Of("1234567890123456789012345678901234567890"~ "1234567890123456789012345678901234567890"); assert(digest == cast(ubyte[])x"50abf5706a150990a08b2c5ea40fa0e585554732"); diff --git a/std/encoding.d b/std/encoding.d index fd6b0b0c8..2a262ca7e 100644 --- a/std/encoding.d +++ b/std/encoding.d @@ -819,9 +819,9 @@ template EncoderInstance(CharType : Windows1252Char) } immutable wstring charMap = - "\u20AC\uFFFD\u201A\u0192\u201E\u2026\u2020\u2021" - "\u02C6\u2030\u0160\u2039\u0152\uFFFD\u017D\uFFFD" - "\uFFFD\u2018\u2019\u201C\u201D\u2022\u2103\u2014" + "\u20AC\uFFFD\u201A\u0192\u201E\u2026\u2020\u2021"~ + "\u02C6\u2030\u0160\u2039\u0152\uFFFD\u017D\uFFFD"~ + "\uFFFD\u2018\u2019\u201C\u201D\u2022\u2103\u2014"~ "\u02DC\u2122\u0161\u203A\u0153\uFFFD\u017E\u0178" ; @@ -2463,7 +2463,7 @@ class EncodingSchemeASCII : EncodingScheme "ISO_646.irv:1991", "US-ASCII", "cp367", - "csASCII" + "csASCII", "iso-ir-6", "us" ]; diff --git a/std/exception.d b/std/exception.d index 3287c22f2..1ac7b3096 100644 --- a/std/exception.d +++ b/std/exception.d @@ -410,11 +410,11 @@ unittest "delegate void() " ~ (EncloseSafe ? "@safe " : "") ~ (EnclosePure ? "pure " : "") ~ - "{ ""enforce(true, { " + "{ enforce(true, { " ~ "int n; " ~ (BodySafe ? "" : "auto p = &n + 10; " ) ~ // unsafe code (BodyPure ? "" : "static int g; g = 10; ") ~ // impure code - "}); " + "}); " ~ "}"; enum expect = (BodySafe || !EncloseSafe) && (!EnclosePure || BodyPure); diff --git a/std/internal/math/biguintx86.d b/std/internal/math/biguintx86.d index 60c944f9c..c02f6a52e 100644 --- a/std/internal/math/biguintx86.d +++ b/std/internal/math/biguintx86.d @@ -139,7 +139,7 @@ L_unrolled: ~ indexedLoopUnroll( 8, "mov EAX, [@*4-8*4+EDX+ECX*4];" ~ ( op == '+' ? "adc" : "sbb" ) ~ " EAX, [@*4-8*4+ESI+ECX*4];" - "mov [@*4-8*4+EDI+ECX*4], EAX;") + ~ "mov [@*4-8*4+EDI+ECX*4], EAX;") ~ "}"); asm { setc AL; // save carry @@ -156,7 +156,7 @@ L_residual: ~ indexedLoopUnroll( 1, "mov EAX, [@*4+EDX+ECX*4];" ~ ( op == '+' ? "adc" : "sbb" ) ~ " EAX, [@*4+ESI+ECX*4];" - "mov [@*4+EDI+ECX*4], EAX;") ~ "}"); + ~ "mov [@*4+EDI+ECX*4], EAX;") ~ "}"); asm { setc AL; // save carry add ECX, 1; diff --git a/std/math.d b/std/math.d index 2945ce733..f47859325 100644 --- a/std/math.d +++ b/std/math.d @@ -162,14 +162,14 @@ version(LittleEndian) { static assert(real.mant_dig == 53 || real.mant_dig==64 || real.mant_dig == 113, - "Only 64-bit, 80-bit, and 128-bit reals" + "Only 64-bit, 80-bit, and 128-bit reals"~ " are supported for LittleEndian CPUs"); } else { static assert(real.mant_dig == 53 || real.mant_dig==106 || real.mant_dig == 113, - "Only 64-bit and 128-bit reals are supported for BigEndian CPUs." + "Only 64-bit and 128-bit reals are supported for BigEndian CPUs."~ " double-double reals have partial support"); } diff --git a/std/net/curl.d b/std/net/curl.d index 1d4c1889d..c9e884e06 100644 --- a/std/net/curl.d +++ b/std/net/curl.d @@ -3748,7 +3748,7 @@ struct Curl { _onReceiveHeader = (in char[] od) { - throwOnStopped("Receive header callback called on " + throwOnStopped("Receive header callback called on "~ "cleaned up Curl instance"); callback(od); }; @@ -3866,7 +3866,7 @@ struct Curl { _onSocketOption = (curl_socket_t sock, CurlSockType st) { - throwOnStopped("Socket option callback called on " + throwOnStopped("Socket option callback called on "~ "cleaned up Curl instance"); return callback(sock, st); }; @@ -3908,7 +3908,7 @@ struct Curl { _onProgress = (size_t dlt, size_t dln, size_t ult, size_t uln) { - throwOnStopped("Progress callback called on cleaned " + throwOnStopped("Progress callback called on cleaned "~ "up Curl instance"); return callback(dlt, dln, ult, uln); }; @@ -4186,9 +4186,9 @@ private static size_t _receiveAsyncLines(Terminator, Unit) // onReceive. Can be up to a max of 4 bytes. enforceEx!CurlException(data.length <= 4, format( - "Too many bytes left not decoded %s" - " > 4. Maybe the charset specified in" - " headers does not match " + "Too many bytes left not decoded %s"~ + " > 4. Maybe the charset specified in"~ + " headers does not match "~ "the actual content downloaded?", data.length)); leftOverBytes ~= data; diff --git a/std/net/isemail.d b/std/net/isemail.d index 225644de9..d9baaebef 100644 --- a/std/net/isemail.d +++ b/std/net/isemail.d @@ -229,7 +229,7 @@ EmailStatus isEmail (Char) (const(Char)[] email, CheckDns checkDNS = CheckDns.no break; default: - throw new Exception("More text found where none is allowed, but unrecognised prior " + throw new Exception("More text found where none is allowed, but unrecognised prior " ~ "context: " ~ to!(string)(contextPrior)); } } @@ -345,7 +345,7 @@ EmailStatus isEmail (Char) (const(Char)[] email, CheckDns checkDNS = CheckDns.no break; default: - throw new Exception("More text found where none is allowed, but unrecognised prior " + throw new Exception("More text found where none is allowed, but unrecognised prior " ~ "context: " ~ to!(string)(contextPrior)); } @@ -851,19 +851,19 @@ unittest // EmailStatusCode.any).statusCode == EmailStatusCode.dnsWarningNoRecord); // DNS check is currently not implemented - assert(`abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghiklm@abcdefghijklmnopqrstuvwxyz` - `abcdefghijklmnopqrstuvwxyzabcdefghikl.abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghikl.` - `abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghij`.isEmail(CheckDns.no, + assert((`abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghiklm@abcdefghijklmnopqrstuvwxyz`~ + `abcdefghijklmnopqrstuvwxyzabcdefghikl.abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghikl.`~ + `abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghij`).isEmail(CheckDns.no, EmailStatusCode.any).statusCode == EmailStatusCode.rfc5322TooLong); - assert(`a@abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghikl.abcdefghijklmnopqrstuvwxyz` - `abcdefghijklmnopqrstuvwxyzabcdefghikl.abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghikl.` - `abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefg.hij`.isEmail(CheckDns.no, + assert((`a@abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghikl.abcdefghijklmnopqrstuvwxyz`~ + `abcdefghijklmnopqrstuvwxyzabcdefghikl.abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghikl.`~ + `abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefg.hij`).isEmail(CheckDns.no, EmailStatusCode.any).statusCode == EmailStatusCode.rfc5322TooLong); - assert(`a@abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghikl.abcdefghijklmnopqrstuvwxyz` - `abcdefghijklmnopqrstuvwxyzabcdefghikl.abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghikl.` - `abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefg.hijk`.isEmail(CheckDns.no, + assert((`a@abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghikl.abcdefghijklmnopqrstuvwxyz`~ + `abcdefghijklmnopqrstuvwxyzabcdefghikl.abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghikl.`~ + `abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefg.hijk`).isEmail(CheckDns.no, EmailStatusCode.any).statusCode == EmailStatusCode.rfc5322DomainTooLong); assert(`"test"@iana.org`.isEmail(CheckDns.no, EmailStatusCode.any).statusCode == @@ -1000,7 +1000,7 @@ unittest EmailStatusCode.foldingWhitespace, `Folding whitespace`); assert("\u000D\u000A \u000D\u000A test@iana.org".isEmail(CheckDns.no, EmailStatusCode.any).statusCode == - EmailStatusCode.deprecatedFoldingWhitespace, `FWS with one line composed entirely of WSP` + EmailStatusCode.deprecatedFoldingWhitespace, `FWS with one line composed entirely of WSP`~ ` -- only allowed as obsolete FWS (someone might allow only non-obsolete FWS)`); assert(`(comment)test@iana.org`.isEmail(CheckDns.no, EmailStatusCode.any).statusCode == EmailStatusCode.comment); @@ -1025,21 +1025,21 @@ unittest assert(`test@(comment)abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghikl.com`.isEmail(CheckDns.no, EmailStatusCode.any).statusCode == EmailStatusCode.deprecatedCommentFoldingWhitespaceNearAt); - assert(`(comment)test@abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghik.abcdefghijklmnopqrstuvwxyz` - `abcdefghijklmnopqrstuvwxyzabcdefghik.abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijk.` - `abcdefghijklmnopqrstuvwxyzabcdefghijk.abcdefghijklmnopqrstu`.isEmail(CheckDns.no, + assert((`(comment)test@abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghik.abcdefghijklmnopqrstuvwxyz`~ + `abcdefghijklmnopqrstuvwxyzabcdefghik.abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijk.`~ + `abcdefghijklmnopqrstuvwxyzabcdefghijk.abcdefghijklmnopqrstu`).isEmail(CheckDns.no, EmailStatusCode.any).statusCode == EmailStatusCode.comment); assert("test@iana.org\u000A".isEmail(CheckDns.no, EmailStatusCode.any).statusCode == EmailStatusCode.errorExpectingText); assert(`test@xn--hxajbheg2az3al.xn--jxalpdlp`.isEmail(CheckDns.no, EmailStatusCode.any).statusCode == - EmailStatusCode.valid, `A valid IDN from ICANN's ` + EmailStatusCode.valid, `A valid IDN from ICANN's `~ `IDN TLD evaluation gateway`); assert(`xn--test@iana.org`.isEmail(CheckDns.no, EmailStatusCode.any).statusCode == EmailStatusCode.valid, - `RFC 3490: "unless the email standards are revised to invite the use of IDNA for local parts, a domain label` - ` that holds the local part of an email address SHOULD NOT begin with the ACE prefix, and even if it does,` + `RFC 3490: "unless the email standards are revised to invite the use of IDNA for local parts, a domain label`~ + ` that holds the local part of an email address SHOULD NOT begin with the ACE prefix, and even if it does,`~ ` it is to be interpreted literally as a local part that happens to begin with the ACE prefix"`); assert(`test@iana.org-`.isEmail(CheckDns.no, EmailStatusCode.any).statusCode == @@ -1179,7 +1179,7 @@ unittest EmailStatusCode.foldingWhitespace, `FWS`); assert("test@iana.org\u000D\u000A \u000D\u000A ".isEmail(CheckDns.no, EmailStatusCode.any).statusCode == - EmailStatusCode.deprecatedFoldingWhitespace, `FWS with one line composed entirely of WSP -- ` + EmailStatusCode.deprecatedFoldingWhitespace, `FWS with one line composed entirely of WSP -- `~ `only allowed as obsolete FWS (someone might allow only non-obsolete FWS)`); assert("test@iana.org\u000D\u000A".isEmail(CheckDns.no, EmailStatusCode.any).statusCode == @@ -1316,13 +1316,13 @@ string statusCodeDescription (EmailStatusCode statusCode) case EmailStatusCode.dnsWarning: return "Address is valid but a DNS check was not successful"; case EmailStatusCode.rfc5321: return "Address is valid for SMTP but has unusual elements"; - case EmailStatusCode.cFoldingWhitespace: return "Address is valid within the message but cannot be used" + case EmailStatusCode.cFoldingWhitespace: return "Address is valid within the message but cannot be used"~ " unmodified for the envelope"; - case EmailStatusCode.deprecated_: return "Address contains deprecated elements but may still be valid in" + case EmailStatusCode.deprecated_: return "Address contains deprecated elements but may still be valid in"~ " restricted contexts"; - case EmailStatusCode.rfc5322: return "The address is only valid according to the broad definition of RFC 5322." + case EmailStatusCode.rfc5322: return "The address is only valid according to the broad definition of RFC 5322."~ " It is otherwise invalid"; case EmailStatusCode.any: return ""; @@ -1334,7 +1334,7 @@ string statusCodeDescription (EmailStatusCode statusCode) case EmailStatusCode.valid: return "Address is valid"; // Address is valid but a DNS check was not successful - case EmailStatusCode.dnsWarningNoMXRecord: return "Could not find an MX record for this domain but an A-record" + case EmailStatusCode.dnsWarningNoMXRecord: return "Could not find an MX record for this domain but an A-record"~ " does exist"; case EmailStatusCode.dnsWarningNoRecord: return "Could not find an MX record or an A-record for this domain"; @@ -1342,13 +1342,13 @@ string statusCodeDescription (EmailStatusCode statusCode) // Address is valid for SMTP but has unusual elements case EmailStatusCode.rfc5321TopLevelDomain: return "Address is valid but at a Top Level Domain"; - case EmailStatusCode.rfc5321TopLevelDomainNumeric: return "Address is valid but the Top Level Domain begins" + case EmailStatusCode.rfc5321TopLevelDomainNumeric: return "Address is valid but the Top Level Domain begins"~ " with a number"; case EmailStatusCode.rfc5321QuotedString: return "Address is valid but contains a quoted string"; case EmailStatusCode.rfc5321AddressLiteral: return "Address is valid but at a literal address not a domain"; - case EmailStatusCode.rfc5321IpV6Deprecated: return "Address is valid but contains a :: that only elides one" + case EmailStatusCode.rfc5321IpV6Deprecated: return "Address is valid but contains a :: that only elides one"~ " zero group"; @@ -1359,7 +1359,7 @@ string statusCodeDescription (EmailStatusCode statusCode) // Address contains deprecated elements but may still be valid in restricted contexts case EmailStatusCode.deprecatedLocalPart: return "The local part is in a deprecated form"; - case EmailStatusCode.deprecatedFoldingWhitespace: return "Address contains an obsolete form of" + case EmailStatusCode.deprecatedFoldingWhitespace: return "Address contains an obsolete form of"~ " Folding White Space"; case EmailStatusCode.deprecatedQuotedText: return "A quoted string contains a deprecated character"; @@ -1367,11 +1367,11 @@ string statusCodeDescription (EmailStatusCode statusCode) case EmailStatusCode.deprecatedComment: return "Address contains a comment in a position that is deprecated"; case EmailStatusCode.deprecatedCommentText: return "A comment contains a deprecated character"; - case EmailStatusCode.deprecatedCommentFoldingWhitespaceNearAt: return "Address contains a comment or" + case EmailStatusCode.deprecatedCommentFoldingWhitespaceNearAt: return "Address contains a comment or"~ " Folding White Space around the @ sign"; // The address is only valid according to the broad definition of RFC 5322 - case EmailStatusCode.rfc5322Domain: return "Address is RFC 5322 compliant but contains domain characters that" + case EmailStatusCode.rfc5322Domain: return "Address is RFC 5322 compliant but contains domain characters that"~ " are not allowed by DNS"; case EmailStatusCode.rfc5322TooLong: return "Address is too long"; @@ -1380,7 +1380,7 @@ string statusCodeDescription (EmailStatusCode statusCode) case EmailStatusCode.rfc5322LabelTooLong: return "The domain part contains an element that is too long"; case EmailStatusCode.rfc5322DomainLiteral: return "The domain literal is not a valid RFC 5321 address literal"; - case EmailStatusCode.rfc5322DomainLiteralObsoleteText: return "The domain literal is not a valid RFC 5321" + case EmailStatusCode.rfc5322DomainLiteralObsoleteText: return "The domain literal is not a valid RFC 5321"~ " address literal and it contains obsolete characters"; case EmailStatusCode.rfc5322IpV6GroupCount: @@ -1407,7 +1407,7 @@ string statusCodeDescription (EmailStatusCode statusCode) case EmailStatusCode.errorTextAfterQuotedString: return "Address contains text after a quoted string"; - case EmailStatusCode.errorTextAfterDomainLiteral: return "Extra characters were found after the end of" + case EmailStatusCode.errorTextAfterDomainLiteral: return "Extra characters were found after the end of"~ " the domain literal"; case EmailStatusCode.errorExpectingQuotedPair: diff --git a/std/parallelism.d b/std/parallelism.d index 674fd54ee..d827032c9 100644 --- a/std/parallelism.d +++ b/std/parallelism.d @@ -1662,7 +1662,7 @@ public: alias args[0..$ - 1] args2; alias Args[0..$ - 1] Args2; enforce(buf.length == len, - text("Can't use a user supplied buffer that's the wrong " + text("Can't use a user supplied buffer that's the wrong ", "size. (Expected :", len, " Got: ", buf.length)); } else static if(randAssignable!(Args[$ - 1]) && Args.length > 1) diff --git a/std/random.d b/std/random.d index 05c7146c4..ce394fd22 100644 --- a/std/random.d +++ b/std/random.d @@ -621,7 +621,7 @@ Parameter for the generator. mti = n; if(range.empty && j < n) { - throw new Exception(format("MersenneTwisterEngine.seed: Input range didn't provide enough" + throw new Exception(format("MersenneTwisterEngine.seed: Input range didn't provide enough"~ " elements: Need %s elemnets.", n)); } diff --git a/std/range.d b/std/range.d index f70a0f73f..88db6c9aa 100644 --- a/std/range.d +++ b/std/range.d @@ -2941,15 +2941,15 @@ if (Rs.length > 1 && allSatisfy!(isInputRange, staticMap!(Unqual, Rs))) static string makeSwitchIncrementCounter() { string result = - "auto next = _current == Rs.length - 1 ? 0 : _current + 1;\n" + "auto next = _current == Rs.length - 1 ? 0 : _current + 1;\n"~ "switch (next) {\n"; foreach (i, R; Rs) { auto si = to!string(i); auto si_1 = to!string(i ? i - 1 : Rs.length - 1); - result ~= "case "~si~": " - "if (!source["~si~"].empty) { _current = "~si~"; return; }\n" - "if ("~si~" == _current) { _current = _current.max; return; }\n" + result ~= "case "~si~": "~ + "if (!source["~si~"].empty) { _current = "~si~"; return; }\n"~ + "if ("~si~" == _current) { _current = _current.max; return; }\n"~ "goto case "~to!string((i + 1) % Rs.length)~";\n"; } return result ~ "default: assert(0); }"; diff --git a/std/regex.d b/std/regex.d index c466e3a72..706919ba4 100644 --- a/std/regex.d +++ b/std/regex.d @@ -6845,16 +6845,16 @@ unittest TestVectors( `[-+*/\p{in-mathematical-operators}]{2}`, "a+\u2212", "y", "$&", "+\u2212"), TestVectors( `\p{Ll}+`, "XabcD", "y", "$&", "abc"), TestVectors( `\p{Lu}+`, "абвГДЕ", "y", "$&", "ГДЕ"), - TestVectors( `^\p{Currency Symbol}\p{Sc}` "$₤", "y", "$&", "$₤"), - TestVectors( `\p{Common}\p{Thai}` "!ฆ", "y", "$&", "!ฆ"), + TestVectors( `^\p{Currency Symbol}\p{Sc}`, "$₤", "y", "$&", "$₤"), + TestVectors( `\p{Common}\p{Thai}`, "!ฆ", "y", "$&", "!ฆ"), TestVectors( `[\d\s]*\D`, "12 \t3\U00001680\u0F20_2", "y", "$&", "12 \t3\U00001680\u0F20_"), TestVectors( `[c-wф]фф`, "ффф", "y", "$&", "ффф"), //case insensitive: - TestVectors( `^abcdEf$`, "AbCdEF" "y", "$&", "AbCdEF", "i"), + TestVectors( `^abcdEf$`, "AbCdEF", "y", "$&", "AbCdEF", "i"), TestVectors( `Русский язык`, "рУсскИй ЯзЫк", "y", "$&", "рУсскИй ЯзЫк", "i"), TestVectors( `ⒶⒷⓒ` , "ⓐⓑⒸ", "y", "$&", "ⓐⓑⒸ", "i"), TestVectors( "\U00010400{2}", "\U00010428\U00010400 ", "y", "$&", "\U00010428\U00010400", "i"), - TestVectors( `[adzУ-Я]{4}`, "DzюА" "y", "$&", "DzЮа", "i"), + TestVectors( `[adzУ-Я]{4}`, "DzюА", "y", "$&", "DzЮа", "i"), TestVectors( `\p{L}\p{Lu}{10}`, "абвгдеЖЗИКЛ", "y", "$&", "абвгдеЖЗИКЛ", "i"), TestVectors( `(?:Dåb){3}`, "DåbDÅBdÅb", "y", "$&", "DåbDÅBdÅb", "i"), //escapes: diff --git a/std/traits.d b/std/traits.d index 5ac5cdd49..063b4e9fb 100644 --- a/std/traits.d +++ b/std/traits.d @@ -732,7 +732,7 @@ unittest static assert(fqn!(typeof(cFuncPtr)) == format("extern(C) %s function(double, string)", inner_name)); // Delegate type with qualified function type - static assert(fqn!(typeof(attrDeleg)) == format("shared(immutable(%s) " + static assert(fqn!(typeof(attrDeleg)) == format("shared(immutable(%s) "~ "delegate(ref double, scope string) nothrow @trusted shared const)", inner_name)); // Variable argument function types diff --git a/std/typecons.d b/std/typecons.d index 3b509dbc1..9f43e6c4c 100644 --- a/std/typecons.d +++ b/std/typecons.d @@ -2730,7 +2730,7 @@ template generateAssertTrap(C, func.../+[BUG 4217]+/) { static if (functionAttributes!(func) & FunctionAttribute.nothrow_) //XXX { - pragma(msg, "Warning: WhiteHole!(", C, ") used assert(0) instead " + pragma(msg, "Warning: WhiteHole!(", C, ") used assert(0) instead ", "of Error for the auto-implemented nothrow function ", C, ".", __traits(identifier, func)); enum string generateAssertTrap = diff --git a/std/uni.d b/std/uni.d index caee1872c..32dd3a25a 100644 --- a/std/uni.d +++ b/std/uni.d @@ -3767,7 +3767,7 @@ private: curIndex = idxB; // open-right } - enum errMsg = "non-monotonic prefix function(s), an unsorted range or " + enum errMsg = "non-monotonic prefix function(s), an unsorted range or "~ "duplicate key->value mapping"; public: @@ -4919,7 +4919,7 @@ else "N", "Number", "P", "Punctuation", "S", "Symbol", - "Z", "Separator" + "Z", "Separator", "Graphical", "any", "ascii" diff --git a/std/uuid.d b/std/uuid.d index 9c1c2de7c..0d68f7686 100644 --- a/std/uuid.d +++ b/std/uuid.d @@ -1475,7 +1475,7 @@ enum x500Namespace = UUID("6ba7b814-9dad-11d1-80b4-00c04fd430c8"); * writeln(found); * ------------------- */ -enum uuidRegex = r"[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}" +enum uuidRegex = "[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}"~ "-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}"; /// @@ -1484,11 +1484,11 @@ unittest import std.algorithm; import std.regex; - string test = "Lorem ipsum dolor sit amet, consetetur " - "6ba7b814-9dad-11d1-80b4-00c04fd430c8 sadipscing \n" - "elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore \r\n" - "magna aliquyam erat, sed diam voluptua. " - "8ab3060e-2cba-4f23-b74c-b52db3bdfb46 At vero eos et accusam et " + string test = "Lorem ipsum dolor sit amet, consetetur "~ + "6ba7b814-9dad-11d1-80b4-00c04fd430c8 sadipscing \n"~ + "elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore \r\n"~ + "magna aliquyam erat, sed diam voluptua. "~ + "8ab3060e-2cba-4f23-b74c-b52db3bdfb46 At vero eos et accusam et "~ "justo duo dolores et ea rebum."; auto r = regex(uuidRegex, "g"); diff --git a/std/variant.d b/std/variant.d index 315a26e56..9e80a547e 100644 --- a/std/variant.d +++ b/std/variant.d @@ -566,7 +566,7 @@ public: else static if (is(T : const(VariantN))) { static assert(false, - "Assigning Variant objects from const Variant" + "Assigning Variant objects from const Variant"~ " objects is currently not supported."); } else diff --git a/std/xml.d b/std/xml.d index 489ee95a2..c0683bfbb 100644 --- a/std/xml.d +++ b/std/xml.d @@ -2350,7 +2350,7 @@ private int n = 0; if (s.startsWith("'yes'") || s.startsWith("\"yes\"")) n = 5; else if (s.startsWith("'no'" ) || s.startsWith("\"no\"" )) n = 4; - else fail("standalone attribute value must be 'yes', \"yes\"," + else fail("standalone attribute value must be 'yes', \"yes\","~ " 'no' or \"no\""); s = s[n..$]; } @@ -2686,7 +2686,7 @@ unittest } catch(CheckException e) { - int n = e.toString().indexOf("end tag name \"genres\" differs" + int n = e.toString().indexOf("end tag name \"genres\" differs"~ " from start tag name \"genre\""); assert(n != -1); }