From 0001e6aa1252495162ba89b7c2ba332945779dc7 Mon Sep 17 00:00:00 2001 From: "Keith A. Lewis" Date: Thu, 13 Jun 2024 14:01:22 -0400 Subject: [PATCH] counted ponter range for test --- fms_iterable.t.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/fms_iterable.t.cpp b/fms_iterable.t.cpp index 3220ada..6ede76e 100644 --- a/fms_iterable.t.cpp +++ b/fms_iterable.t.cpp @@ -353,6 +353,15 @@ int test_pointer() { ++p; assert(!p); } + { + int i[] = { 1, 2, 3 }; + pointer p(i, 3); + int j = 1; + for (const auto& pi : p) { + assert(pi == j); + ++j; + } + } return 0; }