1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

parser,fmt: implement [manualfree] module abc for opting out *all* fns in a given .v from autofree

This commit is contained in:
Delyan Angelov
2021-01-08 17:24:42 +02:00
parent 083dc23db8
commit 46a5c487c1
7 changed files with 49 additions and 2 deletions

View File

@ -0,0 +1,18 @@
[manualfree]
module main
fn abc() {
x := 'abc should be autofreed'
println(x)
}
[manualfree]
fn xyz() {
x := 'xyz should do its own memory management'
println(x)
}
fn main() {
abc()
xyz()
}