[nostalgia/geo] GCC 12 fix
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
* Copyright 2016 - 2022 Gary Talent (gary@drinkingtea.net). All rights reserved.
|
||||
*/
|
||||
|
||||
#include <algorithm>
|
||||
#include <filesystem>
|
||||
|
||||
#include <ox/std/std.hpp>
|
||||
|
@@ -27,8 +27,8 @@ enum class ProjectEvent {
|
||||
};
|
||||
|
||||
[[nodiscard]]
|
||||
constexpr ox::Result<ox::String> fileExt(auto path) noexcept {
|
||||
const auto extStart = std::find(path.crbegin(), path.crend(), '.').offset();
|
||||
constexpr ox::Result<ox::String> fileExt(const ox::String &path) noexcept {
|
||||
const auto extStart = ox::find(path.crbegin(), path.crend(), '.').offset();
|
||||
if (!extStart) {
|
||||
return OxError(1, "Cannot open a file without valid extension.");
|
||||
}
|
||||
|
Reference in New Issue
Block a user