diff options
author | Sven Gothel <[email protected]> | 2010-11-07 22:09:14 +0100 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2010-11-07 22:09:14 +0100 |
commit | 40ed7595d282f79eb332965c1684bb368674ac36 (patch) | |
tree | cf6dbe45c1eb73f37803d6225463d897308f39d2 /src/java/com/jogamp/gluegen | |
parent | 55f1e7f99df8ee47f1c68627c4eb455c6517c65b (diff) |
PCPP: Add '# <line> <file>' pass through ; Fix NB antlr.jar reference
Diffstat (limited to 'src/java/com/jogamp/gluegen')
-rw-r--r-- | src/java/com/jogamp/gluegen/pcpp/PCPP.java | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/java/com/jogamp/gluegen/pcpp/PCPP.java b/src/java/com/jogamp/gluegen/pcpp/PCPP.java index 987d0a9..95a4b43 100644 --- a/src/java/com/jogamp/gluegen/pcpp/PCPP.java +++ b/src/java/com/jogamp/gluegen/pcpp/PCPP.java @@ -422,7 +422,17 @@ public class PCPP { handleInclude(); shouldPrint = false; } else { - // Unknown preprocessor directive (#pragma?) -- ignore + int line = -1; + try { + // try '# <line> "<filename>"' case + line = Integer.parseInt(w); + String filename = nextWordOrString(); + print("# " + line + " " + filename); + println(); + shouldPrint = false; + } catch (NumberFormatException nfe) { + // Unknown preprocessor directive (#pragma?) -- ignore + } } if (shouldPrint) { print("# "); |