package androidx.compose.runtime;

/* JADX INFO: loaded from: classes.dex */
public final class PreconditionsKt {
    public static final void checkPrecondition(boolean z6, J4.a aVar) {
        if (z6) {
            return;
        }
        throwIllegalStateException((String) aVar.invoke());
    }

    public static final void requirePrecondition(boolean z6, J4.a aVar) {
        if (z6) {
            return;
        }
        throwIllegalArgumentException((String) aVar.invoke());
    }

    public static final void throwIllegalArgumentException(String str) {
        throw new IllegalArgumentException(str);
    }

    public static final void throwIllegalStateException(String str) {
        throw new IllegalStateException(str);
    }

    public static final void checkPrecondition(boolean z6) {
        if (z6) {
            return;
        }
        throwIllegalStateException("Check failed.");
    }
}
