From d28c9ba054112cda3788cef73e5abccecfeefc66 Mon Sep 17 00:00:00 2001 From: Timothy Flynn Date: Thu, 15 Dec 2022 17:28:18 -0500 Subject: [PATCH] AK: Synchronize explicit instantiations of to_int and to_uint 1. Ensure long and long long are instantiated for to_int. 2. Ensure long and long long are not instantiated for to_uint. --- AK/DeprecatedString.cpp | 3 ++- AK/StringUtils.cpp | 2 -- AK/StringView.cpp | 2 -- 3 files changed, 2 insertions(+), 5 deletions(-) diff --git a/AK/DeprecatedString.cpp b/AK/DeprecatedString.cpp index f30fbae61f..c2ff851ea6 100644 --- a/AK/DeprecatedString.cpp +++ b/AK/DeprecatedString.cpp @@ -172,7 +172,8 @@ Optional DeprecatedString::to_int(TrimWhitespace trim_whitespace) const template Optional DeprecatedString::to_int(TrimWhitespace) const; template Optional DeprecatedString::to_int(TrimWhitespace) const; template Optional DeprecatedString::to_int(TrimWhitespace) const; -template Optional DeprecatedString::to_int(TrimWhitespace) const; +template Optional DeprecatedString::to_int(TrimWhitespace) const; +template Optional DeprecatedString::to_int(TrimWhitespace) const; template Optional DeprecatedString::to_uint(TrimWhitespace trim_whitespace) const diff --git a/AK/StringUtils.cpp b/AK/StringUtils.cpp index 58157d148e..eba74f8ee0 100644 --- a/AK/StringUtils.cpp +++ b/AK/StringUtils.cpp @@ -157,8 +157,6 @@ template Optional convert_to_uint(StringView str, TrimWhitespace); template Optional convert_to_uint(StringView str, TrimWhitespace); template Optional convert_to_uint(StringView str, TrimWhitespace); template Optional convert_to_uint(StringView str, TrimWhitespace); -template Optional convert_to_uint(StringView str, TrimWhitespace); -template Optional convert_to_uint(StringView str, TrimWhitespace); template Optional convert_to_uint_from_hex(StringView str, TrimWhitespace trim_whitespace) diff --git a/AK/StringView.cpp b/AK/StringView.cpp index f299ab707b..92315f6add 100644 --- a/AK/StringView.cpp +++ b/AK/StringView.cpp @@ -239,8 +239,6 @@ template Optional StringView::to_uint() const; template Optional StringView::to_uint() const; template Optional StringView::to_uint() const; template Optional StringView::to_uint() const; -template Optional StringView::to_uint() const; -template Optional StringView::to_uint() const; #ifndef KERNEL Optional StringView::to_double(TrimWhitespace trim_whitespace) const