Skip to content

Unable to prompt types correctly. #4374

Closed

Description

@fufu1437

Describe the bug
Unable to properly prompt any type without preceding context. For example:

import java.io.*;

public class Test {
    public static void main(String argv[]) {
        File f = new File("null");
        // The first 'File' cannot be prompted normally, but the 'File' after 'new' can be prompted correctly.
    }
}

To Reproduce
Steps to reproduce the behavior:
Normal use of extensions

Any project without a build tool (because I prefer to have full control over the compilation process, so I do not use build tools)

Expected behavior
Properly prompt types such as FileNotFoundException.

Screenshots

Image Image

Environment

  • Operating System: ArchLinux

  • JDK version:
    openjdk version "21.0.10" 2026-01-20 LTS
    OpenJDK Runtime Environment Temurin-21.0.10+7 (build 21.0.10+7-LTS)
    OpenJDK 64-Bit Server VM Temurin-21.0.10+7 (build 21.0.10+7-LTS, mixed mode, sharing)

  • Visual Studio Code version: 1.113.0

  • Java extension version: 1.53.0

Additional Information

Activity

  1. fufu1437 commented on Mar 27, 2026

    @fufu1437
    Author
    Image The text in the image reads "No suggestions." Image
  2. fufu1437 commented on Mar 27, 2026

    @fufu1437
    Author

    Change the JDK version to 26.0.2 2026-03-17, but code completion still does not work properly.

    .log

  3. fufu1437 commented on Mar 27, 2026

    @fufu1437
    Author

    Personal operating system configuration issue

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions