Static analysis of PostScript code

It is pointed out that stack-based languages, such as PostScript, present a major challenge to static analysis techniques because of their almost unlimited polymorphism. A regular expression notation that is used to represent allowed combinations of types on the stack at different points in a PostScript program is introduced. An abstract interpretation algorithm can then be used to perform static-type analysis. The analysis has applications in detecting probable errors in the PostScript code or, ultimately, in permitting full or partial compilation of portions of code.<<ETX>>