Niels Lohmann
c2e175763c
👌 added another conversion function #1315
2018-10-25 22:47:08 +02:00
Niels Lohmann
20038e2703
📝 added a note to the discussion #1286
2018-10-23 23:00:43 +02:00
Niels Lohmann
b49f76931f
👌 replaced static_cast to CharType by conversion function #1286
2018-10-23 17:49:04 +02:00
Niels Lohmann
9294e25c98
Merge pull request #1301 from theodelrieu/fix/1299
...
add new is_constructible_* traits used in from_json
2018-10-18 19:18:48 +02:00
Niels Lohmann
dbb0b63187
♿ improved error messages for binary formats #1288
...
This commit is the equivalent of #1282 for CBOR, MessagePack, and UBJSON.
2018-10-17 12:15:58 +02:00
Théo DELRIEU
a946dfc19c
add a note to maintainers in type_traits.hpp
2018-10-17 12:03:10 +02:00
Théo DELRIEU
45c8af2c46
add new is_constructible_* traits used in from_json
...
is_compatible_* traits were used in from_json, but it made no sense
whatsoever.
It used to work because of non-SFINAE correctness + json_ref
unconstrained variadic template constructor.
SFINAE checks are becoming quite complex, we need a specification of
some sort describing:
* which concepts the library uses
* how the conversion to/from json works in detail
Having such a specification would really help simplifying the current
code (as well as having meaningful checks).
Fixes !1299
2018-10-16 14:00:34 +02:00
Théo DELRIEU
11fecc25af
add constraints for variadic json_ref constructors
...
Fixes #1292
2018-10-12 10:54:58 +02:00
Niels Lohmann
e426219256
Merge pull request #1282 from nlohmann/feature/lines_columns
...
Improve diagnostic messages
2018-10-08 22:17:33 +02:00
Niels Lohmann
6d34d64bfd
🚑 fixed compilation error
2018-10-08 06:54:51 +02:00
Niels Lohmann
74a31075e3
♿ improved parse error messages
2018-10-07 22:39:17 +02:00
Niels Lohmann
6e49d9f5ff
🚑 fixed compilation error
2018-10-07 21:34:40 +02:00
Niels Lohmann
f8158997b5
📝 fixed documentation
2018-10-07 21:30:58 +02:00
Niels Lohmann
3abb788139
🚨 fixed some more clang-tidy warnings
2018-10-07 19:07:58 +02:00
Niels Lohmann
858e75c4df
🚨 fixed some clang-tidy warnings
2018-10-07 18:39:18 +02:00
Niels Lohmann
6d09cdec34
🐛 fixed a bug in the unget function
2018-10-07 16:48:45 +02:00
Niels Lohmann
011b15dd08
♿ added line positions to error messages
...
This is a follow-up to #1210 .
2018-10-07 12:27:24 +02:00
Niels Lohmann
fa722d5ac3
🚨 fixed another linter warning
2018-10-06 16:26:47 +02:00
Niels Lohmann
ec95438a59
🚨 fixed some linter warnings
2018-10-06 13:49:02 +02:00
Niels Lohmann
b968faa882
🔖 set version to 3.3.0
2018-10-05 10:59:33 +02:00
Niels Lohmann
bb55885215
💄 cleaned code
2018-10-04 20:42:19 +02:00
Antonio Borondo
b6fdad9acd
Remove anonymous namespace
2018-10-03 13:51:49 +01:00
Antonio Borondo
7c385a4844
Fix error: 'wide_string_input_helper' was not declared in this scope
2018-10-03 12:41:34 +01:00
Antonio Borondo
9ba3f79667
Fix error: explicit specialization in non-namespace scope
2018-10-03 12:26:24 +01:00
Antonio Borondo
8d1585f065
Change implementation to use templates
2018-10-03 11:44:02 +01:00
Antonio Borondo
0231059290
Fix warning
2018-10-03 11:27:53 +01:00
Niels Lohmann
1fae82b7a7
Merge branch 'develop' into fix/1237
2018-09-29 14:50:36 +02:00
Niels Lohmann
d26f39466e
Merge pull request #1231 from theodelrieu/feature/get_with_parameter
...
Add a get overload taking a parameter.
2018-09-29 14:30:04 +02:00
Niels Lohmann
c61a9071ae
🚨 fixed a compilation issue with ICPC #755
...
Closes #1222
2018-09-29 11:50:14 +02:00
Théo DELRIEU
521fe49fec
Add basic_json::get_to function.
...
Takes an lvalue reference, and returns the same reference.
This allows non-default constructible types to be converted without
specializing adl_serializer.
This overload does not require CopyConstructible either.
Implements #1227
2018-09-28 11:25:23 +02:00
Henry Fredrick Schreiner
7a37ba0c02
Adding 4.8 test to travis
2018-09-27 22:31:39 +02:00
Chris Harris
99b7c7c8ef
Patch nlohmann/json for GCC 4.8
...
See https://github.com/nlohmann/json/pull/212 for details
2018-09-25 18:10:20 +02:00
Théo DELRIEU
4e52277b70
Fix issue #1237
...
* Make the conversion operator SFINAE correct.
* Workaround a GCC bug with some traits in type_traits.hpp
The first bullet-point implies that every `get`/`get_ptr` be SFINAE
correct as well.
2018-09-20 10:33:14 +02:00
David Guthrie
4d780b091b
Reordered the code. It seems to stop clang 3.4.2 in RHEL 7 from crashing intermittently.
2018-09-18 16:38:59 -04:00
Niels Lohmann
7fa3b8865c
Merge pull request #1221 from rivertam/better-error-305
...
Better error 305
2018-09-18 12:49:07 +02:00
Ben Berman
8f07ab6392
Replace "key-style argument" with "string argument"
2018-09-17 15:36:38 -04:00
mandreyel
6b5334c167
Move lambda out of unevaluated context
2018-09-10 13:34:59 +02:00
Niels Lohmann
ebb3c03293
🎨 cleanup after #1228
2018-09-09 18:19:33 +02:00
Théo DELRIEU
aea648bb7a
remove now-useless traits. check for is_basic_json where needed
2018-09-07 14:10:39 +02:00
Théo DELRIEU
4b4bbceebf
make from_json SFINAE-correct
2018-09-07 14:10:37 +02:00
Théo DELRIEU
f7971f04a5
make to_json SFINAE-correct
2018-09-07 12:18:04 +02:00
Théo DELRIEU
f7c8a2145a
refactor from/to_json(CompatibleArrayType)
2018-09-07 12:18:04 +02:00
Théo DELRIEU
628f76729e
do not check for compatible_object_type in compatible_array_type
2018-09-07 12:18:03 +02:00
Théo DELRIEU
29f72966c3
refactor is_compatible_type, remove conjunction & co
2018-09-07 12:18:03 +02:00
Théo DELRIEU
77967e6548
refactor is_compatible_integer_type
2018-09-07 12:18:03 +02:00
Théo DELRIEU
13760857ff
refactor is_compatible_array_type
2018-09-07 12:18:02 +02:00
Théo DELRIEU
924e95c6e8
refactor is_compatible_string_type
2018-09-07 12:18:02 +02:00
Théo DELRIEU
e84195ab7b
refactor is_compatible_object_type
2018-09-07 12:18:02 +02:00
Théo DELRIEU
b59c3367c9
use detected instead of has_* traits
2018-09-07 12:17:59 +02:00
Théo DELRIEU
1ea8cd128c
fix void_t for older compilers
2018-09-07 12:17:33 +02:00