3 # Copyright © 2023 Nick Bowler
5 # Helper script used by the RRace makefile to combine gen-tree.awk and
6 # gen-strtab.awk inputs into a single source file and build rule.
8 # Usage: awk -f mkstrtab.awk -f gen-strtab.awk input.dat
10 # License WTFPL2: Do What The Fuck You Want To Public License, version 2.
11 # This is free software: you are free to do what the fuck you want to.
12 # There is NO WARRANTY, to the extent permitted by law.
15 if (sub(/^#&/, "\\&")) {
16 # Lines beginning with #& are taken verbatim (with the # removed)
18 } else if (sub(/,$/, "", $1) && !("&"$1 in explicit)) {
19 # Put tree node ids into the strtab, unless explicitly defined earlier.