Skip to content

Commit

Permalink
Add API annotation for new fail assertion
Browse files Browse the repository at this point in the history
  • Loading branch information
awelless committed Sep 1, 2023
1 parent 5a70965 commit 666f73f
Showing 1 changed file with 2 additions and 1 deletion.
Expand Up @@ -33,13 +33,14 @@ fun fail(message: String?, throwable: Throwable? = null): Nothing =
/**
* @see Assertions.fail
*/
@API(since = "5.11", status = EXPERIMENTAL)
@JvmName("fail_nonNullableLambda")
fun fail(message: () -> String): Nothing {
contract {
callsInPlace(message, UNKNOWN)
}

return Assertions.fail<Nothing>(message)
return Assertions.fail(message)
}

/**
Expand Down

0 comments on commit 666f73f

Please sign in to comment.