Skip to content

Commit

Permalink
Add a few additional dupes
Browse files Browse the repository at this point in the history
  • Loading branch information
danog committed Mar 14, 2022
1 parent dc01e08 commit 9e66c07
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/Psalm/Internal/Analyzer/AlgebraAnalyzer.php
Expand Up @@ -68,7 +68,7 @@ public static function checkForParadox(
new RedundantCondition(
$formula_2_clause . ' has already been asserted',
new CodeLocation($statements_analyzer, $stmt),
null
'already asserted ' . $formula_2_clause
),
$statements_analyzer->getSuppressedIssues()
);
Expand Down
Expand Up @@ -3124,7 +3124,7 @@ private static function getEmptyArrayEqualityAssertions(
new DocblockTypeContradiction(
$var_type . ' does not contain an empty array',
new CodeLocation($source, $conditional),
null
$var_type . ' !== []'
),
$source->getSuppressedIssues()
);
Expand All @@ -3133,7 +3133,7 @@ private static function getEmptyArrayEqualityAssertions(
new TypeDoesNotContainType(
$var_type . ' does not contain empty array',
new CodeLocation($source, $conditional),
null
$var_type . ' !== []'
),
$source->getSuppressedIssues()
);
Expand Down
Expand Up @@ -292,7 +292,7 @@ public static function analyze(
new DocblockTypeContradiction(
$atomic_right_type . ' string length is not ' . $string_length,
new CodeLocation($statements_analyzer, $stmt),
null
"strlen($atomic_right_type) !== $string_length"
),
$statements_analyzer->getSuppressedIssues()
);
Expand All @@ -301,7 +301,7 @@ public static function analyze(
new TypeDoesNotContainType(
$atomic_right_type . ' string length is not ' . $string_length,
new CodeLocation($statements_analyzer, $stmt),
null
"strlen($atomic_right_type) !== $string_length"
),
$statements_analyzer->getSuppressedIssues()
);
Expand All @@ -312,7 +312,7 @@ public static function analyze(
new RedundantConditionGivenDocblockType(
$atomic_right_type . ' string length is never ' . $string_length,
new CodeLocation($statements_analyzer, $stmt),
null
"strlen($atomic_right_type) !== $string_length"
),
$statements_analyzer->getSuppressedIssues()
);
Expand All @@ -321,7 +321,7 @@ public static function analyze(
new RedundantCondition(
$atomic_right_type . ' string length is never ' . $string_length,
new CodeLocation($statements_analyzer, $stmt),
null
"strlen($atomic_right_type) !== $string_length"
),
$statements_analyzer->getSuppressedIssues()
);
Expand Down
2 changes: 1 addition & 1 deletion src/Psalm/Internal/Type/AssertionReconciler.php
Expand Up @@ -1526,7 +1526,7 @@ private static function handleIsA(
new TypeDoesNotContainType(
'Cannot allow string comparison to object for ' . $key,
$code_location,
null
"no string comparison to $key"
),
$suppressed_issues
);
Expand Down
4 changes: 2 additions & 2 deletions src/Psalm/Internal/Type/SimpleNegatedAssertionReconciler.php
Expand Up @@ -125,7 +125,7 @@ public static function reconcile(
'Cannot resolve types for ' . $key . ' with docblock-defined type '
. $existing_var_type . ' and !isset assertion',
$code_location,
null
'cannot resolve !isset '.$existing_var_type. ' ' . $key
),
$suppressed_issues
);
Expand All @@ -135,7 +135,7 @@ public static function reconcile(
'Cannot resolve types for ' . $key . ' with type '
. $existing_var_type . ' and !isset assertion',
$code_location,
null
'cannot resolve !isset '.$existing_var_type. ' ' . $key
),
$suppressed_issues
);
Expand Down

0 comments on commit 9e66c07

Please sign in to comment.