Skip to content

Commit 58b34bb

Browse files
committed
fixes
1 parent 8bad775 commit 58b34bb

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

runtime-light/stdlib/time/datetime.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ class_instance<C$DateTime> f$DateTime$$__construct(const class_instance<C$DateTi
1818
auto expected{kphp::timelib::parse_time(std::string_view{str_to_parse.c_str(), str_to_parse.size()})};
1919
if (!expected.has_value()) [[unlikely]] {
2020
string err_msg;
21-
std::format_to(kphp::string_back_insert_iterator{.ref = err_msg}, "DateTime::__construct(): Failed to parse time string ({}) {}", datetime.c_str(), expected.error());
21+
std::format_to(kphp::string_back_insert_iterator{.ref = err_msg}, "DateTime::__construct(): Failed to parse time string ({}) {}", datetime.c_str(),
22+
expected.error());
2223
TimeInstanceState::get().update_last_errors(std::move(expected.error()));
2324
THROW_EXCEPTION(kphp::exception::make_throwable<C$Exception>(err_msg));
2425
return {};

runtime-light/stdlib/time/timelib-functions.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ std::expected<rel_time, error_container> parse_interval(std::string_view interva
101101
return std::unexpected{error_container{errors}};
102102
}
103103

104-
time add(const kphp::timelib::time& t, timelib_rel_time& interval) noexcept {
104+
time add_time_interval(const kphp::timelib::time& t, timelib_rel_time& interval) noexcept {
105105
time new_time{(kphp::memory::libc_alloc_guard{}, timelib_add(t.get(), std::addressof(interval)))};
106106
return new_time;
107107
}

0 commit comments

Comments
 (0)