Turn clumsy `static assert` into a `pragma(msg)`

This commit is contained in:
Elias Batek 2024-05-24 04:45:48 +02:00
parent 5c2817e563
commit 033770a6c6
1 changed files with 1 additions and 1 deletions

View File

@ -442,7 +442,7 @@ in (source.length == target.length) {
} else { } else {
// better error message in case its not implemented // better error message in case its not implemented
static if (!is(typeof(blendPixel!mode))) { static if (!is(typeof(blendPixel!mode))) {
static assert(false, "Missing `blendPixel!(" ~ mode.stringof ~ ")`."); pragma(msg, "Hint: Missing or bad `blendPixel!(" ~ mode.stringof ~ ")`.");
} }
foreach (immutable idx, ref pxTarget; target) { foreach (immutable idx, ref pxTarget; target) {