We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3e7cf05 commit 00f151dCopy full SHA for 00f151d
src/lpython/semantics/python_ast_to_asr.cpp
@@ -7600,7 +7600,7 @@ we will have to use something else.
7600
} else if (AST::is_a<AST::Dict_t>(*at->m_value)) {
7601
AST::Dict_t* cdict = AST::down_cast<AST::Dict_t>(at->m_value);
7602
visit_Dict(*cdict);
7603
- if (!tmp) {
+ if (tmp == nullptr) {
7604
throw SemanticError("cannot call " + std::string(at->m_attr) + " on an empty dict" , loc);
7605
}
7606
ASR::expr_t* dict_expr = ASR::down_cast<ASR::expr_t>(tmp);
0 commit comments