Commit b14bf55
authored
annotate overloaded private class members where needed (#51)
## Purpose
Running IDs across the LLVM source, I observed a few cases where private
methods that should have been annotated due to being referenced in the
same translation unit. In these instances, the missed private methods
had overloads and their references were ambiguous. This PR addresses the
issue and makes IDS properly flag these methods for export.
## Overview
1. Override `VisitUnresolvedMemberExpr` which gets called in this
scenario. Invoke the existing `export_function_if_needed` for each
method declaration the expression may reference. This is only done for
private methods because public methods will always be annotated.
2. Add a new test case. For this test force Clang language options to
`-fno-delayed-template-parsing`, which is already the default on Linux
and Darwin. This is required on Windows, where the default behavior is
`-fdelayed-template-parsing` to better match MSVC behavior. More details
[here](https://clang.llvm.org/docs/MSVCCompatibility.html). Without this
argument, the new test case does not pass when run on Windows.
## Validation
1. New tests case.
2. Ran tests on Windows and Linux.
3. Manually ran on a subset of the llvm headers and inspected results.1 parent c48649d commit b14bf55
2 files changed
Lines changed: 33 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
514 | 514 | | |
515 | 515 | | |
516 | 516 | | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
| 520 | + | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
517 | 530 | | |
518 | 531 | | |
519 | 532 | | |
| |||
| 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 | + | |
0 commit comments