chapel
chapel copied to clipboard
[Bug]: erroneously creating an AstNode causes a segfault
The following python code for chapel-py
results in a sefault
import chapel
a = chapel.AstNode()
This is not semantically valid code, since you cannot create AstNodes from chapel-py
. But it is allowed by the interpreter and results in a segfault. This is because the internal context object for a
is never initialized, but the interpreter does try to deinitialize it, causing a segfault.
I hit this while writing a chplcheck rule, where I erroneously created an advanced rule as @driver.advanced_rule(AstNode)
, which is not correct and resulted in an unexpected node being "created"