Skip to content
Snippets Groups Projects
Commit b28ef56b authored by Nils-Arne Dreier's avatar Nils-Arne Dreier Committed by Siddhant Tibrewal
Browse files

fix: use std::to_chars instead of std::format

parent 6b972b0a
No related branches found
No related tags found
No related merge requests found
#include <cassert>
#include <charconv>
#include <coyote.hpp>
#include <format>
#include <iostream>
#include <memory>
#include <numeric>
......@@ -58,9 +58,10 @@ namespace coyote {
size_t hash = std::hash<std::string>{}(
iso_dt.value() + std::to_string(yac_time_reduction) + interpolation_stack_yaml);
std::string tgt_field_name =
"target:" + source_field + "(" + std::format("{:x}", hash) + ")";
int target_field_id = -1;
char hash_str[2 * sizeof(hash)];
std::to_chars(hash_str, hash_str + (2 * sizeof(hash)), hash, 16);
std::string tgt_field_name = "target:" + source_field + "(" + hash_str + ")";
int target_field_id = -1;
yac_cdef_field(
tgt_field_name.c_str(),
_yac_comp_id,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment