BalticAmadeus / AblFormatter

Code formatter for Progress OpenEdge (ABL)
Apache License 2.0
6 stars 0 forks source link

COMMENTS formatting #122

Closed eglekaz closed 2 months ago

eglekaz commented 2 months ago

Linear comments do not get indented at the moment

SSaulenas commented 2 months ago

Tree-sitter does not correctly recognize that classBody and body can start and end with a comment. Instead, it only considers comment statements as part of the body after the define statement. For example:

class Class final:
    ///Comment
    define public property prop as decimal initial 3.0 no-undo
        get.
        private set.

    ///Comment

    constructor private Class( ):
        m_NumCusts = 0.
    end.

    ///Comment
end class.

First comment:

Image

Second comment:

Image

Last comment:

Image

eglekaz commented 2 months ago

Copied the description to a similar issue. Closing this one