Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

code with comments inside multline comment breaks syntax parsing #62

Open
Baehn opened this issue Oct 27, 2022 · 2 comments
Open

code with comments inside multline comment breaks syntax parsing #62

Baehn opened this issue Oct 27, 2022 · 2 comments
Labels
bug Something isn't working grammar Related to the grammar

Comments

@Baehn
Copy link

Baehn commented Oct 27, 2022

code like below will not parse correctly, due to the comment line inside the code block inside the multiline comment:


/**
 *
 * ```kotlin
 * object Foo {
 *     /** this comment breaks syntax parsing */
 *     const val VAR = "VAL"
 * }
 * ```
 */

 object Foo {
     const val VAR = "VAL"
 }
@brandonspark
Copy link
Contributor

Bump, is there any plan to address this? @fwcd

@fwcd fwcd added bug Something isn't working grammar Related to the grammar labels Oct 6, 2023
@ObserverOfTime
Copy link
Contributor

This has been fixed.

(source_file [1, 0] - [14, 0]
  (multiline_comment [1, 0] - [9, 3])
  (object_declaration [11, 1] - [13, 2]
    (type_identifier [11, 8] - [11, 11])
    (class_body [11, 12] - [13, 2]
      (property_declaration [12, 5] - [12, 26]
        (modifiers [12, 5] - [12, 10]
          (property_modifier [12, 5] - [12, 10]))
        (variable_declaration [12, 15] - [12, 18]
          (simple_identifier [12, 15] - [12, 18]))
        (string_literal [12, 21] - [12, 26])))))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working grammar Related to the grammar
Projects
None yet
Development

No branches or pull requests

4 participants