GenAPI outputs reference to internal type in assembly-level attribute
See original GitHub issueWhen targeting System.Text.Json 6.0.0, GenAPI includes the following in its output:
[assembly: System.Reflection.Metadata.MetadataUpdateHandler(typeof(JsonSerializerOptionsUpdateHandler))]
This fails to compile because JsonSerializerOptionsUpdateHandler
is an internal type and is not included in the generated code. Here’s what the actual source looks like: https://github.com/dotnet/runtime/blob/5f94bffeff62f4b767a311a4505d6d40d86279d9/src/libraries/System.Text.Json/src/System/Text/Json/Serialization/JsonSerializerOptionsUpdateHandler.cs#L11-L18
cc @ViktorHofer
Issue Analytics
- State:
- Created 6 months ago
- Reactions:2
- Comments:10 (7 by maintainers)
Top Results From Across the Web
How to generate code using Roslyn source ...
The BuildOutputTargetFolder property means our assembly will end up in analyzers/netstandard2.0 inside the package, so it will not become a lib ...
Read more >c# - How can I access an internal class from an external ...
Having an assembly which I cannot modify (vendor-supplied) which have a method returning an object type but is really of an internal type....
Read more >MIPS Assembly Language Programming using QtSpim
The following diagram shows a basic configuration of the MIPS processor internal architecture. The FPU (floating-point unit) is also referred to as the...
Read more >ABAQUS Analysis User's Manual (v6.6)
This section describes the methods for defining elements in an ABAQUS input file. In a preprocessor such as ABAQUS/CAE, you define the model...
Read more >Assembly language
The use of symbolic references is a key feature of assemblers, saving tedious calculations and manual address updates after program modifications. Most ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
We are checking attribute type
System.Reflection.Metadata.MetadataUpdateHandler
and nottypeof(JsonSerializerOptionsUpdateHandler)
. We do not analyze attribute’s value.Submitted https://github.com/dotnet/sdk/issues/31098 to fix this. As mentioned above, the change follows what we were doing in the CCI based GenAPI. Internal attributes are already filtered out today in main. If we want to change that, we should discuss that in a separate issue.