This repository was archived by the owner on Jun 10, 2026. It is now read-only.
* BREAKING: .NET type to express Json integers now will be nullable if the property is not required and also without default.#167
Merged
Conversation
shaopeng-gh
commented
Oct 27, 2022
| ""type"": ""integer"", | ||
| ""description"": ""An integer property, required and with a default value."", | ||
| ""default"": 42 | ||
| }, |
Contributor
Author
There was a problem hiding this comment.
These 4 are a set of tests.
shaopeng-gh
commented
Oct 27, 2022
| } | ||
|
|
||
| return unqualifiedTypeName.ToPascalCase(); | ||
| namespaceName = namespaceName == "System" ? null : namespaceName; |
Contributor
Author
shaopeng-gh
commented
Oct 27, 2022
| return unqualifiedTypeName.ToPascalCase(); | ||
| namespaceName = namespaceName == "System" ? null : namespaceName; | ||
|
|
||
| return typeName.StartsWith("System.") ? unqualifiedTypeName : unqualifiedTypeName.ToPascalCase(); |
Contributor
Author
shaopeng-gh
requested review from
EasyRhinoMSFT,
michaelcfanning and
yongyan-gh
October 27, 2022 06:57
Merged
This was referenced Jul 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose of this change:
Ran through SARIF SDK looks good to remove all those:
// NOTYETAUTOGENERATED: Property should be nullable int. https://github.com/Microsoft/jschema/issues/112#112
And also nullable
BigInteger.Modified existing test case, and add a test in
GeneratesAttributesForPropertiesOfPrimitiveTypeWithDefaults()