From b1a37815d0d1a8cbc9f980f20ddafaa29b5e503c Mon Sep 17 00:00:00 2001 From: Jacob Bachmeyer Date: Tue, 29 Nov 2022 21:48:48 -0600 Subject: Fix incorrect documentation --- ChangeLog | 6 ++++++ doc/dejagnu.texi | 10 ++++++---- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index a74fce5..c619837 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2022-11-29 Jacob Bachmeyer + + * doc/dejagnu.texi (C++ unit testing API): Fix incorrect + documentation. The C and C++ interfaces share the same global + counters, as do all C++ TestState objects. + 2022-11-28 Jacob Bachmeyer * dejagnu.h: Remove _DEJAGNU_WAIT_ conditional and revise comment diff --git a/doc/dejagnu.texi b/doc/dejagnu.texi index deeb46d..0b6777b 100644 --- a/doc/dejagnu.texi +++ b/doc/dejagnu.texi @@ -2656,10 +2656,12 @@ as the message to be displayed. There currently is no support for formatted output in the C++ API; build the desired string before passing it to these functions. -Note that the C API is also available in C++ unit test programs; using -both will cause confusion because each @code{TestState} object carries -its own set of summary counters, while the C API has an independent -global set of summary counters. +Note that the C API is also available in C++ unit test programs; all +@code{TestState} objects and the C API share the same global set of +summary counters. Also note that a single global @code{TestState} +object should be used, since the constructor clears the summary +counters and the @code{totals} method is automatically called when a +@code{TestState} object is destroyed. The @code{TestState} class supports the following instance methods: -- cgit v1.2.3