mirror of
https://github.com/electron/electron.git
synced 2026-02-19 03:14:51 -05:00
chore: remove invalid constexpr qualification (#40006)
GetPathConstant calls base::internal::flat_tree<Key, GetKeyFromValue, KeyCompare, Container>::find(Key const&) const which is not constexpr. GCC 12 and earlier raise a compile error on this.
This commit is contained in:
@@ -433,7 +433,7 @@ IconLoader::IconSize GetIconSizeByString(const std::string& size) {
|
||||
}
|
||||
|
||||
// Return the path constant from string.
|
||||
constexpr int GetPathConstant(base::StringPiece name) {
|
||||
int GetPathConstant(base::StringPiece name) {
|
||||
// clang-format off
|
||||
constexpr auto Lookup = base::MakeFixedFlatMapSorted<base::StringPiece, int>({
|
||||
{"appData", DIR_APP_DATA},
|
||||
|
||||
Reference in New Issue
Block a user