Преглед изворни кода

Limit scoped search to module if that's the current scope. Fixes #409.

woollybah пре 6 година
родитељ
комит
db1b197792
1 измењених фајлова са 5 додато и 1 уклоњено
  1. 5 1
      expr.bmx

+ 5 - 1
expr.bmx

@@ -2834,8 +2834,12 @@ Type TIdentExpr Extends TExpr
 
 		'Local scope:TScopeDecl=IdentScope()
 		Local initialScope:Int = SCOPE_ALL
-		If scope And TClassDecl(scope) Then
+		If scope Then
+			If TClassDecl(scope) Then
 			initialScope = SCOPE_CLASS_HEIRARCHY
+			Else If TModuleDecl(scope) Then
+				initialScope = SCOPE_MODULE
+			End If
 		End If
 		
 		Local fdecl:TFuncDecl