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

compiler: error on unused imports

This commit is contained in:
joe-conigliaro
2019-09-23 20:42:20 +10:00
committed by Alexander Medvednikov
parent 71484e89d6
commit 23c84516e2
29 changed files with 112 additions and 55 deletions

View File

@@ -7,8 +7,8 @@ module main
import os
// add a module and its deps (module speficic dag method)
pub fn(graph mut DepGraph) from_import_tables(import_tables []FileImportTable) {
for fit in import_tables {
pub fn(graph mut DepGraph) from_import_tables(import_tables map[string]FileImportTable) {
for _, fit in import_tables {
mut deps := []string
for _, m in fit.imports {
deps << m