Should alias expand visibility?

Norbert Nemec Norbert at Nemec-online.de
Mon Jul 26 21:13:37 PDT 2010


On 25/07/10 23:23, Tomek Sowiński wrote:
> If foo is private but its public alias poo exists, should you be able to use
> poo? (currently you can't)

Visibility is a property of each symbol, not the object behind it. I see 
nothing wrong with allowing aliases as a way to offer public access to 
objects that were originally only accessible via private symbols.

Imagine a public wrapper function that does nothing but call another 
private function. This would be conceptually very similar to a public 
alias of a private symbol. Nothing wrong with it.


More information about the Digitalmars-d mailing list