On Sunday, April 13, 2014 08:40:17 Philpax wrote:
Is not being able to overload functions in local scope intended
behaviour?
Yes. IIRC, I complained about it at one point, and Walter didn't like the idea
of having overloaded nested functions. I don't remember what his reasoning
was, but I
On Monday, 14 April 2014 at 10:35:20 UTC, Jonathan M Davis wrote:
On Sunday, April 13, 2014 08:40:17 Philpax wrote:
Is not being able to overload functions in local scope intended
behaviour?
Yes. IIRC, I complained about it at one point, and Walter
didn't like the idea
of having overloaded
Thanks! I used the static struct solution.
I did some quick research, and I think that the reason why the
original code doesn't work is because the two functions have the
same identifier, which results in Dsymboltable::insert rejecting
the second function. I haven't tested this hypothesis,
While trying to overload a function in local/function scope, I
ran into this behaviour: http://dpaste.dzfl.pl/b4e8b9ddf78a and I
was wondering what the cause was.
As far as I can tell, this should be fine in global scope (and it
is), but I'm curious as to why it doesn't work inside a
On Saturday, 12 April 2014 at 16:45:02 UTC, Philpax wrote:
While trying to overload a function in local/function scope, I
ran into this behaviour: http://dpaste.dzfl.pl/b4e8b9ddf78a and
I was wondering what the cause was.
As far as I can tell, this should be fine in global scope (and
it is),
On 4/12/14, monarch_dodra monarchdo...@gmail.com wrote:
I know you can workaround it by putting
your functions a static members of a dummy struct
You can also use a mixin template:
class A {}
class B {}
mixin template M()
{
void func2(A a) { }
void func2(B b) { }
}
void main()
{