Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 358211

Summary: [traceability] Invalid positions of the traceability information for the indentation of templates
Product: [Modeling] Acceleo Reporter: Stephane Begaudeau <stephane.begaudeau>
Component: CoreAssignee: Project Inbox <acceleo-inbox>
Status: CLOSED WONTFIX QA Contact:
Severity: normal    
Priority: P3    
Version: 3.2   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:
Bug Depends on:    
Bug Blocks: 365555    

Description Stephane Begaudeau CLA 2011-09-20 05:53:34 EDT
This module:

[module generateJava('http://www.eclipse.org/uml2/3.0.0/UML')/]

[template public generateClass(c : Class)]
[comment @main /]
[file ('test.txt', false)]
[c.generateClassBody()/]
[/file]
[/template]

[template public generateClassBody(c : Class)]
    [c.genOperations()/]
[/template]

[template public genOperations(aClass : Class)]
[for (s1 : String | Sequence{'bacon is awesome'})]
// [protected ('caramel')]
[for (s2 : String | Sequence{s1})]
[s2/]
[/for]
// [/protected]
[/for]
[/template]

Produce invalid traceability information because this template:
[template public generateClassBody(c : Class)]
    [c.genOperations()/]
[/template]

Will put the traceability information of the 4 spaces at the beginning of the line at the end of the line generated like this (see '[...]'):
[    ]// Start of user code cara[mel\n]
    bacon is awes[ome\n]
    // End of user c[ode\n]
Comment 1 Stephane Begaudeau CLA 2014-05-20 08:08:42 EDT
This issue will not be fixed and this component will be deprecated.