Issue #394 resolved
created an issue

a lexer for the ABAP programming language.

Comments (14)

  1. adsworth reporter

    There is one little problem with the current implementation. ABAP allows keywords as variable names.

    The following is perfectly legal ABAP:

    DATA data TYPE sflight.
    SELECT * FROM sflight INTO data WHERE carrid = 'BAR'. 

    The current version of the lexer would highlight all ocurrences of data as a keyword. It should only highlight the first occurence as keyword and the other occurences as Name.Variable. I would need to implement a state for nearly all ABAP statements and I currently haven't gone through the trouble.

    Maybe I'll get to it bit by bit.

  2. adsworth reporter

    Replying to [comment:4 gbrandl]:

    Maybe it isn't worth the trouble. (Please don't tell me it is standard practice to use keywords as identifiers...)

    No, it's not standard pratice to use keywords. Though I have seen some SAP demo programs that do. I attached a new patch that fixes some issues.

  3. adsworth reporter

    Replying to [comment:9 gbrandl]:

    Committed in [1e77cfc028a1]. Do you have an example file for the test suite?

    I currently only have an example file which uses demos created by SAP. I'm not sure about making them public. I'll either get some public samples or put something together myself.

  4. Log in to comment