parameters: (self, key)
return_statement: return rv
docstring: Looks up a variable like `__getitem__` or `get` but returns an
          :class:`Undefined` object with the name of the name looked up.
docstring_summary: Looks up a variable like `__getitem__` or `get` but returns an
          :class:`Undefined` object with the name of the name looked up.
docstring_tokens: Looks up a variable like __getitem__ or get but returns an : class : Undefined object with the name of the name looked up .
function: def resolve(self, key):
          """Looks up a variable like `__getitem__` or `get` but returns an
          :class:`Undefined` object with the name of the name looked up.
          """
          if self._legacy_resolve_mode:
              rv = resolve_or_missing(self, key)
          else:
              rv = self.resolve_or_missing(key)
          if rv is missing:
              return self.environment.undefined(name=key)
          return rv
function_tokens: def resolve ( self , key ) : if self . _legacy_resolve_mode : rv = resolve_or_missing ( self , key ) else : rv = self . resolve_or_missing ( key ) if rv is missing : return self . environment . undefined ( name = key ) return rv