bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Can gperf be made to generate code that will compile on EBCDIC systems?


From: Aharon Robbins
Subject: Can gperf be made to generate code that will compile on EBCDIC systems?
Date: Tue, 24 Mar 2009 12:27:22 +0200

        awk 'BEGIN { print "hello, world" }'

Hi gperf guys!

In gawk, I currently maintain the table of reserved words and built-in
functions as a sorted list that is binary searched.  It's getting to be
medium big and I was considering switching to gperf.

The problem is that gawk can be compiled and run native on EBCDIC systems.
It's a problem since in ASCII "BEGIN" and "END" come at the top of the
table but in EBCDIC they come at the bottom. Initially I simply repeated
the entries inside #ifdef, but recently I switched the code to have the
uppercase entries at the top and to just sort the table once on EBCDIC
systems.

I was wondering if gperf could be made to generate code that would work
on an EBCDIC system so that I could switch to it without having to worry
about character sets.

Please note that I haven't yet investigated what changes would be
required for gawk itself to use gperf-generated code.

Thanks for any feedback,

Arnold Robbins
The gawk guy




reply via email to

[Prev in Thread] Current Thread [Next in Thread]