As an alternative to @constinferred_broken introduced in #4, I think it would be helpful to support the syntax @constinferred expr broken=true, similar to the syntax of @test: https://docs.julialang.org/en/v1/stdlib/Test/#Test.@test.
My use case is that it is not uncommon that type inference only succeeds in more recent versions of Julia, that syntax would allow writing tests like:
@test @constinferred(f(x), broken=VERSION<v"1.11-")
while having separate macros makes expressing that logic a bit more verbose.