Two non-functional problem reports

This commit is contained in:
Chad Stearns 2020-03-29 14:28:06 -04:00
parent a00ed8a1ca
commit 221581432a
4 changed files with 142 additions and 7 deletions

View file

@ -10,7 +10,9 @@ use roc_region::all::{Located, Region};
pub enum Problem {
UnusedDef(Symbol, Region),
UnusedImport(ModuleId, Region),
UnusedArgument(Symbol, Region),
/// First symbol is the name of the closure with that argument
/// Second symbol is the name of the argument that is unused
UnusedArgument(Symbol, Symbol, Region),
PrecedenceProblem(PrecedenceProblem),
// Example: (5 = 1 + 2) is an unsupported pattern in an assignment; Int patterns aren't allowed in assignments!
UnsupportedPattern(PatternType, Region),