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

all: if smartcast part 2 (#5754)

This commit is contained in:
Daniel Däschle
2020-07-08 15:46:58 +02:00
committed by GitHub
parent 7ad03e9d6a
commit 5ea17ad2d4
15 changed files with 67 additions and 88 deletions

View File

@ -98,10 +98,9 @@ fn (app App) gen_api_for_module_in_os(mod_name, os_name string) string {
for f in b.parsed_files {
for s in f.stmts {
if s is ast.FnDecl {
fnd := s as ast.FnDecl
if fnd.is_pub {
fn_signature := fnd.stringify(b.table)
fn_mod := fnd.modname()
if it.is_pub {
fn_signature := it.stringify(b.table)
fn_mod := it.modname()
if fn_mod == mod_name {
fline := '${fn_mod}: $fn_signature'
res << fline