Skip to content

Commit

Permalink
error->notice
Browse files Browse the repository at this point in the history
  • Loading branch information
felipensp committed Sep 25, 2024
1 parent 044120e commit 3ae4c84
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion vlib/v/checker/infix.v
Original file line number Diff line number Diff line change
Expand Up @@ -964,7 +964,7 @@ fn (mut c Checker) check_duplicated_items(node &ast.ArrayInit) {
if item.str() !in unique_items {
unique_items << item_str
} else {
c.error('item `${item_str}` is duplicated in the list', item.pos())
c.note('item `${item_str}` is duplicated in the list', item.pos())
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions vlib/v/checker/tests/infix_dup_in_err.out
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
vlib/v/checker/tests/infix_dup_in_err.vv:1:16: error: the item `2` is duplicated in the list
vlib/v/checker/tests/infix_dup_in_err.vv:1:16: notice: item `2` is duplicated in the list
1 | if 1 in [1, 2, 2, 2] { println('ok') }
| ^
2 |
3 | a := `a`
vlib/v/checker/tests/infix_dup_in_err.vv:4:20: error: the item `a` is duplicated in the list
vlib/v/checker/tests/infix_dup_in_err.vv:4:20: notice: item `a` is duplicated in the list
2 |
3 | a := `a`
4 | if `a` in [`c`, a, a] { println('ok') }
Expand Down

0 comments on commit 3ae4c84

Please sign in to comment.