v icon indicating copy to clipboard operation
v copied to clipboard

build error for wasm: unhandled node v.ast.StringInterLiteral

Open alwint3r opened this issue 1 year ago • 0 comments

Describe the bug

V failed building for wasm from a source code with the following code

fn adder(x int, y int) int {
	return x + y
}

fn main() {
	println('${adder(1, 2)}')

        // this works
	// println(adder(1, 2))
}

Error:

wasm error: wasm.expr(): unhandled node: v.ast.StringInterLiteral

Expected Behavior

Build success

Current Behavior

wasm error: wasm.expr(): unhandled node: v.ast.StringInterLiteral

Reproduction Steps

Compile the following V code:

fn adder(x int, y int) int {
	return x + y
}

fn main() {
	println('${adder(1, 2)}')
}
v -b wasm main.v

Possible Solution

No response

Additional Information/Context

No response

V version

V 0.3.3 2597efa, timestamp: 2023-03-07 23:53:56 +0300

Environment details (OS name and version, etc.)

OS: macos, macOS, 12.6.3, 21G419 Processor: 8 cpus, 64bit, little endian, Apple M1 Pro CC version: Apple clang version 14.0.0 (clang-1400.0.29.202)

alwint3r avatar Mar 08 '23 08:03 alwint3r