Skip to content

Type checker fails to check method returns #75

Closed

Description

@mattcce

MWE (type-checker does not throw errors):

class C {
    public int method() {
    }
    
    public static void main(String[] args) {
        C c = new C();
        
        int x = c.method();
    }
}

The above should not pass type-checking; method does not return an int along all paths.

Activity

  1. added theissue type on Jun 17, 2025
  2. kjw142857 commented on Sep 30, 2026

    @kjw142857
    Contributor

    It now throws a ClassFormatError

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

    bugSomething isn't working

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions