Bug 29768 - Ajde not honouring -source14 (-1.4) option
Summary: Ajde not honouring -source14 (-1.4) option
Status: RESOLVED FIXED
Alias: None
Product: AspectJ
Classification: Tools
Component: IDE (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Adrian Colyer CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on: 29769
Blocks:
  Show dependency tree
 
Reported: 2003-01-19 11:38 EST by Adrian Colyer CLA
Modified: 2003-01-31 16:00 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Adrian Colyer CLA 2003-01-19 11:38:12 EST
I've tracked the correct setting of the 1.4 source level option through AJDT
into Ajde. If I enableLogging( ) in Ajde, it even prints out correctly that
source14 is set to true, and appears to set the correct property in the 
CompilerAdapter Map. However, the compile itself is not honoring this flag.

Simplest test is to compile any source file with an assert in it. 

I've assigned this bug to myself(!) for now - though if anyone fixes it before
I get to it then that's fine ;). This option works fine from the command line, 
so I'll track down how the options are processed there and see what's different 
from the Ajde route. For the time being, this option will not work from any of
the IDEs.
Comment 1 Adrian Colyer CLA 2003-01-20 14:56:18 EST
Tracked this one down...
When performing a command-line compile, options are set through (a) the
constructor of org.eclipse.jdt.internal.compiler.batch.Main, and then through
the configure() method of the same. When driven through Ajde, the options are
set through a different route where the option processing is much less 
comprehensive: org.aspectj.ajde.internal.CompilerAdapter sets the Compliance 
level to 1.4 in reponse to a -source14 option, but fails to also set the 
[eclipse] -source option to 1.4 as well (which configure does()). This later 
causes the AjParser to be incorrectly instantiated with assertMode = false.

I'm not planning to patch this in isolation, since the proper fix is to add
full support for the new AspectJ 1.1 options (including -1.4) in Ajde. This 
work is nearly complete in my local copy, but I want to run some more tests yet 
before submitting.
Comment 2 Adrian Colyer CLA 2003-01-31 16:00:24 EST
Fixed now that Mik has integrated the patches for 29769