Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
AW: [jdt-ui-dev] SEF Refactoring

-----Ursprüngliche Nachricht-----
Von: jdt-ui-dev-admin@xxxxxxxxxxx
[mailto:jdt-ui-dev-admin@xxxxxxxxxxx]Im Auftrag von adam kiezun
Gesendet: Dienstag, 11. Dezember 2001 11:07
An: jdt-ui-dev@xxxxxxxxxxx
Betreff: Re: [jdt-ui-dev] SEF Refactoring


Hi Adam

> <- compound assignments>
> are now handled in the following way:
>
> field += expr;  =>  setField(getField() + expr);

<some other things to consider - just from the top of my head:

1. field ^= expr  (and others operators (in compound assignement and
elsewhere)
 like %, /, !,  >>, <<, >>>, &, |, *, ~)>

already implemented + was just an example

<2. remember about operator prorities:
field *= 0 + 1 must be transformed to sth like:
set(get() * (1 + 2))>

oops, forgot that! good point!
I think I should set parentheses around the expression

<3. what about stuff like:

if ((field = expr1) == expr2){
}>

in this case the setter returns a value

<i think, simply using a setter will not work here.
same as:

field += (field = 2);

or

field += (field *= 2);>

(see above)

<or sth else of that sort

4. similar case for boolean:

if (booleanField = false){  //<< assignment!
}>

(see above)


<if i come up with something more i'll let you know
a.>

yes, very good
thanx
  Jens

_______________________________________________
jdt-ui-dev mailing list
jdt-ui-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/jdt-ui-dev



Back to the top