#92 IfThenElseBlock hides its condition field

closed-fixed
nobody
decompiler (49)
5
2007-01-19
2007-01-17
No

Certain StructuredBlock subclasses have a "cond" field of type Expression. For instance, LoopBlock has a "cond" field that can be obtained by calling LoopBlock.getCondition().

IfThenElseBlock also has a "cond" field but unfortunately it has no getCondition() method. This is a problem for tools built on top of JODE that need access to the condition field.

The fix is easy: Just add a simple accessor method to IfThenElseBlock.java, like this:

public Expression getCondition() {
return cond;
}

Discussion

  • Jochen Hoenicke

    Jochen Hoenicke - 2007-01-19
    • status: open --> closed-fixed
     
  • Jochen Hoenicke

    Jochen Hoenicke - 2007-01-19

    Logged In: YES
    user_id=18252
    Originator: NO

    I added the method as you suggested.

     

Log in to post a comment.