Jonathan Pryor
Jonathan Pryor
Design thoughts… Instead of a `bool PeersRequireRelease {get;}` property, perhaps it should be an enum of some form? `ReleasePeers()` doesn't need to be the abstraction; it could be implemented in...
Related related idea? Model on Objective-C AutoRelease pools? https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/MemoryMgmt/Articles/mmAutoreleasePools.html The problem *here* is that we don't have reference counting, so it's a bit of an "all or nothing" thing.
Having slept on it, wrt [previous design thoughts](https://github.com/xamarin/java.interop/issues/426#issuecomment-782283038)… We *don't* want to support explicitly registering "global" instances, at least not at first. It *may* be useful, but without a concrete...
…and more thinking, the current `DoNotRegister` idea isn't really viable, as currently constructed, because there may be an entire object graph implicitly created, but -- in the idea of the...
"Related" random thought: there is a `System.Threading.ThreadPool.EnableDispatchAutoreleasePool` feature switch: https://github.com/dotnet/runtime/blob/d0616f837f4ad1ceb7e36a341934c929fd790089/docs/workflow/trimming/feature-switches.md > When set to true, creates an NSAutoreleasePool around each thread pool work item on applicable platforms. *If* we had...
Back on the `JniValueManager` side of things, [instead of a new enum](https://github.com/xamarin/java.interop/issues/426#issuecomment-782283038), go for an easier semantic. (Still a breaking change vs. current API, but at least it's explicable.) ```csharp...
A possible alternate/additional idea [suggested by `@wasabi#2184`](https://discord.com/channels/732297728826277939/732297837953679412/870065303663566920): > Ever thought about using DependentHandles for the GC stuff? Not going to be performant. But might work. What's a "dependent handle"? [`ConditionalWeakTable`](https://docs.microsoft.com/en-us/dotnet/api/system.runtime.compilerservices.conditionalweaktable-2?view=net-5.0)...
Is there a reason to generate these new `___jni_marshal_`-prefixed delegate types instead of using the same types -- or same naming convention? -- as the `_JniMarshal_`-prefixed types?
***Note***: in the case of xamarin/xamarin-android#5580, the above `` *does **not** work*, because `generator` doesn't like `..` in the name. If I manually replace all instances of `HttpRequest..serializer` with `HttpRequest._serializer`,...
We should do (2) and emit `new` to remove the CS0114 warning.