class_docstr: Lexer for `Shen <http://shenlanguage.org/>`_ source code.
  
  .. versionadded:: 2.1
class_docstr_tok: ["Lexer","for","`","Shen","<","http",":","\/\/shenlanguage.org\/",">","`","_","source","code",".","..","versionadded",":",":","2.1"]
code: def _process_declaration(self, declaration, tokens):
      for index, token, value in tokens:
          if self._relevant(token):
              break
          yield index, token, value
  
      if declaration == "datatype":
          prev_was_colon = False
          token = Keyword.Type if token == Literal else token
          yield index, token, value
          for index, token, value in tokens:
              if prev_was_colon and token == Literal:
                  token = Keyword.Type
              yield index, token, value
              if self._relevant(token):
                  prev_was_colon = token == Literal and value == ":"
      elif declaration == "package":
          token = Name.Namespace if token == Literal else token
          yield index, token, value
      elif declaration == "define":
          token = Name.Function if token == Literal else token
          yield index, token, value
          for index, token, value in tokens:
              if self._relevant(token):
                  break
              yield index, token, value
          if value == "{" and token == Literal:
              yield index, Punctuation, value
              for index, token, value in self._process_signature(
                  tokens
              ):
                  yield index, token, value
          else:
              yield index, token, value
      else:
          token = Name.Function if token == Literal else token
          yield index, token, value
  
      return
  
imports: import re
  from pygments.lexer import RegexLexer, include, bygroups, words, default
  from pygments.token import Text, Comment, Operator, Keyword, Name, String, Number, Punctuation, Literal, Error
  from pygments.lexers.python import PythonLexer
label_desc: Use image node_id 5 for calling the ShenLexer obj's underlying member method code with example usage: obj._process_declaration(declaration, tokens) without return types