aboutsummaryrefslogtreecommitdiff
path: root/src/checker.cpp
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2022-01-31 20:19:46 +0000
committergingerBill <bill@gingerbill.org>2022-01-31 20:19:46 +0000
commit85706d559d06998895b27710f5e4f4643443b032 (patch)
treecc700398ca5869d982c40f66fea2f55c9890242c /src/checker.cpp
parent67ba05cb7cfee60daaf257230ddbc4f1e0a9f8ac (diff)
Fix typo
Diffstat (limited to 'src/checker.cpp')
-rw-r--r--src/checker.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/checker.cpp b/src/checker.cpp
index d9a1af0d1..d50d4d176 100644
--- a/src/checker.cpp
+++ b/src/checker.cpp
@@ -5307,18 +5307,18 @@ void check_unique_package_names(Checker *c) {
string_map_set(&pkgs, key, pkg);
continue;
}
- auto *this = pkg->files[0]->pkg_decl;
- auto *other = (*found)->files[0]->pkg_decl;
- if (this == other) {
+ auto *curr = pkg->files[0]->pkg_decl;
+ auto *prev = (*found)->files[0]->pkg_decl;
+ if (curr == prev) {
// NOTE(bill): A false positive was found, ignore it
continue;
}
- error(this, "Duplicate declaration of 'package %.*s'", LIT(name));
+ error(curr, "Duplicate declaration of 'package %.*s'", LIT(name));
error_line("\tA package name must be unique\n"
"\tThere is no relation between a package name and the directory that contains it, so they can be completely different\n"
"\tA package name is required for link name prefixing to have a consistent ABI\n");
- error(other, "found at previous location");
+ error(prev, "found at previous location");
}
}