From 2597d9f8005109e9871c71e9c381ab0b7a89fbbb Mon Sep 17 00:00:00 2001 From: Ezekiel Warren Date: Tue, 29 Oct 2024 09:03:45 -0700 Subject: [PATCH] chore: unsafe_narrow -> unchecked_narrow --- examples/donut/cursed_donut.cpp2 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/donut/cursed_donut.cpp2 b/examples/donut/cursed_donut.cpp2 index 8141847..6910247 100644 --- a/examples/donut/cursed_donut.cpp2 +++ b/examples/donut/cursed_donut.cpp2 @@ -34,13 +34,13 @@ main: () = { t: float = c * h * g - f * e; - x: int = cpp2::unsafe_narrow(40 + 30 * D * (l * h * m - t * n)); + x: int = cpp2::unchecked_narrow(40 + 30 * D * (l * h * m - t * n)); - y: int = cpp2::unsafe_narrow(12 + 15 * D * (l * h * n + t * m)); + y: int = cpp2::unchecked_narrow(12 + 15 * D * (l * h * n + t * m)); o: int = x + 80 * y; - N: int = cpp2::unsafe_narrow(8 * ((f * e - c * d * g) * m - c * d * e - f * g - l * d * n)); + N: int = cpp2::unchecked_narrow(8 * ((f * e - c * d * g) * m - c * d * e - f * g - l * d * n)); if 22 > y && y > 0 && x > 0 && 80 > x && D > z[0] { z[o] = D; if N > 0 { b[o] = brightness_chars[N % brightness_chars.size()]; }