ClojureScript

Self-host: Macro specs are instrumented

Details

  • Type: Defect Defect
  • Status: Closed Closed
  • Priority: Minor Minor
  • Resolution: Completed
  • Affects Version/s: 1.9.908
  • Fix Version/s: None
  • Component/s: None
  • Labels:
  • Patch:
    Code and Test

Description

If you use cljs.spec.alpha/fdef to define a macro spec, self-host will apply that spec as expected during macroexpansion time. But another unintended consequence is that cljs.spec.test.alpha/instrument will unnecessarily instrument this spec.

Activity

Hide
Mike Fikes added a comment -

The attached patch adds some self-host-conditional code that checks that a Var is not a macro before instrumenting it.
The patch also adds a test. Things pass if applied against master, but for the test to actually be executed in the self-hosted suite, CLJS-2415 will need to be applied.

Show
Mike Fikes added a comment - The attached patch adds some self-host-conditional code that checks that a Var is not a macro before instrumenting it. The patch also adds a test. Things pass if applied against master, but for the test to actually be executed in the self-hosted suite, CLJS-2415 will need to be applied.
Hide
David Nolen added a comment -

Looks like this one needs a rebase.

Show
David Nolen added a comment - Looks like this one needs a rebase.
Hide
Mike Fikes added a comment -

Attaching re-baselined CLJS-2414-2.patch

Show
Mike Fikes added a comment - Attaching re-baselined CLJS-2414-2.patch

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: