From a4ecc653986c331941d841961369befb33814dd6 Mon Sep 17 00:00:00 2001 From: Shannon Booth Date: Sat, 23 Dec 2023 14:09:17 +1300 Subject: [PATCH] AK: Add DeprecatedFlyString::to_number --- AK/DeprecatedFlyString.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/AK/DeprecatedFlyString.h b/AK/DeprecatedFlyString.h index 174b2d9d184..3a64ab91f31 100644 --- a/AK/DeprecatedFlyString.h +++ b/AK/DeprecatedFlyString.h @@ -69,6 +69,12 @@ public: DeprecatedFlyString to_lowercase() const; + template + Optional to_number(TrimWhitespace trim_whitespace = TrimWhitespace::Yes) const + { + return view().to_number(trim_whitespace); + } + template Optional to_int(TrimWhitespace = TrimWhitespace::Yes) const; template