Skip to content

Rule "Remove space before commas and period" duplicates template comment in function module  #348

@ConjuringCoffee

Description

@ConjuringCoffee

Hi Jörg-Michael, the rule "Remove space before commas and period" causes a problem in function modules without parameters.

Example:

FUNCTION z_test.
  WRITE 'hello world'.
ENDFUNCTION.

When this function module is saved, a comment is automatically added by SAP standard:

FUNCTION Z_TEST
 " You can use the template 'functionModuleParameter' to add here the signature!
.

  WRITE 'hello world'.
ENDFUNCTION.

Ignoring the infuriating grammar issue in the comment, this is how it looks like after the ABAP Cleaner is executed:

FUNCTION z_test.
  " You can use the template 'functionModuleParameter' to add here the signature!

  WRITE 'hello world'.
ENDFUNCTION.

When saving again, the comment is added once again:

FUNCTION Z_TEST
 " You can use the template 'functionModuleParameter' to add here the signature!
.

  " You can use the template 'functionModuleParameter' to add here the signature!

  WRITE 'hello world'.
ENDFUNCTION.

This can be repeated indefinitely.

These are the options I used:
image

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions