Bug 96414 - Javadoc of ASTParser#setCompilerOptions(..): mention that setProject(..) resets options
Summary: Javadoc of ASTParser#setCompilerOptions(..): mention that setProject(..) rese...
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.1   Edit
Hardware: PC Windows XP
: P3 trivial (vote)
Target Milestone: 3.1 RC1   Edit
Assignee: Jim des Rivieres CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-05-24 08:25 EDT by Markus Keller CLA
Modified: 2005-05-27 10:35 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Markus Keller CLA 2005-05-24 08:25:31 EDT
N20050523-0010

The javadoc of ASTParser#setProject(..) mentions that this method also calls
ASTParser#setCompilerOptions(..).

There should also be a note in the javadoc of ASTParser#setCompilerOptions(..)
that mentions that setProject(..) and two of the setSource(..) methods reset the
compiler options.
Comment 1 Jim des Rivieres CLA 2005-05-24 14:59:43 EDT
Clarified spec as follows:

/**
 * Sets the compiler options to be used when parsing.
 * <p>
 * The compiler options default to {@link JavaCore#getOptions()}.
 * </p>
 * <p>
 * Note that {@link #setSource(IClassFile)},
 * {@link #setSource(ICompilationUnit)},
 * and {@link #setProject(IJavaProject)} reset the compiler options
 * based on the Java project.
 * </p>
 * 
 * @param options the table of options (key type: <code>String</code>;
 * value type: <code>String</code>), or <code>null</code>
 * to set it back to the default
 */
public void setCompilerOptions(Map options)
Comment 2 Olivier Thomann CLA 2005-05-27 10:35:08 EDT
Verified in I20050526-2000