Convex-Dev / convex

Convex Main Repository - Decentralised platform for the Internet of Value
https://convex.world
Other
90 stars 27 forks source link

Cumulative ignore reader macros #264

Open helins opened 2 years ago

helins commented 2 years ago

Not top priority but Clojure allows to chain several #_. For instance, the following fails with the Convex Reader while the Clojure Reader would effectively ignore both forms:

#_ #_ :foo :bar

Sometimes useful.

mikera commented 2 years ago

Hmmm the intention is to ignore both? Makes sense I guess if the inner ignore is considered as "nested".

helins commented 2 years ago

Yes, you can't "ignore ignoring", they have a cumulative effect. Since there are 2 #_ in the example, the next 2 forms afterwards should be ignored.

Subtle touch, granted, but sometimes useful during dev. Allows for quickly ignoring forms in a row.