Added IEnumerable implementation
This commit is contained in:
parent
c1dc527007
commit
05c8bce662
1 changed files with 8 additions and 1 deletions
|
@ -89,7 +89,7 @@ namespace arookas {
|
|||
}
|
||||
}
|
||||
|
||||
class sunScope {
|
||||
class sunScope : IEnumerable<sunStorableSymbol> {
|
||||
List<sunStorableSymbol> mStorables;
|
||||
sunScopeType mType;
|
||||
|
||||
|
@ -142,6 +142,13 @@ namespace arookas {
|
|||
public sunConstantSymbol ResolveConstant(string name) {
|
||||
return ResolveStorable(name) as sunConstantSymbol;
|
||||
}
|
||||
|
||||
public IEnumerator<sunStorableSymbol> GetEnumerator() {
|
||||
return mStorables.GetEnumerator();
|
||||
}
|
||||
IEnumerator IEnumerable.GetEnumerator() {
|
||||
return GetEnumerator();
|
||||
}
|
||||
}
|
||||
|
||||
enum sunScopeType {
|
||||
|
|
Loading…
Reference in a new issue