Closed bradcray closed 6 years ago
While I made progress with several of the categories above, I also ran into a challenge that I had previously not anticipated properly: Namely, some of the failures above were because in resolving a concrete function that was not called, subsequent compiler passes see that it is resolved and now process it where they had not before. Put another way, removeUnusedFunctions()
no longer eliminated them because they seemed to be used (since they are marked as "resolved").
As a quick workaround, I tried simply flipping FLAG_RESOLVED off after the function had been resolved, but of course this only catches the function itself, not others that were resolved simply because it called them. But this (a) doesn't seem ideal (keeps more functions alive than it should) and (b) introduced some new errors as well:
In either case, there are also failures in all SSCA2 cases for resolving isArray() too many times, a few override messages that need updating, and a spec example that should probably be rewritten for clarity.
I opened up issue #11271 as the follow-on to this one.
In my current branch, I'm seeing ~40 errors when trying to resolve concrete user-defined functions, which break down as follows:
In this spike, I plan to investigate these cases to understand the internal errors and resolve or create stories for the other cases.