Community
Participate
Working Groups
Include the part[file](line #) that caused the exception
Before printing the stack trace I changed the code to output the part[file name](line #)
move this code to the framework so it's available to all generators.
The EGLContext now contains a field to store the last EGL_Location. All JavaGen and JavaScriptGen statements pass through ReorganizeCode.reorgCode, in this method I get the EGL_Location Annotation from the statement and write it to the context. In all locations that were using EGLMessage.createMessage, if there is a context available I do EGLContext.getLastStatementLocation which is the current statement that is being generated. This causes the error markers to appear on the EGL line that caused the generation exception. I use the same annotation information when we print a stacktrace. Before we output the stack trace we will output generating:<fully qualified part name>[<part's file name>](line #). If the exception occurs while in pregen or when generating special (non user functions or fields) the line number will be 0 because we have not started processing statements.
changing to Enhancement, as this isn't really a defect.
verified