Page MenuHomePhabricator

Refactoring how macro backtraces are printed
ClosedPublic

Authored by zhengkai on Jul 27 2015, 2:52 PM.

Details

Summary

Implement the iteration version of the function emitMacroExpansions instead of the recursion version.

Will work on to improve the diagnostic information in macro.

Diff Detail

Repository
rL LLVM

Event Timeline

zhengkai updated this revision to Diff 30740.Jul 27 2015, 2:52 PM
zhengkai retitled this revision from to Refactoring how macro backtraces are printed .
zhengkai updated this object.
zhengkai added a reviewer: rtrieu.
zhengkai added a subscriber: cfe-commits.
rtrieu added inline comments.Jul 27 2015, 3:21 PM
lib/Frontend/DiagnosticRenderer.cpp
403 ↗(On Diff #30740)

"bactrace" => "backtrace"

446 ↗(On Diff #30740)

This comment was for the recursive version of this code. Change to say that the intermediate macro locations are being stored for processing.

457 ↗(On Diff #30740)

There's an extra space at the end of this line, and several below. Remove them.

zhengkai updated this revision to Diff 30745.Jul 27 2015, 3:27 PM

Address the comments/

zhengkai updated this revision to Diff 30746.Jul 27 2015, 3:29 PM

Fix one unchanged in the previous patch.

zhengkai marked 3 inline comments as done.Jul 27 2015, 3:30 PM
rtrieu accepted this revision.Jul 28 2015, 1:44 PM
rtrieu edited edge metadata.

LGTM

This revision is now accepted and ready to land.Jul 28 2015, 1:44 PM
This revision was automatically updated to reflect the committed changes.