Levi
Levi
SCSWC Community
Created by Shahryar on 1/12/2025 in #questions
Emitter in SWC does not add expected space after '=>' in Arrow Functions
8 replies
SCSWC Community
Created by Shahryar on 1/12/2025 in #questions
Emitter in SWC does not add expected space after '=>' in Arrow Functions
Why do you need it to have a space? This sounds like an XY problem
8 replies
SCSWC Community
Created by herman.3682 on 12/25/2024 in #questions
Parsing error
I don’t believe that code is valid in modules
5 replies
SCSWC Community
Created by herman.3682 on 12/25/2024 in #questions
Parsing error
You must be parsing as module. Parsing as script works for me
5 replies
SCSWC Community
Created by Levi on 3/8/2024 in #questions
How to test a visitor that uses visit_mut_script?
I’ve made an issue for now, we can perhaps discuss this further and see if changing it would break anything if you are interested
4 replies
SCSWC Community
Created by Levi on 3/8/2024 in #questions
How to test a visitor that uses visit_mut_script?
So after a bit of digging it seems like visit_mut_module, visit_mut_script and visit_mut_program can be called if you use parse_program (I think?) but not parse_module which is what test_transform seems to use. Should test_transform maybe use parse_program instead? I think this should probably be the case as a test case could be either a module or a script but right now it's assuming it's always a module which I think is bad, parse_program doc states: Returns Module if it's a module and returns Script if it's not a module. so therefor test_transform should probably use parse_program correct?
4 replies