We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4ff2569 commit 31b0c4aCopy full SHA for 31b0c4a
src/dscanner/analysis/useless_initializer.d
@@ -368,6 +368,19 @@ public:
368
NotKnown nk = NotKnown.init;
369
}, sac);
370
371
+ // passes
372
+ assertAnalyzerWarnings(q{
373
+ @("NOLINT(useless_initializer)")
374
+ int a = 0;
375
+ ubyte a = 0x0; /+
376
+ ^^^ [warn]: X +/
377
+
378
379
+ int f() {
380
+ int[] a = null;
381
+ }
382
+ }, sac);
383
384
stderr.writeln("Unittest for UselessInitializerChecker passed.");
385
}
386
0 commit comments