-
Notifications
You must be signed in to change notification settings - Fork 88
Nullability: conversion behavior #1242
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: draft-v8
Are you sure you want to change the base?
Conversation
5ff046a
to
da6c48d
Compare
da6c48d
to
95a4f4e
Compare
@BillWagner Would you like to take a look at these added nullability examples since you had been working on previous ones? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for adding me to review.
I looked everything over, and this is all good. The suggestions I have all concern how our tooling works.
Ii think you need to be looking for ^>.*\r\n> *\r\n in a block quote but not in a contained code block in the block quote (i.e. just be wary of false +ve’s). This sequence occurs at the start & end of this particular code block. As Bill mentions you can disable particular errors in a file, just add HTML comments:
Disable one or more rules by name: <!-- markdownlint-disable MD001 MD005 -->
Enable one or more rules by name: <!-- markdownlint-enable MD001 MD005 —>
… On 17/04/2025, at 10:56 am, Joseph Musser ***@***.***> wrote:
@jnm2 commented on this pull request.
In standard/types.md <#1242 (comment)>:
> +> {
+> public void M1(string p)
+> {
+> _ = (string?)p; // No warning, widening
+> }
+>
+> public void M2(string? p)
+> {
+> _ = (string)p; // Warning, narrowing
+> _ = (string)p!; // No warning, suppressed
+> }
+> }
+> ```
+>
+> *end example*
+
I might be misunderstanding. This seems to be rule https://github.com/DavidAnson/markdownlint/blob/v0.37.4/doc/md028.md. Scrolling through files and a regex search in all files for ^>.*\r\n\r\n> didn't turn anything up, so I haven't found any examples to follow.
Looking at what this rule is, it seems to be saving people from creating block quotes that get unified by some parsers and not others. If that's not a concern in this spot, then it seems that it must not be a concern for the entire repo, and maybe we could ignore MD028 globally with the run of this tool. What do you think?
—
Reply to this email directly, view it on GitHub <#1242 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/ABSYVW25CK5JCOPYYOQGUJ32Z3NZNAVCNFSM6AAAAABUOEA7CKVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMZDONZUGA3DQOBTGA>.
You are receiving this because you were mentioned.
|
CI is nice and fast. Really neat system here! |
> | ||
> public void M2(string? p) | ||
> { | ||
> _ = (string)p; // Warning, narrowing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we jinxed it after all?
This is my first PR to the repo. Guidance is very helpful. Think of the lines of this PR as a series of questions: how far to go, whether it's worth going here, how do we do things?