aboutsummaryrefslogtreecommitdiffstats
path: root/doc/gawk.texi
diff options
context:
space:
mode:
authorArnold D. Robbins <arnold@skeeve.com>2017-11-08 21:57:05 +0200
committerArnold D. Robbins <arnold@skeeve.com>2017-11-08 21:57:05 +0200
commita5397f50278d484584b4c157d0deafe72bed32b4 (patch)
tree36a3b9b0d40efaaa5cb5fcf3e41745efa8078f40 /doc/gawk.texi
parent67daaccf1c28720654f70c2c570d81d472a88211 (diff)
parent19905e061994bab83ffdce30dab36cea12e68fe4 (diff)
downloadegawk-a5397f50278d484584b4c157d0deafe72bed32b4.tar.gz
egawk-a5397f50278d484584b4c157d0deafe72bed32b4.tar.bz2
egawk-a5397f50278d484584b4c157d0deafe72bed32b4.zip
Merge branch 'gawk-4.2-stable'
Diffstat (limited to 'doc/gawk.texi')
-rw-r--r--doc/gawk.texi16
1 files changed, 10 insertions, 6 deletions
diff --git a/doc/gawk.texi b/doc/gawk.texi
index 0485a566..2913673c 100644
--- a/doc/gawk.texi
+++ b/doc/gawk.texi
@@ -32888,13 +32888,18 @@ The @code{val_type} member indicates what kind of value the
Using these macros makes accessing the fields of the @code{awk_value_t} more
readable.
+@item enum AWK_NUMBER_TYPE @{
+@itemx @ @ @ @ AWK_NUMBER_TYPE_DOUBLE,
+@itemx @ @ @ @ AWK_NUMBER_TYPE_MPFR,
+@itemx @ @ @ @ AWK_NUMBER_TYPE_MPZ
+@itemx @};
+This @code{enum} is used in the following structure for defining the
+type of numeric value that is being worked with. It is declared at the
+top level of the file so that it works correctly for C++ as well as for C.
+
@item typedef struct awk_number @{
@itemx @ @ @ @ double d;
-@itemx @ @ @ @ enum AWK_NUMBER_TYPE @{
-@itemx @ @ @ @ @ @ @ @ AWK_NUMBER_TYPE_DOUBLE,
-@itemx @ @ @ @ @ @ @ @ AWK_NUMBER_TYPE_MPFR,
-@itemx @ @ @ @ @ @ @ @ AWK_NUMBER_TYPE_MPZ
-@itemx @ @ @ @ @} type;
+@itemx @ @ @ @ enum AWK_NUMBER_TYPE type;
@itemx @ @ @ @ void *ptr;
@itemx @} awk_number_t;
This represents a numeric value. Internally, @command{gawk} stores
@@ -32909,7 +32914,6 @@ in data received from @command{gawk}. In addition, by examining the
member is either a GMP integer (type @code{mpz_ptr}), or an MPFR
floating-point value (type @code{mpfr_ptr_t}), and cast it appropriately.
-
@item typedef void *awk_scalar_t;
Scalars can be represented as an opaque type. These values are obtained
from @command{gawk} and then passed back into it. This is discussed