This is an archive of the discontinued LLVM Phabricator instance.

Allow in-place compound statment body replacement
AbandonedPublic

Authored by v.g.vassilev on Nov 7 2020, 12:52 AM.

Details

Reviewers
rsmith
bkramer
Summary

CompoundStmt::setStmts was reimplemented to save a pointer (r321429/llvm-mirror/clang@d0ee47a).

The patch assumes allocation of a new CompoundStmt if its statements are modified. Unfortunately this needs the newly created CompoundStmt swapped in its users making the AST visitation harder. This break external tools such as cling which alters CompoundStmts to implement its interactive extensions.

This patch patch brings the old facilities only when the new interface CompoundStmt::replaceStmts is called.

Diff Detail

Repository
rC Clang

Event Timeline

v.g.vassilev created this revision.Nov 7 2020, 12:52 AM
v.g.vassilev requested review of this revision.Nov 7 2020, 12:52 AM
v.g.vassilev abandoned this revision.May 13 2021, 9:24 AM

Thanks to @Hahnfeld, that's not needed anymore.