Commit dc25ab3
authored
[lldb]Make
Given this simple test case:
```
// foo.h
extern int* ptr;
inline void g(int x) {
*ptr = x; // should raise a SIGILL
}
//--------------
// foo.cc
#include "foo.h"
int* ptr;
//--------------
// main.cc
#include "foo.h"
int main() {
g(123); // Call the inlined function and crash
return 0;
}
$ clang -g main.cc foo.cc -o main.out
$ lldb main.out
```
When you run `main.out` under lldb, it'd stop inside `void g(int)`
because of the crash.
The stack trace would show that it had crashed in `foo.h`, but if you do
`list foo.h:2`, lldb would complain that it could not find the source
file, which is confusing.
This patch make `list` work with headers.list command work with headers when possible. (#139002)1 parent 59f8af3 commit dc25ab3
File tree
2 files changed
+85
-11
lines changed- lldb
- source/Commands
- test/Shell/Commands
2 files changed
+85
-11
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1108 | 1108 | | |
1109 | 1109 | | |
1110 | 1110 | | |
1111 | | - | |
1112 | | - | |
| 1111 | + | |
| 1112 | + | |
1113 | 1113 | | |
| 1114 | + | |
| 1115 | + | |
| 1116 | + | |
| 1117 | + | |
| 1118 | + | |
| 1119 | + | |
1114 | 1120 | | |
1115 | 1121 | | |
1116 | 1122 | | |
| |||
1122 | 1128 | | |
1123 | 1129 | | |
1124 | 1130 | | |
1125 | | - | |
1126 | | - | |
| 1131 | + | |
| 1132 | + | |
1127 | 1133 | | |
1128 | | - | |
| 1134 | + | |
| 1135 | + | |
1129 | 1136 | | |
1130 | 1137 | | |
1131 | 1138 | | |
1132 | 1139 | | |
1133 | | - | |
1134 | | - | |
1135 | | - | |
| 1140 | + | |
| 1141 | + | |
| 1142 | + | |
| 1143 | + | |
| 1144 | + | |
1136 | 1145 | | |
1137 | 1146 | | |
1138 | 1147 | | |
| |||
1179 | 1188 | | |
1180 | 1189 | | |
1181 | 1190 | | |
| 1191 | + | |
| 1192 | + | |
| 1193 | + | |
| 1194 | + | |
| 1195 | + | |
| 1196 | + | |
| 1197 | + | |
| 1198 | + | |
1182 | 1199 | | |
1183 | | - | |
1184 | | - | |
1185 | | - | |
| 1200 | + | |
| 1201 | + | |
| 1202 | + | |
1186 | 1203 | | |
1187 | 1204 | | |
1188 | 1205 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
0 commit comments