From 2f0fe5aef269cbac8a5dc78ef3dd3a005f6ff2db Mon Sep 17 00:00:00 2001 From: Aryadev Chavali Date: Sun, 21 Nov 2021 00:28:01 +0000 Subject: (list)+general style change, use unary switches for checking null --- list.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'list.cpp') diff --git a/list.cpp b/list.cpp index 873dfe9..593a87e 100644 --- a/list.cpp +++ b/list.cpp @@ -45,7 +45,7 @@ List *append(List *lst, T value) template std::ostream& operator<<(std::ostream& ostream, const List *lst) { - if (lst == NULL) + if (!lst) return ostream; ostream << "|" << lst->value << lst->next; return ostream; -- cgit v1.2.3-13-gbd6f