annotate run/o/overload_26_A.d @ 1489:b8c0195059d9

changed nntp: URLs to http: URLs
author thomask
date Mon, 09 Apr 2007 13:47:01 +0000
parents 7ca91547903e
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1013
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
1 // $HeadURL$
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
2 // $Date$
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
3 // $Author$
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
4
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
5 // @author@ Stewart Gordon <smjg_1998@yahoo.com>
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
6 // @date@ 2005-10-13
1489
b8c0195059d9 changed nntp: URLs to http: URLs
thomask
parents: 1013
diff changeset
7 // @uri@ http://www.digitalmars.com/pnews/read.php?server=news.digitalmars.com&group=digitalmars.D.bugs&artnum=5140
1013
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
8
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
9 module dstress.run.o.overload_26_A;
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
10
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
11 enum E{
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
12 A
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
13 }
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
14
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
15 int foo(E e){
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
16 assert(0);
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
17 }
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
18
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
19 int foo(uint i){
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
20 return i + 1;
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
21 }
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
22
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
23 int main(){
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
24 if(foo(cast(int)2) != 3){
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
25 assert(0);
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
26 }
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
27
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
28 return 0;
7ca91547903e Weird overload resolution (or rather, lack thereof) for literals
thomask
parents:
diff changeset
29 }