aboutsummaryrefslogtreecommitdiff
path: root/src/checker.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/checker.cpp')
-rw-r--r--src/checker.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/checker.cpp b/src/checker.cpp
index ed9da4fee..8f4b2f766 100644
--- a/src/checker.cpp
+++ b/src/checker.cpp
@@ -1074,11 +1074,11 @@ bool add_entity(Checker *c, Scope *scope, AstNode *identifier, Entity *entity) {
String name = entity->token.string;
if (!is_blank_ident(name)) {
Entity *ie = scope_insert_entity(scope, entity);
- if (ie) {
+ if (ie != nullptr) {
TokenPos pos = ie->token.pos;
Entity *up = ie->using_parent;
if (up != nullptr) {
- if (token_pos_eq(pos, up->token.pos)) {
+ if (pos == up->token.pos) {
// NOTE(bill): Error should have been handled already
return false;
}
@@ -1089,7 +1089,7 @@ bool add_entity(Checker *c, Scope *scope, AstNode *identifier, Entity *entity) {
LIT(up->token.pos.file), up->token.pos.line, up->token.pos.column);
return false;
} else {
- if (token_pos_eq(pos, entity->token.pos)) {
+ if (pos == entity->token.pos) {
// NOTE(bill): Error should have been handled already
return false;
}