[LLVMbugs] [Bug 19039] New: Destructor invocations wanted
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Tue Mar 4 05:28:46 PST 2014
http://llvm.org/bugs/show_bug.cgi?id=19039
Bug ID: 19039
Summary: Destructor invocations wanted
Product: clang
Version: 3.4
Hardware: PC
OS: Windows NT
Status: NEW
Severity: normal
Priority: P
Component: libclang
Assignee: unassignedclangbugs at nondot.org
Reporter: vpozdyayev at gmail.com
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
Libclang shows constructor CallExprs, but no destructor invocations:
struct S {
S() { }
~S() { }
};
int main( int, char ** ) {
S s;
}
turns into
...
FUNCTION_DECL main
PARM_DECL
PARM_DECL
COMPOUND_STMT
DECL_STMT
VAR_DECL s
TYPE_REF struct S
CALL_EXPR S
This plays hell with static analysis of RAII-based code. Essentially, the
problem is that the resulting tree is a mix of a "syntax" tree (which is about
the declaration, but not about the function call), and a "semantics" tree
(which shows the actual behavior and includes both constructor and destructor
calls).
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20140304/129f6441/attachment.html>
More information about the llvm-bugs
mailing list