Skip to content

make_expression with ec broken in v0.172.0 #470

@meierfra-ergon

Description

@meierfra-ergon

after update to 0.172.0 my code using following make_expression() function

template <class Json>
jsonpath_expression<Json> make_expression(const Json::string_view_type& expr,
    std::error_code& ec);

(https://github.com/danielaparker/jsoncons/blob/v0.172.0/doc/ref/jsonpath/make_expression.md)
does not compile anymore. it seems a wrapper function is missing in jsonpath_expression.hpp
something like:

template <class Json>
auto make_expression(const typename Json::string_view_type& expr, std::error_code& ec) {
  return make_expression<Json>(combine_allocators(), expr, custom_functions<Json>(), ec);
}

** What is the expected behavior?**
code should compile with make_expression(expr, ec)

What is the actual behavior?
compile error -> "no matching function for call to 'make_expression'"

Enumerate the steps to reproduce the bug

Include a small, self-contained example if possible

What compiler, architecture, and operating system?

  • Compiler: clang14
  • Architecture x86, x64
  • Operating system: linux

What jsoncons library version?

  • Latest release 0.172.0

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions