technomancy / slamhound

Slamhound rips your namespace form apart and reconstructs it.
Other
473 stars 38 forks source link

clojure.lang.PersistentList cannot be cast to clojure.lang.Symbol #85

Open bendlas opened 9 years ago

bendlas commented 9 years ago

I get this error when trying to reconstruct a namespace, which uses undeclared (append ..), as in enlive-html/append.

Here is the stacktrace:

  Show: Clojure Java REPL Tooling Duplicates All  (0 frames hidden)

2. Unhandled clojure.lang.Compiler$CompilerException
   Error compiling: /tmp/form-init2891029221887922796.clj:1:1

                 Compiler.java: 6715  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6460  clojure.lang.Compiler/analyze
                 Compiler.java: 3766  clojure.lang.Compiler$InvokeExpr/parse
                 Compiler.java: 6710  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6696  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6460  clojure.lang.Compiler/analyze
                 Compiler.java: 3766  clojure.lang.Compiler$InvokeExpr/parse
                 Compiler.java: 6710  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6696  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6696  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6460  clojure.lang.Compiler/analyze
                 Compiler.java: 5836  clojure.lang.Compiler$BodyExpr$Parser/parse
                 Compiler.java: 5271  clojure.lang.Compiler$FnMethod/parse
                 Compiler.java: 3900  clojure.lang.Compiler$FnExpr/parse
                 Compiler.java: 6706  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6696  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java:   38  clojure.lang.Compiler/access$200
                 Compiler.java:  560  clojure.lang.Compiler$DefExpr$Parser/parse
                 Compiler.java: 6708  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6696  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6460  clojure.lang.Compiler/analyze
                 Compiler.java: 5836  clojure.lang.Compiler$BodyExpr$Parser/parse
                 Compiler.java: 6154  clojure.lang.Compiler$LetExpr$Parser/parse
                 Compiler.java: 6708  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6460  clojure.lang.Compiler/analyze
                 Compiler.java: 5836  clojure.lang.Compiler$BodyExpr$Parser/parse
                 Compiler.java: 5271  clojure.lang.Compiler$FnMethod/parse
                 Compiler.java: 3900  clojure.lang.Compiler$FnExpr/parse
                 Compiler.java: 6706  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6764  clojure.lang.Compiler/eval
                 Compiler.java: 6756  clojure.lang.Compiler/eval
                 Compiler.java: 6730  clojure.lang.Compiler/eval
                      core.clj: 3076  clojure.core/eval
                    regrow.clj:  116  slam.hound.regrow/check-for-failure
                    regrow.clj:  456  slam.hound.regrow/regrow
                     hound.clj:   16  slam.hound/reconstruct
                          REPL:    1  qms.launcher/eval126383
                 Compiler.java: 6767  clojure.lang.Compiler/eval
                 Compiler.java: 6730  clojure.lang.Compiler/eval
                      core.clj: 3076  clojure.core/eval
                      main.clj:  239  clojure.main/repl/read-eval-print/fn
                      main.clj:  239  clojure.main/repl/read-eval-print
                      main.clj:  257  clojure.main/repl/fn
                      main.clj:  257  clojure.main/repl
                   RestFn.java: 1523  clojure.lang.RestFn/invoke
        interruptible_eval.clj:   67  clojure.tools.nrepl.middleware.interruptible-eval/evaluate/fn
                      AFn.java:  152  clojure.lang.AFn/applyToHelper
                      AFn.java:  144  clojure.lang.AFn/applyTo
                      core.clj:  626  clojure.core/apply
                      core.clj: 1864  clojure.core/with-bindings*
                   RestFn.java:  425  clojure.lang.RestFn/invoke
        interruptible_eval.clj:   51  clojure.tools.nrepl.middleware.interruptible-eval/evaluate
        interruptible_eval.clj:  183  clojure.tools.nrepl.middleware.interruptible-eval/interruptible-eval/fn/fn
        interruptible_eval.clj:  152  clojure.tools.nrepl.middleware.interruptible-eval/run-next/fn
                      AFn.java:   22  clojure.lang.AFn/run
       ThreadPoolExecutor.java: 1142  java.util.concurrent.ThreadPoolExecutor/runWorker
       ThreadPoolExecutor.java:  617  java.util.concurrent.ThreadPoolExecutor$Worker/run
                   Thread.java:  745  java.lang.Thread/run

1. Caused by java.lang.ClassCastException
   clojure.lang.PersistentList cannot be cast to clojure.lang.Symbol

                 Compiler.java:  677  clojure.lang.Compiler$TheVarExpr$Parser/parse
                 Compiler.java: 6708  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6460  clojure.lang.Compiler/analyze
                 Compiler.java: 3766  clojure.lang.Compiler$InvokeExpr/parse
                 Compiler.java: 6710  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6696  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6460  clojure.lang.Compiler/analyze
                 Compiler.java: 3766  clojure.lang.Compiler$InvokeExpr/parse
                 Compiler.java: 6710  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6696  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6696  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6460  clojure.lang.Compiler/analyze
                 Compiler.java: 5836  clojure.lang.Compiler$BodyExpr$Parser/parse
                 Compiler.java: 5271  clojure.lang.Compiler$FnMethod/parse
                 Compiler.java: 3900  clojure.lang.Compiler$FnExpr/parse
                 Compiler.java: 6706  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6696  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java:   38  clojure.lang.Compiler/access$200
                 Compiler.java:  560  clojure.lang.Compiler$DefExpr$Parser/parse
                 Compiler.java: 6708  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6696  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6460  clojure.lang.Compiler/analyze
                 Compiler.java: 5836  clojure.lang.Compiler$BodyExpr$Parser/parse
                 Compiler.java: 6154  clojure.lang.Compiler$LetExpr$Parser/parse
                 Compiler.java: 6708  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6460  clojure.lang.Compiler/analyze
                 Compiler.java: 5836  clojure.lang.Compiler$BodyExpr$Parser/parse
                 Compiler.java: 5271  clojure.lang.Compiler$FnMethod/parse
                 Compiler.java: 3900  clojure.lang.Compiler$FnExpr/parse
                 Compiler.java: 6706  clojure.lang.Compiler/analyzeSeq
                 Compiler.java: 6499  clojure.lang.Compiler/analyze
                 Compiler.java: 6764  clojure.lang.Compiler/eval
                 Compiler.java: 6756  clojure.lang.Compiler/eval
                 Compiler.java: 6730  clojure.lang.Compiler/eval
                      core.clj: 3076  clojure.core/eval
                    regrow.clj:  116  slam.hound.regrow/check-for-failure
                    regrow.clj:  456  slam.hound.regrow/regrow
                     hound.clj:   16  slam.hound/reconstruct
                          REPL:    1  qms.launcher/eval126383
                 Compiler.java: 6767  clojure.lang.Compiler/eval
                 Compiler.java: 6730  clojure.lang.Compiler/eval
                      core.clj: 3076  clojure.core/eval
                      main.clj:  239  clojure.main/repl/read-eval-print/fn
                      main.clj:  239  clojure.main/repl/read-eval-print
                      main.clj:  257  clojure.main/repl/fn
                      main.clj:  257  clojure.main/repl
                   RestFn.java: 1523  clojure.lang.RestFn/invoke
        interruptible_eval.clj:   67  clojure.tools.nrepl.middleware.interruptible-eval/evaluate/fn
                      AFn.java:  152  clojure.lang.AFn/applyToHelper
                      AFn.java:  144  clojure.lang.AFn/applyTo
                      core.clj:  626  clojure.core/apply
                      core.clj: 1864  clojure.core/with-bindings*
                   RestFn.java:  425  clojure.lang.RestFn/invoke
        interruptible_eval.clj:   51  clojure.tools.nrepl.middleware.interruptible-eval/evaluate
        interruptible_eval.clj:  183  clojure.tools.nrepl.middleware.interruptible-eval/interruptible-eval/fn/fn
        interruptible_eval.clj:  152  clojure.tools.nrepl.middleware.interruptible-eval/run-next/fn
                      AFn.java:   22  clojure.lang.AFn/run
       ThreadPoolExecutor.java: 1142  java.util.concurrent.ThreadPoolExecutor/runWorker
       ThreadPoolExecutor.java:  617  java.util.concurrent.ThreadPoolExecutor$Worker/run
                   Thread.java:  745  java.lang.Thread/run