code: def tokenize(self, text, context=0, skip_style_tags=False):
          
          split = self.regex.split(text)
          self._text = [segment for segment in split if segment]
          self._head = self._global = self._depth = 0
          self._bad_routes = set()
          self._skip_style_tags = skip_style_tags
  
          try:
              tokens = self._parse(context)
          except BadRoute:  # pragma: no cover (untestable/exceptional case)
              raise ParserError("Python tokenizer exited with BadRoute")
          if self._stacks:  # pragma: no cover (untestable/exceptional case)
              err = "Python tokenizer exited with non-empty token stack"
              raise ParserError(err)
          return tokens
docs: Build a list of tokens from a string of wikicode and return it.