Simple query errors on combination of OR, AND and free-text search (advanced query version works)

Example query is:

{{query (and (or [[some-page]] [[another-page]]) "foo")}}

Error:

[frontend.components.query] #error {:message “Cannot parse binding, expected (bind-scalar | bind-tuple | bind-coll | bind-rel)”, :data {:error :parser/binding, :form block-content}}
Error: Cannot parse binding, expected (bind-scalar | bind-tuple | bind-coll | bind-rel)
at new $APP.$cljs$core$ExceptionInfo$$ (file:///tmp/.mount_logseqQFZXWJ/resources/app/js/main.js:11135:25)
at $APP.$cljs$core$ex_info$$.$cljs$core$IFn$_invoke$arity$3$ (file:///tmp/.mount_logseqQFZXWJ/resources/app/js/main.js:108265:10)
at $APP.$cljs$core$ex_info$$.$cljs$core$IFn$_invoke$arity$2$ (file:///tmp/.mount_logseqQFZXWJ/resources/app/js/main.js:108262:36)
at $datascript$parser$parse_binding$$ (file:///tmp/.mount_logseqQFZXWJ/resources/app/js/main.js:30101:35)
at $datascript$parser$parse_tuple_el$$ (file:///tmp/.mount_logseqQFZXWJ/resources/app/js/main.js:30052:294)
at file:///tmp/.mount_logseqQFZXWJ/resources/app/js/main.js:29875:210
at $cljs$core$seq_reduce$cljs$0core$0IFn$0_invoke$0arity$03$$ (file:///tmp/.mount_logseqQFZXWJ/resources/app/js/main.js:8371:328)
at $APP.$JSCompiler_prototypeAlias$$.$cljs$core$IReduce$_reduce$arity$3$ (file:///tmp/.mount_logseqQFZXWJ/resources/app/js/main.js:97547:10)
at $APP.$cljs$core$reduce$$.$cljs$core$IFn$_invoke$arity$3$ (file:///tmp/.mount_logseqQFZXWJ/resources/app/js/main.js:96539:212)
at $datascript$parser$parse_seq$$ (file:///tmp/.mount_logseqQFZXWJ/resources/app/js/main.js:29874:92)

What works:

{{query (and (or [[some-page]]) "foo")}}
{{query (or [[some-page]] [[another-page]]) )}}
{{query "foo" }}

Hence the combination of boolean operators and/or and free-text might be the cause.

Update: This error also exists in v0.9.1. What’s wrong here?
Update2: The advanced query equivalent works without any issues:

#+BEGIN_QUERY
{
:query [
  :find  (pull ?b[*])
  :where
    (or [?p :block/name "some-page"] [?p :block/name "another-page"])
    [?b :block/path-refs ?p]
    [?b :block/content ?c]
    [(clojure.string/includes? ?c "foo")]
]
}
#+END_QUERY