Jan Borsodi  committed d755a41

A symbol object can now point to another symbol, it will iteratively resolve symbols until it reaches the actual object. The resolved object is placed in the symbol as the attribute 'resolved'.

  • Participants
  • Parent commits 8d1404d
  • Branches fixes

Comments (0)

Files changed (1)

File hob/

     def _resolveSymbols(self):
         for sym in self._symbols:
-            item = self.package.find(, sym.current)
+            current = sym.current
+            while isinstance(current, Symbol):
+                current = current.resolved
+            item = self.package.find(, current)
+            sym.resolved = item
             if not isinstance(item, sym.kind):
-                raise TypeError("Expected type %s for symbol %s" % (sym.kind.__name__, ".".join(sym.current.path() + [])))
+                raise TypeError("Expected type %s for symbol %s" % (sym.kind.__name__, ".".join(current.path() + [])))
             setattr(sym.owner, sym.attribute, item)
             if sym.callback:
                 sym.callback(sym, item)