ArrayConstructorExpr extends Expr { @Override public void setChild(int index, Expr expr) { checkBounds(index); args.set(index, expr); } ArrayConstructorExpr(ArrayType arrayType, List<Expr> args); ArrayType getArrayType(); List<Expr> getArgs(); @Override void accept(IAstVisitor visitor); @Override ArrayConstructorExpr clone(); @Override boolean hasChild(IAstNode candidateChild); @Override Expr getChild(int index); @Override void setChild(int index, Expr expr); @Override int getNumChildren();  }
@Test(expected = IndexOutOfBoundsException.class) public void setChildBad() { arrayConstructor.setChild(3, new VariableIdentifierExpr("z")); }