Use to_string() on json_pointer string conversions
This commit is contained in:
parent
c6cb3d4c2d
commit
b2eaf73765
@ -171,7 +171,7 @@ public:
|
|||||||
auto fragment = new_uri.pointer();
|
auto fragment = new_uri.pointer();
|
||||||
|
|
||||||
// is there a reference looking for this unknown-keyword, which is thus no longer a unknown keyword but a schema
|
// is there a reference looking for this unknown-keyword, which is thus no longer a unknown keyword but a schema
|
||||||
auto unresolved = file.unresolved.find(fragment);
|
auto unresolved = file.unresolved.find(fragment.to_string());
|
||||||
if (unresolved != file.unresolved.end())
|
if (unresolved != file.unresolved.end())
|
||||||
schema::make(value, this, {}, {{new_uri}});
|
schema::make(value, this, {}, {{new_uri}});
|
||||||
else { // no, nothing ref'd it, keep for later
|
else { // no, nothing ref'd it, keep for later
|
||||||
@ -884,8 +884,8 @@ class boolean : public schema
|
|||||||
{
|
{
|
||||||
if (!true_) { // false schema
|
if (!true_) { // false schema
|
||||||
// empty array
|
// empty array
|
||||||
//switch (instance.type()) {
|
// switch (instance.type()) {
|
||||||
//case json::value_t::array:
|
// case json::value_t::array:
|
||||||
// if (instance.size() != 0) // valid false-schema
|
// if (instance.size() != 0) // valid false-schema
|
||||||
// e.error(ptr, instance, "false-schema required empty array");
|
// e.error(ptr, instance, "false-schema required empty array");
|
||||||
// return;
|
// return;
|
||||||
|
|||||||
@ -61,7 +61,7 @@ protected:
|
|||||||
|
|
||||||
std::tuple<std::string, std::string, std::string, std::string, std::string> as_tuple() const
|
std::tuple<std::string, std::string, std::string, std::string, std::string> as_tuple() const
|
||||||
{
|
{
|
||||||
return std::make_tuple(urn_, scheme_, authority_, path_, identifier_ != "" ? identifier_ : pointer_);
|
return std::make_tuple(urn_, scheme_, authority_, path_, identifier_ != "" ? identifier_ : pointer_.to_string());
|
||||||
}
|
}
|
||||||
|
|
||||||
public:
|
public:
|
||||||
@ -80,7 +80,7 @@ public:
|
|||||||
std::string fragment() const
|
std::string fragment() const
|
||||||
{
|
{
|
||||||
if (identifier_ == "")
|
if (identifier_ == "")
|
||||||
return pointer_;
|
return pointer_.to_string();
|
||||||
else
|
else
|
||||||
return identifier_;
|
return identifier_;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user