def getitem(self, index, context=None):
try:<EOL><INDENT>methods = dunder_lookup.lookup(self, "<STR_LIT>")<EOL><DEDENT>except exceptions.AttributeInferenceError as exc:<EOL><INDENT>raise exceptions.AstroidTypeError(node=self, context=context) from exc<EOL><DEDENT>method = methods[<NUM_LIT:0>]<EOL>new_context = contextmod.bind_context_to_node(context, self)<EOL>new_context.callcontext = contextmod.CallContext(args=[index])<EOL>try:<EOL><INDENT>return next(method.infer_call_result(self, new_context))<EOL><DEDENT>except exceptions.InferenceError:<EOL><INDENT>return util.Uninferable<EOL><DEDENT>
Return the inference of a subscript.

        This is basically looking up the method in the metaclass and calling it.

        :returns: The inferred value of a subscript to this class.
        :rtype: NodeNG

        :raises AstroidTypeError: If this class does not define a
            ``__getitem__`` method.