def compile(cls, input: str) -> Expression:
        """Compile a match expression.

        :param input: The input expression - one line.
        """
        astexpr = expression(Scanner(input))
        code: types.CodeType = compile(
            astexpr,
            filename="<pytest match expression>",
            mode="eval",
        )
        return Expression(code)
Compile a match expression.

        :param input: The input expression - one line.
        
src/_pytest/mark/expression.py