Dependencies can become incompatible due to anonymous types #28262
Labels
Planning/SwanLakeDump
All issues planned for Swan Lake GA release
Priority/Blocker
Team/CompilerFE
All issues related to Language implementation and Compiler, this exclude run times.
Type/Bug
Description:
Names of anonymous types in a module seem to change across compilations.
Seems like this can cause incompatibilities when using dependencies built on a different lang build
This is probably why we've often been seeing errors like "'lang.array:ArrayIterator' cannot be cast to 'lang.array:$anonType$_1'" and no such field errors for downstream builds.
Assume v1 is the older version which will add the cast from
lang.array:ArrayIterator
tolang.array:$anonType$_1'
which is an object type. Assume the HTTP module is built on this version.Assume v2 is the newer version where
lang.array:$anonType$_1
represents a different anonymous type (may even be a record). Now if we use the HTTP module built on v1 with lang v2, the cast will fail.Steps to reproduce:
Run the following sample on slp8.1
Affected Versions:
slalpha1
The text was updated successfully, but these errors were encountered: