mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
compiler: let attributes work with pub functions
This commit is contained in:
parent
040d03912b
commit
695d4018ea
@ -3632,7 +3632,7 @@ fn (p mut Parser) attribute() {
|
|||||||
p.attr = p.check_name()
|
p.attr = p.check_name()
|
||||||
}
|
}
|
||||||
p.check(.rsbr)
|
p.check(.rsbr)
|
||||||
if p.tok == .func {
|
if p.tok == .func || (p.tok == .key_pub && p.peek() == .func) {
|
||||||
p.fn_decl()
|
p.fn_decl()
|
||||||
p.attr = ''
|
p.attr = ''
|
||||||
return
|
return
|
||||||
|
Loading…
Reference in New Issue
Block a user