Community
Participate
Working Groups
Philppe, as discussed at EclipseCon Tom, this will ease the semantic coloring of autoboxing.
any news here? I don't want to nag, but this might be API relevant...
olivier - how doable is this ? Expression#isBoxed()/isUnboxed() ?
I think this is doable if we consider that this is available only when bindings are requested. I could do it lazily by using the binding resolver. If the binding resolution is disabled, then both methods would always return false. Is this ok?
I will do it the same way I handled the constant value. Jim, could you please put the corresponding method API and javadoc? Then reassign it to me and I will take care of the implementation.
Added specs for 2 new API methods on o.e.jdt.core.dom.Expression: /** * Returns whether this expression node is the site of a boxing * conversion (JLS3 5.1.7). This information is available only * when bindings are requested when the AST is being built. * * @return <code>true</code> if this expression is the site of a * boxing conversion, or <code>false</code> if either no boxing conversion * is involved or if bindings were not requested when the AST was created * @since 3.1 */ public final boolean resolveBoxing(); /** * Returns whether this expression node is the site of an unboxing * conversion (JLS3 5.1.8). This information is available only * when bindings are requested when the AST is being built. * * @return <code>true</code> if this expression is the site of an * unboxing conversion, or <code>false</code> if either no unboxing * conversion is involved or if bindings were not requested when the * AST was created * @since 3.1 */ public final boolean resolveUnboxing(); Olivier, over to you
Fixed and released in HEAD. Regression tests added in ASTConverter15Test.test0153/0154.
Verified in 20050330-0500