Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report for Bug 33016 on
Developer Community or GitHub if you have new
information to add and do not yet see a matching new report.
If the latest results still closely match this report, you can use the
In special cases on GitHub you might also want the comments:
GitHub Markdown with public comments
MKMapRect.Intersection Union and Intersect take two MKMapRects, but could be instance methods on the first instance.
In theory: yes. In practice: there are drawbacks as the existing API are direct binding of Apple's functions, e.g.
> MKMapRect MKMapRectIntersection ( MKMapRect rect1, MKMapRect rect2 );
which returns a new instance of MKMapRect.
Now we could copy the returned `MKMapRect` instance values back into `this` but this has a performance impact.
It could be minor in some cases, e.g. when the original value is not needed, unless it's used in a loop.
OTOH if misused, e.g. if the code keeps it's own copies of the `MKMapRect` because it's not aware that the other API, then you end up doing many copy operations (and likely extra allocations).
Since those API would be easier to discover (code completion) and we cannot assume everyone will read the documentation (the name pretty much covers it) then I'm not sure we end up helping a lot.
Note: `MKMapRectIntersectsRect` is different as it returns a `bool` so there would not be any impact in adding an instance method.