Commit 226d732
Fix a crash while traversing base classes
After llvm/llvm-project#158109 we started seeing cases that were previously `DependentTemplateSpecializationType` become `TemplateSpecializationType` where the `getAsTemplateDecl` returns nullptr.
The documentation had always said that getAsTemplateDecl could be nullptr, but perhaps it was harder to see when diverted to the separate `DependentTemplateSpecializationType` type.
PiperOrigin-RevId: 810993821
Change-Id: Ic59d9775617d4ebb12df85381d5b1f072d856dc51 parent cc9c103 commit 226d732
2 files changed
+29
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
82 | | - | |
| 82 | + | |
83 | 83 | | |
84 | | - | |
85 | | - | |
86 | | - | |
87 | | - | |
88 | | - | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
89 | 92 | | |
90 | 93 | | |
91 | 94 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
340 | 340 | | |
341 | 341 | | |
342 | 342 | | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
343 | 363 | | |
344 | 364 | | |
345 | 365 | | |
| |||
0 commit comments