Mercurial > projects > ldc
diff dmd/mtype.c @ 642:307ae566885f
Make default argument protection check not error for undefined protection.
Fix symbol visibility issues in Tango.
author | Christian Kamm <kamm incasoftware de> |
---|---|
date | Fri, 03 Oct 2008 17:31:16 +0200 |
parents | bc83491463f0 |
children | 50383e476c7e |
line wrap: on
line diff
--- a/dmd/mtype.c Fri Oct 03 09:11:41 2008 +0200 +++ b/dmd/mtype.c Fri Oct 03 17:31:16 2008 +0200 @@ -2939,7 +2939,7 @@ // this check only catches the common case that the default arg Exp is a VarExp if(arg->defaultArg->op == TOKvar) { VarExp *ve = (VarExp *)arg->defaultArg; - if(ve->var->protection < sc->protection) + if(ve->var->protection != PROTundefined && ve->var->protection < sc->protection) error(loc, "default argument %s has stronger protection than function %s", ve->var->toChars(), toChars()); } }