-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
20 changed files
with
176 additions
and
278 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
ERROR: InvalidArgument - input.hack:13:14 - Argument 1 of echo expects arraykey, different type Exception provided | ||
ERROR: InvalidArgument - input.hack:13:14 - Argument 1 of echo expects scalar|null, different type Exception provided |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
ERROR: NonExistentClass - input.hack:8:11 - Cannot call new on undefined class A | ||
ERROR: NonExistentType - input.hack:12:10 - Unknown class A | ||
ERROR: MixedAnyArgument - input.hack:12:10 - Argument 1 of echo expects arraykey, any provided | ||
ERROR: MixedAnyArgument - input.hack:12:10 - Argument 1 of echo expects scalar|null, any provided | ||
ERROR: NonExistentType - input.hack:17:14 - Unknown class A | ||
ERROR: MixedAnyArgument - input.hack:17:14 - Argument 1 of echo expects arraykey, any provided | ||
ERROR: MixedAnyArgument - input.hack:17:14 - Argument 1 of echo expects scalar|null, any provided | ||
ERROR: NonExistentClass - input.hack:21:15 - Cannot call new on undefined class A | ||
ERROR: InvalidReturnStatement - input.hack:26:16 - The type string(a) does not match the declared return type int for B::bat |
2 changes: 1 addition & 1 deletion
2
tests/inference/ArrayAccess/mixedArrayAccessDictWrapped/output.txt
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
ERROR: PossiblyUndefinedStringArrayOffset - input.hack:6:10 - Fetch on dict<arraykey,any> using possibly-undefined key 'foo' | ||
ERROR: MixedAnyArgument - input.hack:6:10 - Argument 1 of echo expects arraykey, any provided | ||
ERROR: MixedAnyArgument - input.hack:6:10 - Argument 1 of echo expects scalar|null, any provided |
2 changes: 0 additions & 2 deletions
2
...nference/FunctionCall/idxMixed/input.hack → ...ctionCall/idxMixedExplicitNull/input.hack
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
function foo(dict<string, mixed> $args): void { | ||
$a = idx($args, 'a', null); | ||
$b = idx($args, 'b'); | ||
if ($a === null) {} | ||
if ($b === null) {} | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
function foo(dict<string, mixed> $args): void { | ||
$b = idx($args, 'b'); | ||
if ($b === null) {} | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
NullArgument | ||
InvalidArgument |
2 changes: 1 addition & 1 deletion
2
tests/inference/Interface/interfaceRequireExtendsClassNegation/output.txt
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
ERROR: InvalidArgument - input.hack:21:10 - Argument 1 of echo expects arraykey, different type Node provided | ||
ERROR: InvalidArgument - input.hack:21:10 - Argument 1 of echo expects scalar|null, different type Node provided |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
NullArgument | ||
InvalidArgument |
2 changes: 1 addition & 1 deletion
2
...nference/MethodCall/unchainedInferredInferredMutationFreeMethodCallDontMemoize/output.txt
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
PossiblyNullArgument | ||
PossiblyInvalidArgument |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
ERROR: InvalidArgument - input.hack:11:14 - Argument 1 of echo expects arraykey, different type Exception provided | ||
ERROR: InvalidArgument - input.hack:11:14 - Argument 1 of echo expects scalar|null, different type Exception provided |
2 changes: 1 addition & 1 deletion
2
tests/inference/TypeAlias/classConstTypeAliasViaTrait/output.txt
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
ERROR: InvalidArgument - input.hack:23:14 - Argument 1 of echo expects arraykey, different type Exception provided | ||
ERROR: InvalidArgument - input.hack:23:14 - Argument 1 of echo expects scalar|null, different type Exception provided |
2 changes: 1 addition & 1 deletion
2
tests/inference/TypeReconciliation/AsExpression/nestedAnyArrayAccess/output.txt
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
ERROR: MixedAnyArrayAccess - input.hack:3:10 - Unsafe array access on value with type any | ||
ERROR: MixedAnyArrayAccess - input.hack:4:10 - Unsafe array access on value with type nonnull-from-any | ||
ERROR: MixedAnyArgument - input.hack:4:10 - Argument 1 of echo expects arraykey, any provided | ||
ERROR: MixedAnyArgument - input.hack:4:10 - Argument 1 of echo expects scalar|null, any provided | ||
ERROR: MixedAnyReturnStatement - input.hack:5:12 - Could not infer a proper return type — saw nonnull-from-any |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
ERROR: NonExistentClass - input.hack:2:12 - Cannot call new on undefined class Foo | ||
ERROR: MixedAnyReturnStatement - input.hack:2:12 - Could not infer a proper return type — saw any | ||
ERROR: NonExistentClasslike - input.hack:6:10 - Unknown classlike Foo | ||
ERROR: MixedAnyArgument - input.hack:6:10 - Argument 1 of echo expects arraykey, any provided | ||
ERROR: MixedAnyArgument - input.hack:6:10 - Argument 1 of echo expects scalar|null, any provided | ||
ERROR: NonExistentClasslike - input.hack:9:12 - Class, enum or interface Foo cannot be found | ||
ERROR: NonExistentClasslike - input.hack:13:10 - Unknown classlike Foo | ||
ERROR: MixedAnyArgument - input.hack:13:10 - Argument 1 of echo expects arraykey, any provided | ||
ERROR: MixedAnyArgument - input.hack:13:10 - Argument 1 of echo expects scalar|null, any provided | ||
ERROR: NonExistentClasslike - input.hack:23:5 - Unknown classlike Foo | ||
ERROR: NonExistentClass - input.hack:28:10 - Cannot access property on undefined class Foo | ||
ERROR: MixedAnyArgument - input.hack:28:10 - Argument 1 of echo expects arraykey, any provided | ||
ERROR: MixedAnyArgument - input.hack:28:10 - Argument 1 of echo expects scalar|null, any provided | ||
ERROR: NonExistentClass - input.hack:33:10 - Cannot access property on undefined class Foo | ||
ERROR: InvalidArgument - input.hack:33:10 - Argument 1 of echo expects arraykey, different type unknown-ref(Foo) provided | ||
ERROR: InvalidArgument - input.hack:33:10 - Argument 1 of echo expects scalar|null, different type unknown-ref(Foo) provided | ||
ERROR: NonExistentClass - input.hack:37:10 - Cannot access property on undefined class Foo | ||
ERROR: MixedAnyArgument - input.hack:37:10 - Argument 1 of echo expects arraykey, any provided | ||
ERROR: MixedAnyArgument - input.hack:37:10 - Argument 1 of echo expects scalar|null, any provided | ||
ERROR: NonExistentClass - input.hack:42:9 - Undefined class Foo |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
ERROR: NonExistentClassConstant - input.hack:8:10 - Unknown class constant Foo::B1 | ||
ERROR: MixedAnyArgument - input.hack:8:10 - Argument 1 of echo expects arraykey, any provided | ||
ERROR: MixedAnyArgument - input.hack:8:10 - Argument 1 of echo expects scalar|null, any provided | ||
ERROR: NonExistentClassConstant - input.hack:16:5 - Unknown class constant Foo::B3 | ||
ERROR: NonExistentClassConstant - input.hack:20:10 - Unknown class constant Foo::B4 | ||
ERROR: MixedAnyArgument - input.hack:20:10 - Argument 1 of echo expects arraykey, any provided | ||
ERROR: MixedAnyArgument - input.hack:20:10 - Argument 1 of echo expects scalar|null, any provided | ||
ERROR: NonExistentMethod - input.hack:24:5 - Method Foo::b5 does not exist | ||
ERROR: NonExistentMethod - input.hack:28:5 - Method Foo::b6 does not exist | ||
ERROR: NonExistentProperty - input.hack:32:10 - Cannot access undefined property Foo::$b7 | ||
ERROR: MixedAnyArgument - input.hack:32:10 - Argument 1 of echo expects arraykey, any provided | ||
ERROR: MixedAnyArgument - input.hack:32:10 - Argument 1 of echo expects scalar|null, any provided | ||
ERROR: NonExistentProperty - input.hack:36:10 - Cannot access undefined property Foo::$b8 | ||
ERROR: InvalidArgument - input.hack:36:10 - Argument 1 of echo expects arraykey, different type Foo provided | ||
ERROR: InvalidArgument - input.hack:36:10 - Argument 1 of echo expects scalar|null, different type Foo provided | ||
ERROR: NonExistentProperty - input.hack:40:10 - Property Foo::$b9 is undefined | ||
ERROR: NonExistentProperty - input.hack:44:9 - Undefined property Foo::$b10 |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
ERROR: NonExistentFunction - input.hack:2:5 - Function f1 is not defined | ||
ERROR: NonExistentFunction - input.hack:6:10 - Unknown function f2 | ||
ERROR: MixedAnyArgument - input.hack:6:10 - Argument 1 of echo expects arraykey, any provided | ||
ERROR: MixedAnyArgument - input.hack:6:10 - Argument 1 of echo expects scalar|null, any provided | ||
ERROR: NonExistentFunction - input.hack:10:5 - Function f3 is not defined |