diff options
author | Sven Gothel <[email protected]> | 2015-03-07 08:25:36 +0100 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2015-03-07 08:25:36 +0100 |
commit | eca019cdea4017227e951d8a9eb30cb34fca4a07 (patch) | |
tree | 214e4837e6f448873c03c886adb2ccf2af7782ab /src/java/com/jogamp/gluegen/structgen | |
parent | 6a0822b03de2976c5bc37544c50e70094eeb94a7 (diff) |
Bug 1134 - Pass ASTLocationTag to all types, used for GlueGenException
Enhances semantic exception in code generation
by adding the AST location of the type or function declaration.
Diffstat (limited to 'src/java/com/jogamp/gluegen/structgen')
-rw-r--r-- | src/java/com/jogamp/gluegen/structgen/CStructAnnotationProcessor.java | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/java/com/jogamp/gluegen/structgen/CStructAnnotationProcessor.java b/src/java/com/jogamp/gluegen/structgen/CStructAnnotationProcessor.java index c4dedb7..7ccfd1b 100644 --- a/src/java/com/jogamp/gluegen/structgen/CStructAnnotationProcessor.java +++ b/src/java/com/jogamp/gluegen/structgen/CStructAnnotationProcessor.java @@ -131,7 +131,11 @@ public class CStructAnnotationProcessor extends AbstractProcessor { if( f.exists() ) { return f; } - } catch (final IOException e) { if(DEBUG) { System.err.println("Caught "+e.getClass().getSimpleName()+": "+e.getMessage()); /* e.printStackTrace(); */ } } + } catch (final IOException e) { + if(DEBUG) { + System.err.println("Caught "+e.getClass().getSimpleName()+": "+e.getMessage()); /* e.printStackTrace(); */ + } + } return null; } @@ -263,6 +267,9 @@ public class CStructAnnotationProcessor extends AbstractProcessor { } catch (final FileNotFoundException ex) { throw new RuntimeException("input file not found", ex); } + if( DEBUG ) { + GlueGen.setDebug(true); + } new GlueGen().run(reader, filename, AnnotationProcessorJavaStructEmitter.class, includePaths, cfgFiles, outputPath1, false /* copyCPPOutput2Stderr */); |