You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When accessing static properties of T through Extensible<T> (e.g. BigInteger.Zero), a type error is raised. Accessing instance properties (e.g. String.Length) or static fields (e.g. Int32.MaxValue) works fine.
Hmm... Seems that ReflectedProperty.MateGetExpresion may be missing the ExplicitCast expression casting from instance to the declaring type of the chosen getter. I've also noticed that while there are extensive tests in ./Test/interop/net/field and ./Test/interop/net/method, the equivalent tests for properties are missing. So there may be more things that are not quite working for properties. I think it is worth investigating deeper and write the missing tests but for now I'll take your workaround as I want to get the PR for #52 out the door. It will probably take a while to get reviewed, so in the meantime I can tie up some loose ends.
BCSharp
added a commit
to BCSharp/ironpython3
that referenced
this issue
Feb 25, 2022
When accessing static properties of
T
throughExtensible<T>
(e.g.BigInteger.Zero
), a type error is raised. Accessing instance properties (e.g.String.Length
) or static fields (e.g.Int32.MaxValue
) works fine.Example:
This issue is blocking #52.
The text was updated successfully, but these errors were encountered: