Added a check for unused imports
This commit is contained in:
3
tests/errors/UnknownPackage.q
Normal file
3
tests/errors/UnknownPackage.q
Normal file
@ -0,0 +1,3 @@
|
||||
main() {
|
||||
sys.read()
|
||||
}
|
3
tests/errors/UnusedImport.q
Normal file
3
tests/errors/UnusedImport.q
Normal file
@ -0,0 +1,3 @@
|
||||
import sys
|
||||
|
||||
main(){}
|
@ -40,6 +40,8 @@ var errs = []struct {
|
||||
{"UnknownIdentifier.q", &errors.UnknownIdentifier{Name: "x"}},
|
||||
{"UnknownIdentifier2.q", &errors.UnknownIdentifier{Name: "x"}},
|
||||
{"UnknownIdentifier3.q", &errors.UnknownIdentifier{Name: "x"}},
|
||||
{"UnknownPackage.q", &errors.UnknownPackage{Name: "sys"}},
|
||||
{"UnusedImport.q", &errors.UnusedImport{Package: "sys"}},
|
||||
{"UnusedVariable.q", &errors.UnusedVariable{Name: "x"}},
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user