Skip to content

Request boost::property_tree::json_parser::read_json(boost::filesystem::path const&, ...) #393

@mfsv

Description

@mfsv

There are currently two signatures available:

  • read_json(std::string const&, ...)
  • read_json(std::basic_istream<...> const&, ...)

In case of Windows and a file name with non-standard characters I cannot rely on read_json(std::string const&, ...).
I therefore use this workaround:

boost::filesystem::path const filename(L"Some foreign language file name");
boost::filesystem::ifstream ifs(filename);
read_json(ifs, ...);

In case of an error, the exception thrown does not contain the filename and I have to construct a message of my own.

I would like to request these additions:

  • read_json(boost::filesystem::path const&, ...)
  • read_json(std::wstring const&, ...)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions