Skip to content

using multiline expressions uses newline and \n instead of just \n #4

Open
@rsa17826

Description

@rsa17826
\nprint(f'a{"asd"}{'asd'}')
^

SyntaxError: Invalid or unexpected token
    at TracingChannel.traceSync (node:diagnostics_channel:322:14)
    at wrapModuleLoad (node:internal/modules/cjs/loader:220:24)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:170:5)
    at node:internal/main/run_main_module:36:49

Node.js v22.14.0
  File "test2", line 5
    lambda: eval("alert(\"a\"+`asd`+'asd')
                 ^
SyntaxError: unterminated string literal (detected at line 5)
npx polycompiler test.js test.py test2 ; node test.js ; py -3.12 test.py ; node test2 ; py -3.12 test2

test.js
test.py
test2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions