Skip to content

Commit eec1974

Browse files
committed
Merge remote-tracking branch 'nlohmann/develop' into iterate-on-destruction
2 parents 372c4d2 + 67259d6 commit eec1974

148 files changed

Lines changed: 32109 additions & 24043 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.circleci/config.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
version: 2
2+
jobs:
3+
build:
4+
docker:
5+
- image: debian:stretch
6+
7+
steps:
8+
- checkout
9+
10+
- run:
11+
name: Install sudo
12+
command: 'apt-get update && apt-get install -y sudo && rm -rf /var/lib/apt/lists/*'
13+
- run:
14+
name: Install GCC
15+
command: 'apt-get update && apt-get install -y gcc g++'
16+
- run:
17+
name: Install CMake
18+
command: 'apt-get update && sudo apt-get install -y cmake'
19+
- run:
20+
name: Create build files
21+
command: 'mkdir build ; cd build ; cmake ..'
22+
- run:
23+
name: Versions
24+
command: 'g++ --version ; uname -a'
25+
- run:
26+
name: Compile
27+
command: 'cmake --build build'
28+
- run:
29+
name: Execute test suite
30+
command: 'cd build ; ctest -j 2'

.clang-tidy

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
Checks: '-*,
2+
bugprone-*,
3+
cert-*,
4+
clang-analyzer-*,
5+
google-*,
6+
-google-runtime-references,
7+
-google-explicit-constructor,
8+
hicpp-*,
9+
-hicpp-no-array-decay,
10+
-hicpp-uppercase-literal-suffix,
11+
-hicpp-explicit-conversions,
12+
misc-*,
13+
-misc-non-private-member-variables-in-classes,
14+
llvm-*,
15+
-llvm-header-guard,
16+
modernize-*,
17+
-modernize-use-trailing-return-type,
18+
performance-*,
19+
portability-*,
20+
readability-*,
21+
-readability-magic-numbers,
22+
-readability-uppercase-literal-suffix'
23+
24+
CheckOptions:
25+
- key: hicpp-special-member-functions.AllowSoleDefaultDtor
26+
value: 1

.doozer.json

Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
{
2+
"targets": {
3+
"raspbian-jessie": {
4+
"buildenv": "raspbian-jessie",
5+
"builddeps": ["build-essential", "wget"],
6+
"buildcmd": [
7+
"uname -a",
8+
"cat /etc/os-release",
9+
"g++ --version",
10+
"cd",
11+
"wget https://github.com/Kitware/CMake/releases/download/v3.14.0/cmake-3.14.0.tar.gz",
12+
"tar xfz cmake-3.14.0.tar.gz",
13+
"cd cmake-3.14.0",
14+
"./bootstrap",
15+
"make -j8",
16+
"cd",
17+
"mkdir build",
18+
"cd build",
19+
"../cmake-3.14.0/bin/cmake /project/repo/checkout",
20+
"make -j8",
21+
"../cmake-3.14.0/bin/ctest -VV -j4 --timeout 10000"
22+
]
23+
},
24+
"xenial-armhf": {
25+
"buildenv": "xenial-armhf",
26+
"builddeps": ["build-essential", "wget"],
27+
"buildcmd": [
28+
"uname -a",
29+
"lsb_release -a",
30+
"g++ --version",
31+
"cd",
32+
"wget --no-check-certificate https://github.com/Kitware/CMake/releases/download/v3.14.0/cmake-3.14.0.tar.gz",
33+
"tar xfz cmake-3.14.0.tar.gz",
34+
"cd cmake-3.14.0",
35+
"./bootstrap",
36+
"make -j8",
37+
"cd",
38+
"mkdir build",
39+
"cd build",
40+
"../cmake-3.14.0/bin/cmake /project/repo/checkout",
41+
"make -j8",
42+
"../cmake-3.14.0/bin/ctest -VV -j4 --timeout 10000"
43+
]
44+
},
45+
"fedora24-x86_64": {
46+
"buildenv": "fedora24-x86_64",
47+
"builddeps": ["cmake", "make", "gcc gcc-c++"],
48+
"buildcmd": [
49+
"uname -a",
50+
"cat /etc/fedora-release",
51+
"g++ --version",
52+
"cd",
53+
"mkdir build",
54+
"cd build",
55+
"cmake /project/repo/checkout",
56+
"make -j8",
57+
"ctest -VV -j8"
58+
]
59+
},
60+
"centos7-x86_64": {
61+
"buildenv": "centos7-x86_64",
62+
"builddeps": ["make", "wget", "gcc-c++"],
63+
"buildcmd": [
64+
"uname -a",
65+
"rpm -q centos-release",
66+
"g++ --version",
67+
"cd",
68+
"wget https://github.com/Kitware/CMake/releases/download/v3.14.0/cmake-3.14.0.tar.gz",
69+
"tar xfz cmake-3.14.0.tar.gz",
70+
"cd cmake-3.14.0",
71+
"./bootstrap",
72+
"make -j8",
73+
"cd",
74+
"mkdir build",
75+
"cd build",
76+
"../cmake-3.14.0/bin/cmake /project/repo/checkout",
77+
"make -j8",
78+
"../cmake-3.14.0/bin/ctest -VV -j8"
79+
]
80+
}
81+
}
82+
}

.github/CODEOWNERS

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# JSON for Modern C++ has been originally written by Niels Lohmann.
2+
# Since 2013 over 140 contributors have helped to improve the library.
3+
# This CODEOWNERS file is only to make sure that @nlohmann is requsted
4+
# for a code review in case of a pull request.
5+
6+
* @nlohmann

.github/CONTRIBUTING.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,15 @@
44

55
This project started as a little excuse to exercise some of the cool new C++11 features. Over time, people actually started to use the JSON library (yey!) and started to help improve it by proposing features, finding bugs, or even fixing my mistakes. I am really [thankful](https://github.com/nlohmann/json/blob/master/README.md#thanks) for this and try to keep track of all the helpers.
66

7-
To make it as easy as possible for you to contribute and for me to keep an overview, here are a few guidelines which should help us avoid all kinds of unnecessary work or disappointment. And of course, this document is subject to discussion, so please [create an issue](https://github.com/nlohmann/json/issues/new) or a pull request if you find a way to improve it!
7+
To make it as easy as possible for you to contribute and for me to keep an overview, here are a few guidelines which should help us avoid all kinds of unnecessary work or disappointment. And of course, this document is subject to discussion, so please [create an issue](https://github.com/nlohmann/json/issues/new/choose) or a pull request if you find a way to improve it!
88

99
## Private reports
1010

1111
Usually, all issues are tracked publicly on [GitHub](https://github.com/nlohmann/json/issues). If you want to make a private report (e.g., for a vulnerability or to attach an example that is not meant to be published), please send an email to <mail@nlohmann.me>.
1212

1313
## Prerequisites
1414

15-
Please [create an issue](https://github.com/nlohmann/json/issues/new), assuming one does not already exist, and describe your concern. Note you need a [GitHub account](https://github.com/signup/free) for this.
15+
Please [create an issue](https://github.com/nlohmann/json/issues/new/choose), assuming one does not already exist, and describe your concern. Note you need a [GitHub account](https://github.com/signup/free) for this.
1616

1717
## Describe your issue
1818

@@ -22,7 +22,7 @@ Clearly describe the issue:
2222
- If you propose a change or addition, try to give an **example** how the improved code could look like or how to use it.
2323
- If you found a compilation error, please tell us which **compiler** (version and operating system) you used and paste the (relevant part of) the error messages to the ticket.
2424

25-
Please stick to the [issue template](https://github.com/nlohmann/json/blob/develop/.github/ISSUE_TEMPLATE.md) if possible.
25+
Please stick to the provided issue templates ([bug report](https://github.com/nlohmann/json/blob/develop/.github/ISSUE_TEMPLATE/Bug_report.md), [feature request](https://github.com/nlohmann/json/blob/develop/.github/ISSUE_TEMPLATE/Feature_request.md), or [question](https://github.com/nlohmann/json/blob/develop/.github/ISSUE_TEMPLATE/question.md)) if possible.
2626

2727
## Files to change
2828

@@ -32,7 +32,7 @@ To make changes, you need to edit the following files:
3232

3333
1. [`include/nlohmann/*`](https://github.com/nlohmann/json/tree/develop/include/nlohmann) - These files are the sources of the library. Before testing or creating a pull request, execute `make amalgamate` to regenerate `single_include/nlohmann/json.hpp`.
3434

35-
2. [`test/src/unit-*.cpp`](https://github.com/nlohmann/json/tree/develop/test/src) - These files contain the [Catch](https://github.com/philsquared/Catch) unit tests which currently cover [100 %](https://coveralls.io/github/nlohmann/json) of the library's code.
35+
2. [`test/src/unit-*.cpp`](https://github.com/nlohmann/json/tree/develop/test/src) - These files contain the [doctest](https://github.com/onqtam/doctest) unit tests which currently cover [100 %](https://coveralls.io/github/nlohmann/json) of the library's code.
3636

3737
If you add or change a feature, please also add a unit test to this file. The unit tests can be compiled and executed with
3838

.github/FUNDING.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
custom: http://paypal.me/nlohmann
Lines changed: 22 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,22 @@
1-
---
2-
name: Bug report
3-
about: Create a report to help us improve
4-
5-
---
6-
7-
- What is the issue you have?
8-
9-
- Please describe the steps to reproduce the issue. Can you provide a small but working code example?
10-
11-
- What is the expected behavior?
12-
13-
- And what is the actual behavior instead?
14-
15-
- Which compiler and operating system are you using? Is it a [supported compiler](https://github.com/nlohmann/json#supported-compilers)?
16-
17-
- Did you use a released version of the library or the version from the `develop` branch?
18-
19-
- If you experience a compilation error: can you [compile and run the unit tests](https://github.com/nlohmann/json#execute-unit-tests)?
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: ''
5+
labels: 'kind: bug'
6+
assignees: ''
7+
8+
---
9+
10+
- What is the issue you have?
11+
12+
- Please describe the steps to reproduce the issue. Can you provide a small but working code example?
13+
14+
- What is the expected behavior?
15+
16+
- And what is the actual behavior instead?
17+
18+
- Which compiler and operating system are you using? Is it a [supported compiler](https://github.com/nlohmann/json#supported-compilers)?
19+
20+
- Did you use a released version of the library or the version from the `develop` branch?
21+
22+
- If you experience a compilation error: can you [compile and run the unit tests](https://github.com/nlohmann/json#execute-unit-tests)?
Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,12 @@
1-
---
2-
name: Feature request
3-
about: Suggest an idea for this project
4-
5-
---
6-
7-
- Describe the feature in as much detail as possible.
8-
9-
- Include sample usage where appropriate.
1+
---
2+
name: Feature request
3+
about: Suggest an idea for this project
4+
title: ''
5+
labels: 'kind: enhancement/improvement'
6+
assignees: ''
7+
8+
---
9+
10+
- Describe the feature in as much detail as possible.
11+
12+
- Include sample usage where appropriate.

.github/ISSUE_TEMPLATE/question.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
---
2+
name: Question
3+
about: Ask a question regarding the library.
4+
title: ''
5+
labels: 'kind: question'
6+
assignees: ''
7+
8+
---
9+
10+
- Describe what you want to achieve.
11+
12+
- Describe what you tried.
13+
14+
- Describe which system (OS, compiler) you are using.
15+
16+
- Describe which version of the library you are using (release version, develop branch).

.github/SECURITY.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Security Policy
2+
3+
## Reporting a Vulnerability
4+
5+
Usually, all issues are tracked publicly on [GitHub](https://github.com/nlohmann/json/issues). If you want to make a private report (e.g., for a vulnerability or to attach an example that is not meant to be published), please send an email to <mail@nlohmann.me>. You can use [this key](https://keybase.io/nlohmann/pgp_keys.asc?fingerprint=797167ae41c0a6d9232e48457f3cea63ae251b69) for encryption.

0 commit comments

Comments
 (0)