Skip to content

Bug: Keyword text is not taken as keyword when letters are entered as value #95

Closed

Description

@jan-jezek

The rule "Convert upper and lower case" is not working correctly for keyword "text", if the value has any letter in it.
Imagine two situations:
WRITE text-042
WRITE text-a42
For the first one "text" will be converted to "TEXT" with default setting.
But in the second case "text" is not converted.

IMHO this is bug as Pretty Print converts it to upper case and abaplint reports it as error if not converted.

image

Activity

  1. self-assigned this
    on Sep 2, 2023
  2. jmgrassau commented on Sep 2, 2023

    @jmgrassau
    Member

    Hi Jan,

    thanks for reporting this!

    For some background: Code bits that aren't separated with a space – such as lo_any_instance->any_method( or ms_struc-component-subcomponent – are usually stored in one single token in ABAP cleaner, because except for display colors, there is no reason to ever tear them apart. In this case, however, some special processing was needed, because TEXT-a42 contains both a keyword and an identifier (unlike the other examples above).

    The issue will be fixed in the next release, and coloring is now also adjusted to ADT:

    image

    As in ADT, the result depends on the settings for keywords and identifiers, so you could also get:

    image

    image

    Kind regards,
    Jörg-Michael

  3. jmgrassau commented on Sep 4, 2023

    @jmgrassau
    Member

    Hi Jan,

    thanks again for opening this issue! This should now be fixed with version 1.5.3, which was just released.

    Kind regards,
    Jörg-Michael

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

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