Skip to content

Setting to modify/remove TODO Auto-generated method stub comments #2963

Closed

Description

@SethFalco

When we click Add unimplemented methods, it includes a comment: // TODO Auto-generated method stub.

It's a small thing, but it's getting a little annoying to remove that comment in every instance, especially with large interfaces. ^-^'

There's already the throw new UnsupportedOperationException so I can decide for myself from there if it needs to be implemented or not, but including the comment just adds an unnecessary step when writing new implementations.

Could an option please be introduced to override/remove the comment?

Example:

public class Test implements Map {

    @Override
    public int size() {
        // TODO Auto-generated method stub
        throw new UnsupportedOperationException("Unimplemented method 'size'");
    }

    @Override
    public boolean isEmpty() {
        // TODO Auto-generated method stub
        throw new UnsupportedOperationException("Unimplemented method 'isEmpty'");
    }

    // …
} 
Environment
  • Operating System: Debian 11
  • JDK version: 11
  • Visual Studio Code version: 1.75.1
  • Java extension version: 1.15.0

Activity

  1. iKollor commented on Jan 7, 2024

    @iKollor

    Bump!

  2. jasin08 commented on Mar 24, 2025

    @jasin08

    +1

  3. iwangbowen commented on Mar 24, 2025

    @iwangbowen

    We need this setting

  4. added this to the End of July 2026 milestone on Jul 14, 2026
  5. datho7561 commented on Jul 14, 2026

    @datho7561
    Contributor

    @MeherSru do you mind commenting on this issue so that I can assign you to it?

  6. MeherSru commented on Jul 15, 2026

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

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions