If possible, rewrites the list to a union expression. @param cc compilation context @return union or original expression @throws QueryException query exception
(final CompileContext cc)
| 259 | * @throws QueryException query exception |
| 260 | */ |
| 261 | public Expr toUnion(final CompileContext cc) throws QueryException { |
| 262 | return seqType().type instanceof NodeType ? |
| 263 | cc.replaceWith(this, new Union(info, exprs)).optimize(cc) : this; |
| 264 | } |
| 265 | |
| 266 | /** |
| 267 | * If possible, rewrites the list to a range sequence. |
no test coverage detected