code: def get_lexer(environment):
      
      key = (environment.block_start_string,
             environment.block_end_string,
             environment.variable_start_string,
             environment.variable_end_string,
             environment.comment_start_string,
             environment.comment_end_string,
             environment.line_statement_prefix,
             environment.line_comment_prefix,
             environment.trim_blocks,
             environment.lstrip_blocks,
             environment.newline_sequence,
             environment.keep_trailing_newline)
      lexer = _lexer_cache.get(key)
      if lexer is None:
          lexer = Lexer(environment)
          _lexer_cache[key] = lexer
      return lexer
docs: Return a lexer which is probably cached.