StardustPL / Stardust

"A programming language that doesn't make me angry to use it."
https://StardustPL.GitHub.IO/
The Unlicense
4 stars 0 forks source link

Planning: Scopes/Namespaces #7

Open LB-- opened 10 years ago

LB-- commented 10 years ago

The difference between a scope and a namespace is that a scope is an anonymous namespace.

Namespaces may be referred to, and they have a distinct type.

The : and :: operators are used for explicitly specifying which namespace is to be searched for an identifier. The : operator can be overloaded to return an ordered set of namespaces in which to search.

The global scope can be explicitly accessed by treating the : and :: operators as unary prefix operators, similar to in C++.

All scopes have user-specified access rights that indicate which other scopes can see the contents of that scope.

LB-- commented 8 years ago

All scopes have user-specified access rights that indicate which other scopes can see the contents of that scope.

See #14