-
Notifications
You must be signed in to change notification settings - Fork 10.5k
[Mangling] Several fixes for de/re/-mangling of generic typealiases #17509
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
528ccc9
7a6ad36
feb0f70
b3e536b
15f4ee7
4f66824
5350d45
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
$S12DeclReconstr8patatinoSiyF ---> func patatino() -> Int | ||
$S12DeclReconstr1SVACycfC ---> init() | ||
$S12DeclReconstr8PatatinoaySiGD ---> typealias Patatino<T> = Foo<T> | ||
$S12DeclReconstr5OuterV3Fooayx_SiGD ---> Can't resolve decl of $S12DeclReconstr5OuterV3Fooayx_SiGD | ||
$S12DeclReconstr5OuterV12GenericInnerV3Barayx_qd___GD ---> typealias Bar = Int |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -192,6 +192,9 @@ int main(int argc, char **argv) { | |
llvm::cl::opt<std::string> DumpTypeFromMangled( | ||
"type-from-mangled", llvm::cl::desc("dump type from mangled names list")); | ||
|
||
llvm::cl::opt<std::string> ResourceDir("resource-dir", | ||
llvm::cl::desc("The directory that holds the compiler resource files")); | ||
|
||
llvm::cl::ParseCommandLineOptions(argc, argv); | ||
// Unregister our options so they don't interfere with the command line | ||
// parsing in CodeGen/BackendUtil.cpp. | ||
|
@@ -254,6 +257,10 @@ int main(int argc, char **argv) { | |
Invocation.setModuleName("lldbtest"); | ||
Invocation.getClangImporterOptions().ModuleCachePath = ModuleCachePath; | ||
|
||
if (!ResourceDir.empty()) { | ||
Invocation.setRuntimeResourcePath(ResourceDir); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Do you need this for testing? [If so, can you add a test for this]. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It's for debugging: I often use a Debug compiler with a standard library that was build with a Release+Asserts compiler, because the latter builds the standard library so much faster. Testing doesn't need this. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. OK, makes sense, thanks! |
||
} | ||
|
||
if (CI.setup(Invocation)) | ||
return 1; | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this invalid?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"This is a hack to avoid crashing; a more complete fix requires deeper changes to the type reconstruction logic."
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to do the thing where we pull out all of the generic argument lists from the "parent" type and put them together.