Added CTFE-ability tests to some stuff in std.conv and std.string.

These tests are for the functionality that std.metastrings provides, and
we need to ensure that the normal functions which are replacing
those in std.metastrings continue to work in CTFE.
This commit is contained in:
jmdavis 2013-02-24 16:02:32 -08:00
parent 20e6064ea8
commit 9bd4044536
2 changed files with 17 additions and 0 deletions

View file

@ -2554,6 +2554,10 @@ unittest
assertThrown!FormatException(format("foo %s"));
assertThrown!FormatException(format("foo %s", 123, 456));
//Test CTFE-ability of format.
static assert(format("hel%slo%s%s%s", "world", -138, 'c', true) ==
"helworldlo-138ctrue", "[" ~ s ~ "]");
}