Comments (21)
I will add both TypedReference and ArgIterator back to the standard.
from standard.
Opened dotnet/ef6#619
from standard.
Are there platform that would not be able to use this feature in the future
Potentially. We're walking a tight rope here. On the one hand side, we don't want to include large amounts of API into the .NET Standard that aren't/cannot be implemented everywhere. However, we also have to consider cases where if the producer of the .NET Standard library doesn't care about all the platforms but wants to share with a specific set of platforms that have this functionality. For larger components, such as registry, it makes sense to make the APIs available as additional packages that those projects can consume. But for tiny APIs like TypedReference
and ArgIterator
it's just not worth it.
Future platforms are likely forks of the existing open source stacks. Mono/Xamarin support both concepts. As @jkotas said, .NET Core's implementation for ArgIterator
needs fixes to work on Unix. It's possible that we never add it, but I doubt that we'd go out of our way to remove these smaller features, unless we run into real issues.
from standard.
After further discussion we decided to remove ArgIterator and the __arglist overloads from the standard because the amount of work to even make them throw PNSE isn't worth any tiny value it might provide. Removed with 52651e7.
from standard.
Removed with 6e3ad13.
from standard.
It looks like the managed linker might depend on TypedReference
outside the C++/CLI and __arglist
scenario.
@russellhadley @erozenfeld @swaroop-sridhar can you elaborate your dependency on TypedReference
?
from standard.
I assume this related to https://github.com/dotnet/corefx/issues/14088. Is it only TypedReference that is needed?
cc @jkotas
from standard.
It turns out that the managed linker doesn't have to depend on TypedReference
so that shouldn't be considered a reason to bring TypedReference
back. dotnet/corefx#14088 is a different motivation to bring it back.
from standard.
I'd say that given we originally removed it due to dubious use we should now bring it back. First, API Port telemetry shows it's used in 2 percent of our reports, which is quite a bit considering the low-level nature of this type. Also, considering dotnet/corefx#14088 it seems to be general useful.
And on top, .NET Framework and Xamarin/Mono already have the type. I believe this is also true for CoreCLR. Not sure about CoreRT/MRT, but that's a different issue.
@weshaggard, any objections exposing this type?
from standard.
There is still time to do this for NS2.0 if it's mainly just exposing something. As Immo mentions of course it needs to work on MRT.
from standard.
It looks like the managed linker might depend on TypedReference
We should fix the linker to not depend on it.
from standard.
First, API Port telemetry shows it's used in 2 percent of our reports, which is quite a bit considering
I missed this part. Yes - if you see this type being used a lot, I agree we should bring it back.
it needs to work on MRT
There is nothing fundamental that prevents it work on MRT. It is just some extra work in the NS2.0 bucket.
from standard.
Excellent. So it seems we should expose it then.
@weshaggard, press the magic button 😄
from standard.
TypedReference and ArgIterator back to the standard.
Sounds reasonable to me.
ArgIterator implementation in .NET Core will need codegen and runtime work, on Unix at least. The codegen teams will need to be involved in the implementation. It should throw PNSE until this work gets done.
from standard.
I have curios for such times that, how many platform derived from dotnet could use TypedReference
and ArgIterator
Such as xamarin that compile to mobile platform, especially iOS which is prohibited runtime code generation. It can use Reflection
but cannot use Reflection.Emit
. Can it use TypedReference
?
There are also webassembly that would parsed from llvm compiled C#. Are there limitation that make it not compatible?
I don't know where to ask this question, sorry if this is wrong place
from standard.
There is nothing about TypedReference or ArgIterator that requires runtime code generation.
from standard.
@jkotas I mean there are many reason each platform cannot implement some feature. TypedReference
used to be not supported on some platform in the past. I just curious that, even it was brought into standard. Are there platform that would not be able to use this feature in the future
from standard.
reverted with #162.
from standard.
@weshaggard EntityFramework6 uses String.Concat with __arglist overload:
https://github.com/aspnet/EntityFramework6/blob/master/src/EntityFramework/Core/Objects/ELinq/MethodCallTranslator.cs#L1493
if you run this on .NET Core you will get null
from standard.
@EgorBo Is there a bug on this in EF6? We do not have plans to add cross-plat vararg support to .NET Core in near future. It would be best for EF6 to fix this.
from standard.
@jkotas I don't think so, I am here just to leave a note 🙂 some of our users hit this issue with CoreFX String and EF6 packages on Mono: mono/mono#9996 (and the fix is mono/mono#10452 (review))
from standard.
Related Issues (20)
- Build issues when referencing project that targets multiple frameworks C# WPF HOT 1
- Questions about tagging within this repository / future versions HOT 1
- System.Drawing.Printing.PrinterSettings slow HOT 1
- Support with Universal Windows Platform HOT 2
- How to build .NET Standard based library for ARM architecture HOT 6
- Update docs to reflect the status of .NET Standard in 2020 HOT 2
- [BUG] [UWP] GetManifestResourceInfo doesn't work on UWP HOT 3
- Value Tuple Could not load file or assembly 'System.ValueTuple, Version=4.0.1.0, HOT 1
- mono and .NET5+ HOT 8
- Security Vulnerability due to System.Text.RegularExpressions HOT 4
- Issue with resolving between .NET Standard 2.0 and .NET Standard 2.1 HOT 3
- Class ValueTask has different definitions between .Net Standard 2.1 and .Net 5 HOT 1
- Strong name signature not valid HOT 5
- Assembly version for DispatchProxy shim is too low resulting in duplicate types for DispatchProxy HOT 10
- linq using GetValueOrDefault in Where clause problem HOT 3
- DbCommand.ExecuteReaderAsync throws TaskCanceledException with wrong CancellationToken HOT 2
- [Feature Request] Allow Static Method In Interface HOT 3
- [question] Will Garbage Collector Collect Memebers, When Object Is Casted To Parent Type, That Is Now Inaccessible On The Type Of Reference? HOT 2
- [Feature Request] Support for MultiSet & MultiMap in System.Collections.Generic HOT 3
- Support of 'IAsyncComparer' for Linq operations. HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from standard.