-
Notifications
You must be signed in to change notification settings - Fork 56
Closed
Labels
Description
Hello Colleagues,
I use the ABAP Cleaner daily, and set the automatic adding of spaces between character literals and parentheses.
There are though some other places, where it might be very handy to add spaces around the character literals:
- declarative statements (e.g. in class header - DATA, TYPES, ...)
- value assignments (standalone or in VALUE #(...) statement, if you have multiple fields within the parentheses.
Code snippet:
CLASS myClass DEFINITION
PUBLIC
FINAL
CREATE PUBLIC .
PUBLIC SECTION.
PROTECTED SECTION.
PRIVATE SECTION.
METHODS: myMethod.
CONSTANTS: myconstant TYPE string VALUE'xyz'. " <<<=== declaration
ENDCLASS.
CLASS myClass IMPLEMENTATION.
METHOD mymethod.
DATA mytext TYPE string VALUE'cde'. "<<<=== declaration
DATA: somevariable TYPE string,
BEGIN OF somedata,
text TYPE string,
number TYPE i,
END OF somedata,
sometexts TYPE STANDARD TABLE OF string.
somedata = VALUE #( text ='hsdfsd' number = 10 ). " <<<=== string literal in VALUE statement
somevariable ='abc'. " <<<=== standalone string literal
ENDMETHOD.
ENDCLASS.
Thanks a lot in advance, nice work you do with the tool, I like it very much!
ConjuringCoffee and m-badura