surface: Simplify extractSymbol - avoid .tree to make library working with Scala 3.4.2#3533
surface: Simplify extractSymbol - avoid .tree to make library working with Scala 3.4.2#3533OndrejSpanel wants to merge 3 commits intowvlet:mainfrom
Conversation
The airframe tests passed locally, but some tests for other modules fail on CI. I will check what is going on. |
|
The issue is with: Compiler crashes with:
My fix causes bad representation of |
fb755f9 to
b9928d5
Compare
|
I am afraid I am unable to fix this. I was missing one dealias, once I have added it, types both with and without the fix seem correct, without the fix the type is represented as It works fine in my "light" fork without the method accessors. Unless this is fixed, expect trouble once users of the library port to 3.4.2. No fix logs: With the fix: Note |
|
As a preliminary work, I've added a CI for Scala 3.4.2 to reproduce this issue #3590. As path-dependent type support is a bit complicated, I will revisit the current implementation later based on this PR. Thanks for reporting and trying to fix the issue. |
Resolves issues when upgrading to Scala 3.3.4 - Surface for nested opaque types - Simplified a path-dependent type test, as path-dependent type is not frequently used, it should not be a blocker to use later versions of Scala. #3533 --------- Co-authored-by: xerial-bot <leo+bot@xerial.org>
|
#3669 adopted this approach. Instead of handling the complicated ownership issue, I've fixed the test case side so that we don't need to address the outer reference for path-dependent types, which will not be used so frequently. |
Followup to #3521
The method
extractSymbolused to dealias inner types for both opaque types and type aliases does not work when the library is used from Scala 3.4.2 application. The reason is infamous.treemethod again, which is known and documented to be unreliable.I am not sure why it was used, the code seems simpler without it, but maybe I am missing something. After the simplification all tests still pass.