Skip to content

Optional/mandatory changes

Losicki Mariusz requested to merge jhotdraw-mandatory-fixes into master

Mandatory/Optional

Some tags were wrongly marked as mandatory based on the jhotdraw ASTs. I updated the attributes to match (I was working on it when the mandatory attribute was still there but I switched to using optionals). Here's a non-exhaustive list of fixes and their reason (if some are missing and you're not convinced, I'll provide an example on request).

  • TryStatement
    • catchClauses not mandatory - PrintFileAction ID="234"
  • ArrayCreation
    • dimensions not mandatory - ToggleViewPropertyAction ID="856"
  • CompilationUnit
    • imports not mandatory - AbstractHarmonicRule ID="1"
  • Initializer
    • modifiers not mandatory - JColorWheel ID="3492"
  • InfixExpression
    • missing this, makes leftoperand not mandatory - AbstractDrawing ID="301"
    • missing this, makes rightoperand not mandatory - AbstractApplication ID="4820"
  • ConditionalExpression
    • missing this, makes thenExpression not mandatory - AbstractFigure ID="2005"
  • FieldDeclaration
    • modifiers not mandatory - GeneralPathTip ID="401
  • MethodDeclaration
    • modifiers not mandatory - DefaultDrawingViewTransferHandler ID="80"
  • ForStatement
    • updaters not mandatory - MDIApplication.java ID="712"
    • body not mandatory - TextAreaFigure ID="4542"
    • initializers not mandatory (because no EmptyExpression in AST) - BezierPath ID="6858"
  • TypeDeclaration
    • bodyDeclarations not mandatory - SelectAreaTracker ID="6
    • modifiers not mandatory - Polygon2D ID="15"
  • EnhancedForStatement
    • expression not mandatory (because 'this' missing in AST) - BezierPath ID="8416"
    • body not mandatory - similar to ForStatement
  • SuperConstructorInvocation
    • arguments not mandatory - PaletteTabbedPanelUI ID="290"
  • WhileStatement
    • body not mandatory - StreamPosTokenizer ID="1396"`
  • ...

Merge request reports