[runtime] Add public API to set the pending exception. (#7759)
commit09bcdbc5a6fcb91fabeef9467a2d4dc38056da4c
authorRolf Bjarne Kvinge <rolf@xamarin.com>
Tue, 17 Apr 2018 14:06:59 +0000 (17 16:06 +0200)
committerAlexander Köplinger <alex.koeplinger@outlook.com>
Tue, 17 Apr 2018 14:06:59 +0000 (17 16:06 +0200)
tree225a138eba98d2b3ae20d0b6308b5b4b0a5cd739
parent1a525f1193310024898cec750371268754d3b389
[runtime] Add public API to set the pending exception. (#7759)

* [runtime] Add public API to set the pending exception.

Xamarin.iOS and Xamarin.Mac need a public API to set the pending exception
when converting Objective-C exceptions to managed exceptions.

This adds a public API to support this scenario.

Partially fixes https://bugzilla.xamarin.com/show_bug.cgi?id=60065.

* [runtime] Document that pending exceptions should not be overwritten when the runtime is handling a thread abort request.
mono/metadata/object.h
mono/metadata/threads.c