From 4f69be80d6f27b0d6d7069514d94ea332e25f113 Mon Sep 17 00:00:00 2001 From: Niels Lohmann Date: Sun, 4 Oct 2026 18:20:20 +0200 Subject: [PATCH] Clarify wording in diff documentation (#5759) Signed-off-by: Niels Lohmann --- docs/mkdocs/docs/api/basic_json/diff.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/mkdocs/docs/api/basic_json/diff.md b/docs/mkdocs/docs/api/basic_json/diff.md index fb6683ec8..ae22454dd 100644 --- a/docs/mkdocs/docs/api/basic_json/diff.md +++ b/docs/mkdocs/docs/api/basic_json/diff.md @@ -8,7 +8,7 @@ static basic_json diff(const basic_json& source, Creates a [JSON Patch](http://jsonpatch.com) so that value `source` can be changed into the value `target` by calling [`patch`](patch.md) function. -For two JSON values `source` and `target`, the following code yields always `#!cpp true`: +For two JSON values `source` and `target`, the following code always yields `#!cpp true`: ```cpp source.patch(diff(source, target)) == target; ``` @@ -27,7 +27,7 @@ a JSON patch to convert the `source` to `target` ## Exception safety -Strong guarantee: if an exception is thrown, there are no changes in the JSON value. +Strong guarantee: `source` and `target` are never modified. ## Complexity