Skip to content

[bean completion proposals] beans of type Object results in no constructor param being generated #1468

Closed

Description

@martinlippert

It looks like if the bean that I select from the completion is of type java.lang.Object, there is no constructor parameter being generated for it and the inserted field gets the name object instead of the name of the bean.

This is the result after applying the completion:

public class TestBean2 {

    private final Object object;

    public void foo() {
        myBean<*>
    }

}

after applying the bean completion for myBean, where myBean is of type java.lang.Object.

Activity

  1. added
    for: eclipse
    for: vscode
    on Feb 6, 2025
  2. added this to the 4.29.0.RELEASE milestone on Feb 6, 2025
  3. BoykoAlex commented on Feb 26, 2025

    @BoykoAlex
    Contributor

    Fixed with 6a9c390. The problem was that field name for a bean was coming from the type simple name rather then bean name in the index.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

for: eclipsefor: vscodetheme: code completiontype: bug

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions