Skip to content

WIP: Combine #546 and #531 #557

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 6 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ This document follows the conventions laid out in [Keep a CHANGELOG][].

### Fixed

- Fixed interop methods with Py_ssize_t. NetCoreApp 2.0 is more sensitive than net40 and requires this fix.
- Fixed Visual Studio 2017 compat (#434) for setup.py
- Fixed crash on exit of the Python interpreter if a python class
derived from a .NET class has a `__namespace__` or `__assembly__`
Expand Down
6 changes: 2 additions & 4 deletions src/embed_tests/TestPySequence.cs
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,8 @@ public void TestRepeat()
PyObject actual = t1.Repeat(3);
Assert.AreEqual("FooFooFoo", actual.ToString());

// On 32 bit system this argument should be int, but on the 64 bit system this should be long value.
// This works on the Framework 4.0 accidentally, it should produce out of memory!
// actual = t1.Repeat(-3);
// Assert.AreEqual("", actual.ToString());
actual = t1.Repeat(-3);
Assert.AreEqual("", actual.ToString());
}

[Test]
Expand Down
2 changes: 1 addition & 1 deletion src/runtime/exceptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ public static void SetError(Exception e)
/// </remarks>
public static bool ErrorOccurred()
{
return Runtime.PyErr_Occurred() != 0;
return Runtime.PyErr_Occurred() != IntPtr.Zero;
}

/// <summary>
Expand Down
Loading