diff options
author | Araq <rumpf_a@web.de> | 2018-01-10 10:01:47 +0100 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2018-01-10 10:01:47 +0100 |
commit | 50fb98d2607f5473ab83f5d8293c9a243eb4d7c8 (patch) | |
tree | c75805ce238736ae06d09806bbf41c2af7137370 /tests | |
parent | 13e9f8aac1b8636c6a45b07c72fc27c1b311e824 (diff) | |
parent | a54430ea2dc7d39670e0451a04d3b9f349ae8072 (diff) | |
download | Nim-50fb98d2607f5473ab83f5d8293c9a243eb4d7c8.tar.gz |
Merge branch 'devel' of github.com:nim-lang/Nim into devel
Diffstat (limited to 'tests')
-rw-r--r-- | tests/stdlib/tstrformat.nim | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/stdlib/tstrformat.nim b/tests/stdlib/tstrformat.nim new file mode 100644 index 000000000..4e5c614a7 --- /dev/null +++ b/tests/stdlib/tstrformat.nim @@ -0,0 +1,13 @@ +discard """ + action: "run" +""" + +import strformat + +type Obj = object + +proc `$`(o: Obj): string = "foobar" + +var o: Obj +doAssert fmt"{o}" == "foobar" +doAssert fmt"{o:10}" == "foobar " \ No newline at end of file |