tools.namespace ignores ns form dependencies inside vectors

Description

Cross reference:

For example, tools.logging has this ns form (metadata omitted):

tools.namespace ignores these dependencies, only processing those that are in list subforms of the ns form.

Not sure if the best way to handle this is to update tools.logging or tools.namespace. tools.logging seems pretty unusual in using vectors like this, but the Clojure compiler seems to accept it just fine.

Environment

None

Activity

Show:
Stuart Sierra
August 24, 2014, 7:29 PM

The ns macro docstring is quite clear that references inside it should be lists. I've seen a lot of weird ns forms, and this is the first time I've seen vectors used this way.

I would say I'm surprised that vectors work here, except nothing weird about the ns macro surprises me any more.

Andy Fingerhut
December 23, 2014, 2:46 AM

Temporarily reopening the ticket just to assign a patch for possible consideration. Will return it to the state I found it in when done.

Andy Fingerhut
December 23, 2014, 2:47 AM

Proposed patch tns-21-v1.patch dated Dec 22 2014 would enable tools.namespace to recognize dependencies in ns forms where the references are vectors, in addition to lists.

Stuart Sierra
January 30, 2015, 3:43 PM
Stuart Sierra
February 1, 2015, 3:39 PM

Included in release version 0.2.9

Completed

Assignee

Stuart Sierra

Reporter

Andy Fingerhut

Labels

None

Approval

None

Patch

Code and Test

Priority

Minor