Skip to content

using ChainRulesCore changes type promotion logic #649

Description

@liushang0322

I'm using Julia 1.9 and ChainRulesCore v1.19.0

When I use the following code, the results change

a = ones(Complex,100,100)
a'

ela = eltype(a') # Complex

using ChainRulesCore
a = ones(Complex,100,100)
a'

ela1 = eltype(a') # Any

ela is Complex but ela1 is Any

Please tell me how to avoid this problem (constructing the Complex type is inevitable),Please tell me how to avoid this problem (constructing the Complex type is inevitable), or is this a bug?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    upsteamA problem that need to be resolved upstream in one of our dependencies or in julia itself

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions