aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2022-03-22 21:34:01 -0700
committerKaz Kylheku <kaz@kylheku.com>2022-03-22 21:34:01 -0700
commit70b0535507439c074bbe6a3b6bb6ad5f7b2db86c (patch)
tree212b5ea2006679a9d128fcf69ca60996b1781744
parenta104327c2fb1b04f14473c713e289e832239c9e3 (diff)
downloadcppawk-70b0535507439c074bbe6a3b6bb6ad5f7b2db86c.tar.gz
cppawk-70b0535507439c074bbe6a3b6bb6ad5f7b2db86c.tar.bz2
cppawk-70b0535507439c074bbe6a3b6bb6ad5f7b2db86c.zip
README: revise bullet 3.
-rw-r--r--README.md20
1 files changed, 14 insertions, 6 deletions
diff --git a/README.md b/README.md
index 08fce62..5e16a7f 100644
--- a/README.md
+++ b/README.md
@@ -51,12 +51,20 @@ and go get it!
files, which easily find each other in the same directory or relative
path. Or macros, for some syntactic sugars.
-3. Though GNU Awk has `@include`, that feature provides no preprocessor
- features and works with GNU Awk only. `cppawk` calls `gawk`, but can
- easily be tweaked to target any Awk; any Awk can have file inclusion.
- There is the possibility of using `#ifdef` to make code
- work on different Awks from one file. (The default cppawk installation uses
- gawk, and also defines `__gawk__` as 1, which you can test for.)
+3. `cppawk` calls `gawk`, but can easily be tweaked to target any Awk; any Awk
+ can have file inclusion. There is the possibility of using `#ifdef` to
+ make code work with different Awks, using their nonportable constructs:
+
+ #if __gawk__
+ GNU Awk specific code
+ #else
+ ...
+ #endif
+
+ The default cppawk installation uses gawk, and also defines `__gawk__`
+ with a value of `1`. (If an installation of `cppawk` is prepared which uses
+ a different awk, it is strongly recommended to define a different symbol to
+ `1`, based on the name: `__mawk__`, and so forth.)
4. Comments. Awk has no comments that don't end at the end of
the line; `cppawk` gives you `/*...*/`.