From 9ca047b49e2486875525eb9111aa32dedf6b3883 Mon Sep 17 00:00:00 2001 From: Andreas Scherer Date: Sun, 18 Oct 2015 10:08:59 +0200 Subject: [PATCH] Fix note on ranges. --- CppCoreGuidelines.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CppCoreGuidelines.md b/CppCoreGuidelines.md index 4dab763..36a40d4 100644 --- a/CppCoreGuidelines.md +++ b/CppCoreGuidelines.md @@ -2540,7 +2540,7 @@ Informal/non-explicit ranges are a source of errors. ##### Note -Ranges are extremely common in C++ code. Typically, they are implicit and their correct use is very hard to ensure. In particular, given a pair of arguments `(p, n)` designating an array [`p`:`p+n`), it is in general impossible to know if there really are n elements to access following `*p`. `span` and `span_p` are simple helper classes designating a [p:q) range and a range starting with p and ending with the first element for which a predicate is true, respectively. +Ranges are extremely common in C++ code. Typically, they are implicit and their correct use is very hard to ensure. In particular, given a pair of arguments `(p, n)` designating an array [`p`:`p+n`), it is in general impossible to know if there really are `n` elements to access following `*p`. `span` and `span_p` are simple helper classes designating a [`p`:`q`) range and a range starting with `p` and ending with the first element for which a predicate is true, respectively. ##### Note