2
誰でも説明できますが、下の例で何が問題になっていますか? StackOverflowError例外がスローされるのはなぜですか?アレックス・ミラーは、定義時に::g
を解決しようとs/+
、this Google Groups discussionで指摘したものと同様clojure.spec適合はスタックオーバーフロー例外をスローする
(s/def ::tag keyword?)
(s/def ::s string?)
(s/def ::n number?)
(s/def ::g
(s/cat :tag (s/? ::tag)
:ex (s/alt :string ::s
:number ::n
:and (s/+ ::g)
)))
(s/conform ::g '["abc"])