http://d.puremagic.com/issues/show_bug.cgi?id=5957



--- Comment #1 from kenn...@gmail.com 2011-05-08 10:35:26 PDT ---
To show that this bug does affect code more than the demangler, consider the
following programs:

-----------------------------------
// a146zzzzzza.d
template b(){}
-----------------------------------
// a.d
template
zzzzzza1bTC1y130bbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffbbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffggggggggggffffffffffgggggggggg(){}
-----------------------------------
// y.d
module y;
import a146zzzzzza;
import a;
import std.stdio;
class
bbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffbbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffggggggggggffffffffffgggggggggg
{}
template f(s...) {
    void f(){ writeln(s.stringof); }
}
void main() {
    f!( a146zzzzzza.b,
bbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffbbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffggggggggggffffffffffgggggggggg
)();
    f!(
a.zzzzzza1bTC1y130bbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffbbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffggggggggggffffffffffgggggggggg
)();
}
-----------------------------------

The output is:

tuple(b(),(bbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffbbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffggggggggggffffffffffgggggggggg))
tuple(b(),(bbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffbbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffggggggggggffffffffffgggggggggg))

as we can see, the 2nd function is shadowed by the 1st as they share the same
symbol:

_D1y161__T1fS1511a146zzzzzza1bTC1y130bbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffbbbbbbbbbbccccccccccddddddddddeeeeeeeeeeffffffffffggggggggggffffffffffggggggggggZ1fFZv

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to