mirror of
https://github.com/dlang-community/dfmt.git
synced 2025-04-29 14:49:55 +03:00
Fix #116
This commit is contained in:
parent
c8c595bf16
commit
c291340e90
4 changed files with 24 additions and 1 deletions
|
@ -776,7 +776,7 @@ private:
|
||||||
formatAt();
|
formatAt();
|
||||||
break;
|
break;
|
||||||
case tok!"!":
|
case tok!"!":
|
||||||
if (peekIs(tok!"is"))
|
if (peekIs(tok!"is") && !(peekBackIs(tok!"(") || peekBackIs(tok!"=")))
|
||||||
write(" ");
|
write(" ");
|
||||||
goto case;
|
goto case;
|
||||||
case tok!"...":
|
case tok!"...":
|
||||||
|
|
8
tests/allman/issue0116.d.ref
Normal file
8
tests/allman/issue0116.d.ref
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
static assert(!is(T : int));
|
||||||
|
|
||||||
|
unittest
|
||||||
|
{
|
||||||
|
foo(!is(T : int));
|
||||||
|
}
|
||||||
|
|
||||||
|
enum a(T) = !is(T : int);
|
8
tests/issue0116.d
Normal file
8
tests/issue0116.d
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
static assert(!is(T : int));
|
||||||
|
|
||||||
|
unittest
|
||||||
|
{
|
||||||
|
foo(!is(T : int));
|
||||||
|
}
|
||||||
|
|
||||||
|
enum a(T) = !is(T : int);
|
7
tests/otbs/issue0116.d.ref
Normal file
7
tests/otbs/issue0116.d.ref
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
static assert(!is(T : int));
|
||||||
|
|
||||||
|
unittest {
|
||||||
|
foo(!is(T : int));
|
||||||
|
}
|
||||||
|
|
||||||
|
enum a(T) = !is(T : int);
|
Loading…
Add table
Add a link
Reference in a new issue