nlohmann / json

JSON for Modern C++
https://json.nlohmann.me
MIT License
42.38k stars 6.67k forks source link

README.md overuses `template` keyword before `get` function #4205

Closed davidstone closed 10 months ago

davidstone commented 10 months ago

Description

The documentation contains 18 matches for template get. All of them should just be get except for the line value = j.template get<T>(); // oops! which is correct as in.

Reproduction steps

Read the readme

Expected vs. actual results

Should not have template keyword

Minimal code example

No response

Error messages

No response

Compiler and operating system

N/A

Library version

develop current

Validation

nlohmann commented 10 months ago

IIRC there were compilers with issues without the template keyword, so we decided to add it just in case. If you have a concrete example, feel free to open a PR.

nlohmann commented 10 months ago

See #4038 and #4039.