[PATCH] Fix segmentation fault when mixing -Rpass with #line.

Richard Smith richard at metafoo.co.uk
Wed May 7 14:32:23 PDT 2014


LGTM, although this makes the "do this properly" FIXME seem somewhat more of a pressing concern :)

================
Comment at: lib/CodeGen/CodeGenAction.cpp:405
@@ -403,4 +404,3 @@
         Column = 1;
-      Loc = SourceMgr.translateFileLineCol(FileMgr.getFile(Filename), Line,
-                                           Column);
+      Loc = SourceMgr.translateFileLineCol(FE, Line, Column);
     }
----------------
How does `SourceMgr` respond if the file/line you give it is out of range for the file?

http://reviews.llvm.org/D3625






More information about the cfe-commits mailing list