Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

cljr-add-stubs fails over :import-ed Java classes #479

Copy link
Copy link
Open
@vemv

Description

@vemv
Issue body actions

Expected behavior

cljr-add-stubs will succesfully complete a reify for a Java class that has been :imported, i.e. the symbol is not package-qualified.

Actual behavior

Errors with Can't find interface IntConsumer

Steps to reproduce the problem

  • (:import java.util.function.IntConsumer)
  • type (reify IntConsumer) in a clojure buffer
  • Place POINT over IntConsumer
  • Invoke cljr-add-stubs normally (I use hydra)

clj-refactor.el version information

This repo @ master

Analysis

When there's no prefix (which is the case with :imported classes), the following LOC is executed:

(format "%s/%s" (cider-current-ns) interface)))

which appears to mistakenly fill IntConsumer with the equivalent of (ns-name *ns*) instead of the actual java package.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.