https://kotlinlang.org logo
#compiler
Title
# compiler
j

jw

10/18/2023, 2:57 PM
I'm trying to fix a JS lowering bug. How can I assert on the generated JS? I see there's CHECK_ comments which assert against function calls, but I want to check whether an `if`/`do`/`while` is present or a
for
d

dmitriy.novozhilov

10/18/2023, 3:00 PM
cc @bashor
b

bashor

10/18/2023, 3:08 PM
You can find existing directives here. If you miss something you can try to write another one, but before, it might worth sharing what are you trying to fix and how do you want to test it. cc @anton.bannykh @Artem Kobzar
j

jw

10/18/2023, 3:13 PM
I'm looking at https://youtrack.jetbrains.com/issue/KT-62652 It also seems slightly broken for JVM, at least with steps https://youtrack.jetbrains.com/issue/KT-59115
a

Artem Kobzar

10/18/2023, 4:27 PM
I don't feel we have such comments, but you can easily define it in
DirectiveTestUtils
. As a reference, you can check how
CHECK_COMMENT_EXISTS
is defined.