def _locatePatterns(self, pattern, default, loop=True): if self.original.tag.pattern == pattern: yield self.original.tag.clone(deep=False, clearPattern=True) for node in stan._locatePatterns(self.original.tag, pattern, default): yield node