def _AddToDependencyMap(names):
 curName = names[0]
 _topLevelNames.add(curName)
 for name in names[1:]:
  _dependencyMap.setdefault(curName, set()).add(name)
  curName = '.'.join([curName, name])

def _AddToDependencyMap ( names ) : curName = names [ 0 ] _topLevelNames . add ( curName ) for name in names [ 1 : ] : _dependencyMap . setdefault ( curName , set ( ) ) . add ( name ) curName = '.' . join ( [ curName , name ] )
note: must be holding the _lazylock .