repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
MATCH: Improve `A CMP 0 ? A : -A` set of patterns to use bitwise_equal_p.
[official-gcc.git]
/
gcc
/
testsuite
/
gdc.test
/
fail_compilation
/
test19176.d
blob
ceceb74c9cba20b61084cac712c2e67bc7575f4c
1
/*
2
REQUIRED_ARGS: -unittest
3
TEST_OUTPUT:
4
---
5
fail_compilation/test19176.d(13): Error: argument `foo()` to __traits(getUnitTests) must be a module or aggregate, not a template
6
---
7
*/
8
9
// https://issues.dlang.org/show_bug.cgi?id=19176
10
11
void
main
()
12
{
13
__traits
(
getUnitTests
,
foo
);
14
}
15
16
template
foo
()
17
{
18
static if
(
true
)
19
{
20
enum
bar
;
21
}
22
else
23
{
24
enum
bar
;
25
}
26
}