mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-14 07:53:40 +00:00
compiler: only support //go:wasmimport on declared functions
Don't support this pragma on defined functions. It is only meant for importing, not for exporting.
This commit is contained in:
committed by
Ron Evans
parent
31043628d8
commit
17bc0d6663
Vendored
+7
@@ -59,6 +59,13 @@ func functionInSection() {
|
||||
func exportedFunctionInSection() {
|
||||
}
|
||||
|
||||
//go:wasmimport modulename import1
|
||||
func declaredImport()
|
||||
|
||||
//go:wasmimport modulename import2
|
||||
func definedImport() {
|
||||
}
|
||||
|
||||
// This function should not: it's only a declaration and not a definition.
|
||||
//
|
||||
//go:section .special_function_section
|
||||
|
||||
Reference in New Issue
Block a user