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

ast: add params info to str of FnDecl (#7933)

This commit is contained in:
zakuro 2021-01-08 04:25:55 +09:00 committed by GitHub
parent 41e9a769e9
commit a2add15558
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -346,7 +346,7 @@ pub fn (node Stmt) str() string {
return node.expr.str()
}
FnDecl {
return 'fn ${node.name}() { $node.stmts.len stmts }'
return 'fn ${node.name}( $node.params.len params ) { $node.stmts.len stmts }'
}
StructDecl {
return 'struct $node.name { $node.fields.len fields }'