Skip to content

Conversation

lostmsu
Copy link
Member

@lostmsu lostmsu commented Jun 30, 2022

Also fixed unhandled Python errors during comparison attempts

What does this implement/fix? Explain your changes.

For == and != operators in C# to use Python equality PyObject must implement operator == and operator !=. C# ignores TryBinaryOperation implementation for equality comparisons.

The "also" part clears Python error when comparison can not be performed.

Does this close any currently open issues?

#1848

Checklist

Check all those that are applicable and complete.

  • Make sure to include one or more tests for your change
  • Updated the CHANGELOG

fixed unhandled Python errors during comparison attempts

fixes pythonnet#1848
@lostmsu lostmsu merged commit 21c5dcc into pythonnet:master Jun 30, 2022
@lostmsu lostmsu deleted the bugs/1848 branch June 30, 2022 23:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant