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
d: Merge upstream dmd, druntime 26f049fb26, phobos 330d6a4fd.
[official-gcc.git]
/
gcc
/
testsuite
/
gdc.test
/
compilable
/
deprecate14283.d
blob
fc51cf3f0b67bbefdcbdfeafe69356d3853e31b2
1
// REQUIRED_ARGS:
2
// PERMUTE_ARGS:
3
class
C
4
{
5
void
bug
()
6
{
7
autoref
!(
true
,
C
)(
this
);
// 'auto ref' becomes ref parameter
8
autoref
!(
false
,
Object
)(
super
);
// 'auto ref' becomes non-ref parameter
9
}
10
}
11
12
void
autoref
(
bool
result
,
T
)(
auto ref
T t
) {
static assert
(
__traits
(
isRef
,
t
) ==
result
); }