From afac86e51e7726b8d0c00baac8d105f62d86a81e Mon Sep 17 00:00:00 2001 From: Wilfred Hughes Date: Mon, 29 Aug 2022 11:47:38 -0700 Subject: [PATCH] Print unresolved types as _ Summary: If we can't resolve a type variable, display it as "_" rather than "[unresolved]". This makes type errors easier to read. For example, if a user writes `await 1` we used to show: ``` -> Expected Awaitable<[unresolved]> -> But got int ``` The problem isn't that we couldn't find an inner type for `Awaitable`. The problem is that `1` isn't an awaitable value at all! We now show this: ``` -> Expected Awaitable<_> -> But got int ``` This is much easier to read, especially in larger types. It's also consistent with `Terr`. Reviewed By: hgoldstein Differential Revision: D39067882 fbshipit-source-id: 0e758cf36fe9c73f3b6347d7f53572fabeadeca3 --- hphp/hack/src/typing/typing_print.ml | 2 +- hphp/hack/test/decl/yield_deeper.php.typecheck.exp | 2 +- .../position_within_position.php.exp | 2 +- .../typing/generic_constraint_dynamic.bad.php.exp | 2 +- .../typing/sound_dynamic_callable_1.bad.php.exp | 2 +- ...ound_dynamic_callable_1.bad.php.legacy_decl.exp | 2 +- .../typing/sound_dynamic_callable_2.bad.php.exp | 2 +- ...ound_dynamic_callable_2.bad.php.legacy_decl.exp | 2 +- .../sound_dynamic/typing/supportdyn.bad.php.exp | 2 +- .../typing/supportdynamic.bad.php.exp | 2 +- .../typecheck/akempty/akempty_promotion_4.php.exp | 2 +- hphp/hack/test/typecheck/anon13.php.pess_exp | 2 +- hphp/hack/test/typecheck/anyarray_bad.php.exp | 4 +- .../argument_unpacking/unpack_call1.php.exp | 132 ++++++++++----------- .../argument_unpacking/unpack_call3.php.exp | 8 +- .../argument_unpacking/unpack_call6.php.exp | 8 +- .../argument_unpacking/unpack_call_mixed.php.exp | 2 +- hphp/hack/test/typecheck/arithmetic_any.php.exp | 4 +- ..._int_when_array_of_tk_to_tv_is_required.php.exp | 2 +- .../test/typecheck/array_append_set_bad.php.exp | 2 +- hphp/hack/test/typecheck/array_sub.php.exp | 2 +- hphp/hack/test/typecheck/array_sub2.php.exp | 2 +- ...ssign_unresolved_obj_get.php.tast_typecheck_exp | 2 +- ...as_an_expression_awaiting_non_awaitable.php.exp | 8 +- .../test/typecheck/await_on_illegal_value.php.exp | 2 +- .../strong_precedence/await_new_precedence.php.exp | 20 ++-- .../weak_precedence/await_old_precedence.php.exp | 20 ++-- .../error/concurrent_non_awaitable.php.exp | 8 +- .../continuation_is_not_awaitable2.php.exp | 2 +- .../test/typecheck/control_flow/lambda.php.exp | 12 +- .../test/typecheck/dynamic/collections.php.exp | 4 +- .../test/typecheck/dynamic/foreach_union.php.exp | 24 ++-- .../typecheck/enum_class_label/xcont.php.pess_exp | 2 +- hphp/hack/test/typecheck/erling_loop2.php.exp | 2 +- .../explicit_type_collection_wildcard_map1.php.exp | 2 +- .../explicit_type_collection_wildcard_map2.php.exp | 2 +- .../explicit_type_collection_wildcard_map3.php.exp | 2 +- .../typecheck/expression_trees/dict_error.php.exp | 4 +- .../expression_trees/nested_splicing.php.exp | 2 +- .../expression_trees/nested_splicing2.php.exp | 2 +- .../test/typecheck/expression_trees/pipe2.php.exp | 4 +- .../test/typecheck/expression_trees/pipe5.php.exp | 4 +- .../splice_err1.php.exp | 4 +- .../typecheck/expression_trees/splice_err4.php.exp | 4 +- .../dict_error.php.exp | 4 +- .../nested_splicing.php.exp | 2 +- .../nested_splicing2.php.exp | 2 +- .../pipe2.php.exp | 4 +- .../pipe5.php.exp | 4 +- .../splice_err1.php.exp | 4 +- .../splice_err4.php.exp | 4 +- .../ffp/function_async_lambda_bad.php.exp | 4 +- hphp/hack/test/typecheck/ffp/throw_yield.php.exp | 4 +- hphp/hack/test/typecheck/ffp/yield_bad1.php.exp | 2 +- hphp/hack/test/typecheck/ffp/yield_bad2.php.exp | 2 +- .../test/typecheck/functional_generator.php.exp | 2 +- hphp/hack/test/typecheck/gen6.php.exp | 2 +- .../hack/test/typecheck/hh_fixme_bug3.php.pess_exp | 2 +- hphp/hack/test/typecheck/hhfixme_bug2.php.pess_exp | 2 +- .../test/typecheck/hhfixme_bug2.php.tgt_pess_exp | 2 +- hphp/hack/test/typecheck/idx2_4.php.exp | 2 +- hphp/hack/test/typecheck/idx3_5.php.exp | 2 +- .../invalid_arraykey/invalid_arraykey.php.exp | 8 +- hphp/hack/test/typecheck/keys.php.exp | 2 +- .../test/typecheck/lambda/async_lambda2.php.exp | 2 +- .../variadics/lambda_unpacked_parameters.php.exp | 2 +- .../test/typecheck/list_generic_assign.php.exp | 8 +- .../expect_awaitable_in_await.php.exp | 2 +- .../test/typecheck/namespace_collections3.php.exp | 8 +- .../typecheck/new_inference/async_lambda.php.exp | 2 +- .../eager_solve/array_append_bad.php.exp | 2 +- .../function_apply_hard.php.tast_typecheck_exp | 2 +- ...llable_array_append_hard.php.tast_typecheck_exp | 2 +- .../new_inference/instance_of_refinement.php.exp | 2 +- .../new_inference/oldtypehole/t21684610.php.exp | 4 +- .../new_inference/typehole/t21684610.php.exp | 2 +- .../untypeable/closure.php.tast_typecheck_exp | 2 +- .../test/typecheck/nonnull/await_nonnull.php.exp | 2 +- .../option_is_not_subtype_of_nonnull1.php.exp | 24 ++-- .../option_is_not_subtype_of_nonnull2.php.exp | 24 ++-- .../re_prefixed_string/re_prefixed_string.php.exp | 16 +-- .../test/typecheck/recursive_non_null_4.php.exp | 8 +- .../hack/test/typecheck/recursive_optional.php.exp | 2 +- .../reified_generics/new_self_new_parent.php.exp | 4 +- hphp/hack/test/typecheck/shape_idx4.php.exp | 2 +- .../test/typecheck/shapes_remove_key.php.pess_exp | 2 +- .../typecheck/shapes_remove_key.php.tgt_pess_exp | 2 +- .../test/typecheck/traversable_foreach3.php.exp | 8 +- .../type_structure/type_structure1.php.exp | 2 +- hphp/hack/test/typecheck/unify_unresolved.php.exp | 2 +- hphp/hack/test/typecheck/union/generics.php.exp | 12 +- .../test/typecheck/union/map_corner_case.php.exp | 2 +- .../union/map_corner_case.php.legacy_decl.exp | 2 +- hphp/hack/test/typecheck/union/mixed.php.exp | 2 +- hphp/hack/test/typecheck/variadic_args1.php.exp | 2 +- hphp/hack/test/typecheck/yield/asyncgen11.php.exp | 2 +- hphp/hack/test/typecheck/yield/asyncgen2.php.exp | 8 +- hphp/hack/test/typecheck/yield/asyncgen3.php.exp | 2 +- hphp/hack/test/typecheck/yield/asyncgen4.php.exp | 4 +- hphp/hack/test/typecheck/yield/asyncgen5.php.exp | 2 +- hphp/hack/test/typecheck/yield/asyncgen6.php.exp | 8 +- hphp/hack/test/typecheck/yield/asyncgen9.php.exp | 8 +- .../typecheck/yield/yield_lambda_async.php.exp | 4 +- hphp/hack/test/typecheck/yield_method.php.exp | 2 +- 104 files changed, 292 insertions(+), 292 deletions(-) rewrite hphp/hack/test/typecheck/argument_unpacking/unpack_call1.php.exp (69%) rewrite hphp/hack/test/typecheck/dynamic/foreach_union.php.exp (66%) copy hphp/hack/test/typecheck/{expression_trees_not_virtualize_functions => expression_trees}/splice_err1.php.exp (68%) copy hphp/hack/test/typecheck/{expression_trees => expression_trees_not_virtualize_functions}/splice_err4.php.exp (68%) rewrite hphp/hack/test/typecheck/nonnull/option_is_not_subtype_of_nonnull1.php.exp (63%) rewrite hphp/hack/test/typecheck/nonnull/option_is_not_subtype_of_nonnull2.php.exp (63%) diff --git a/hphp/hack/src/typing/typing_print.ml b/hphp/hack/src/typing/typing_print.ml index 2bddd3ca797..eb0dd81dfa5 100644 --- a/hphp/hack/src/typing/typing_print.ml +++ b/hphp/hack/src/typing/typing_print.ml @@ -653,7 +653,7 @@ module Full = struct if ISet.mem n' st then text "[rec]" else if !blank_tyvars then - text "[unresolved]" + text "_" else text ("#" ^ string_of_int n') in diff --git a/hphp/hack/test/decl/yield_deeper.php.typecheck.exp b/hphp/hack/test/decl/yield_deeper.php.typecheck.exp index 1a15df01fa0..906fbefce17 100644 --- a/hphp/hack/test/decl/yield_deeper.php.typecheck.exp +++ b/hphp/hack/test/decl/yield_deeper.php.typecheck.exp @@ -1,6 +1,6 @@ File "yield_deeper.php", line 20, characters 3-45: `await` can only operate on an `Awaitable` (Typing[4110]) File "yield_deeper.php", line 20, characters 3-45: - Expected `Awaitable<[unresolved]>` + Expected `Awaitable<_>` File "yield_deeper.php", line 20, characters 9-45: But got `AsyncGenerator` (result of `async function` containing a `yield`) diff --git a/hphp/hack/test/error_formatting_highlighted/position_within_position.php.exp b/hphp/hack/test/error_formatting_highlighted/position_within_position.php.exp index ea39c963193..5a93276556b 100644 --- a/hphp/hack/test/error_formatting_highlighted/position_within_position.php.exp +++ b/hphp/hack/test/error_formatting_highlighted/position_within_position.php.exp @@ -1,5 +1,5 @@ Typing[4110] await can only operate on an Awaitable [1] --> Expected Awaitable<[unresolved]> [1] +-> Expected Awaitable<_> [1] -> But got int [2] position_within_position.php:4:3 diff --git a/hphp/hack/test/sound_dynamic/typing/generic_constraint_dynamic.bad.php.exp b/hphp/hack/test/sound_dynamic/typing/generic_constraint_dynamic.bad.php.exp index fca26833db6..6a2bfa1104e 100644 --- a/hphp/hack/test/sound_dynamic/typing/generic_constraint_dynamic.bad.php.exp +++ b/hphp/hack/test/sound_dynamic/typing/generic_constraint_dynamic.bad.php.exp @@ -13,7 +13,7 @@ Some type arguments violate their constraints (Typing[4323]) File "generic_constraint_dynamic.bad.php", line 21, characters 14-20: Invalid argument (Typing[4110]) File "generic_constraint_dynamic.bad.php", line 21, characters 12-12: - Expected `~[unresolved]` because type parameter `T` of `C` could not be determined. Please add explicit type parameters to the invocation of `C` + Expected `~_` because type parameter `T` of `C` could not be determined. Please add explicit type parameters to the invocation of `C` File "generic_constraint_dynamic.bad.php", line 6, characters 39-39: via this generic `T` File "generic_constraint_dynamic.bad.php", line 21, characters 18-18: diff --git a/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_1.bad.php.exp b/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_1.bad.php.exp index a62136418a7..2249b84d202 100644 --- a/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_1.bad.php.exp +++ b/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_1.bad.php.exp @@ -5,4 +5,4 @@ Method `foo` in class `C` is not dynamically callable. (Typing[4110]) File "sound_dynamic_callable_1.bad.php", line 11, characters 27-34: Expected `dynamic` because method must be callable in a dynamic context File "sound_dynamic_callable_1.bad.php", line 12, characters 16-18: - Type `Box<[unresolved]>` is not a subtype of `dynamic` under dynamic-aware subtyping + Type `Box<_>` is not a subtype of `dynamic` under dynamic-aware subtyping diff --git a/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_1.bad.php.legacy_decl.exp b/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_1.bad.php.legacy_decl.exp index a62136418a7..2249b84d202 100644 --- a/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_1.bad.php.legacy_decl.exp +++ b/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_1.bad.php.legacy_decl.exp @@ -5,4 +5,4 @@ Method `foo` in class `C` is not dynamically callable. (Typing[4110]) File "sound_dynamic_callable_1.bad.php", line 11, characters 27-34: Expected `dynamic` because method must be callable in a dynamic context File "sound_dynamic_callable_1.bad.php", line 12, characters 16-18: - Type `Box<[unresolved]>` is not a subtype of `dynamic` under dynamic-aware subtyping + Type `Box<_>` is not a subtype of `dynamic` under dynamic-aware subtyping diff --git a/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_2.bad.php.exp b/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_2.bad.php.exp index fa3ab1d37ea..e5230ed1af4 100644 --- a/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_2.bad.php.exp +++ b/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_2.bad.php.exp @@ -5,4 +5,4 @@ Method `foo` in class `C` is not dynamically callable. (Typing[4110]) File "sound_dynamic_callable_2.bad.php", line 10, characters 27-34: Expected `dynamic` because method must be callable in a dynamic context File "sound_dynamic_callable_2.bad.php", line 11, characters 16-18: - Type `Box<[unresolved]>` is not a subtype of `dynamic` under dynamic-aware subtyping + Type `Box<_>` is not a subtype of `dynamic` under dynamic-aware subtyping diff --git a/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_2.bad.php.legacy_decl.exp b/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_2.bad.php.legacy_decl.exp index fa3ab1d37ea..e5230ed1af4 100644 --- a/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_2.bad.php.legacy_decl.exp +++ b/hphp/hack/test/sound_dynamic/typing/sound_dynamic_callable_2.bad.php.legacy_decl.exp @@ -5,4 +5,4 @@ Method `foo` in class `C` is not dynamically callable. (Typing[4110]) File "sound_dynamic_callable_2.bad.php", line 10, characters 27-34: Expected `dynamic` because method must be callable in a dynamic context File "sound_dynamic_callable_2.bad.php", line 11, characters 16-18: - Type `Box<[unresolved]>` is not a subtype of `dynamic` under dynamic-aware subtyping + Type `Box<_>` is not a subtype of `dynamic` under dynamic-aware subtyping diff --git a/hphp/hack/test/sound_dynamic/typing/supportdyn.bad.php.exp b/hphp/hack/test/sound_dynamic/typing/supportdyn.bad.php.exp index b901fe1396d..d7d12998bf8 100644 --- a/hphp/hack/test/sound_dynamic/typing/supportdyn.bad.php.exp +++ b/hphp/hack/test/sound_dynamic/typing/supportdyn.bad.php.exp @@ -55,7 +55,7 @@ Invalid `foreach` (Typing[4110]) File "supportdyn.bad.php", line 21, characters 3-11: `await` can only operate on an `Awaitable` (Typing[4110]) File "supportdyn.bad.php", line 21, characters 3-11: - Expected `Awaitable<[unresolved]>` + Expected `Awaitable<_>` File "supportdyn.bad.php", line 18, characters 32-38: But got `nonnull` File "supportdynamic.hhi", line 6, characters 29-29: diff --git a/hphp/hack/test/sound_dynamic/typing/supportdynamic.bad.php.exp b/hphp/hack/test/sound_dynamic/typing/supportdynamic.bad.php.exp index 34e93696edc..4398c35cf29 100644 --- a/hphp/hack/test/sound_dynamic/typing/supportdynamic.bad.php.exp +++ b/hphp/hack/test/sound_dynamic/typing/supportdynamic.bad.php.exp @@ -55,7 +55,7 @@ Invalid `foreach` (Typing[4110]) File "supportdynamic.bad.php", line 18, characters 3-11: `await` can only operate on an `Awaitable` (Typing[4110]) File "supportdynamic.bad.php", line 18, characters 3-11: - Expected `Awaitable<[unresolved]>` + Expected `Awaitable<_>` File "supportdynamic.bad.php", line 15, characters 32-38: But got `nonnull` File "supportdynamic.hhi", line 6, characters 29-29: diff --git a/hphp/hack/test/typecheck/akempty/akempty_promotion_4.php.exp b/hphp/hack/test/typecheck/akempty/akempty_promotion_4.php.exp index 63069bd1180..7ad1e5498ab 100644 --- a/hphp/hack/test/typecheck/akempty/akempty_promotion_4.php.exp +++ b/hphp/hack/test/typecheck/akempty/akempty_promotion_4.php.exp @@ -3,4 +3,4 @@ Invalid argument (Typing[4110]) File "akempty_promotion_4.php", line 12, characters 24-26: Expected `int` File "akempty_promotion_4.php", line 7, characters 17-24: - But got `vec<(string | [unresolved])>` + But got `vec<(string | _)>` diff --git a/hphp/hack/test/typecheck/anon13.php.pess_exp b/hphp/hack/test/typecheck/anon13.php.pess_exp index 7f5985fd8fe..7ede3c1b8da 100644 --- a/hphp/hack/test/typecheck/anon13.php.pess_exp +++ b/hphp/hack/test/typecheck/anon13.php.pess_exp @@ -3,4 +3,4 @@ Invalid return type (Typing[4110]) File "anon13.php.pess", line 16, characters 18-59: Expected `~Vector>` File "anon13.php.pess", line 17, characters 8-62: - But got `Vector>` + But got `Vector>` diff --git a/hphp/hack/test/typecheck/anyarray_bad.php.exp b/hphp/hack/test/typecheck/anyarray_bad.php.exp index a533f73591a..b7c02add3cf 100644 --- a/hphp/hack/test/typecheck/anyarray_bad.php.exp +++ b/hphp/hack/test/typecheck/anyarray_bad.php.exp @@ -5,13 +5,13 @@ Invalid argument (Typing[4110]) File "anyarray_bad.php", line 3, characters 22-39: Expected `AnyArray` File "anyarray_bad.php", line 10, characters 15-20: - But got `Map<[unresolved], [unresolved]>` + But got `Map<_, _>` File "anyarray_bad.php", line 11, characters 15-20: Invalid argument (Typing[4110]) File "anyarray_bad.php", line 3, characters 22-39: Expected `AnyArray` File "anyarray_bad.php", line 11, characters 15-20: - But got `Set<[unresolved]>` + But got `Set<_>` File "anyarray_bad.php", line 12, characters 15-26: Invalid argument (Typing[4110]) File "anyarray_bad.php", line 3, characters 22-39: diff --git a/hphp/hack/test/typecheck/argument_unpacking/unpack_call1.php.exp b/hphp/hack/test/typecheck/argument_unpacking/unpack_call1.php.exp dissimilarity index 69% index b469ed95fd0..ecb358b1c6a 100644 --- a/hphp/hack/test/typecheck/argument_unpacking/unpack_call1.php.exp +++ b/hphp/hack/test/typecheck/argument_unpacking/unpack_call1.php.exp @@ -1,66 +1,66 @@ -File "unpack_call1.php", line 38, characters 8-12: -Invalid argument (Typing[4359]) -File "unpack_call1.php", line 38, characters 8-12: -An array cannot be unpacked into the required arguments of a function -File "unpack_call1.php", line 3, characters 10-10: -Definition is here -File "unpack_call1.php", line 39, characters 21-25: -Invalid argument (Typing[4359]) -File "unpack_call1.php", line 39, characters 21-25: -An array cannot be unpacked into the required arguments of a function -File "unpack_call1.php", line 8, characters 19-29: -Definition is here -File "unpack_call1.php", line 40, characters 15-19: -Invalid argument (Typing[4359]) -File "unpack_call1.php", line 40, characters 15-19: -An array cannot be unpacked into the required arguments of a function -File "unpack_call1.php", line 12, characters 19-19: -Definition is here -File "unpack_call1.php", line 41, characters 21-25: -Invalid argument (Typing[4359]) -File "unpack_call1.php", line 41, characters 21-25: -An array cannot be unpacked into the required arguments of a function -File "unpack_call1.php", line 16, characters 19-29: -Definition is here -File "unpack_call1.php", line 42, characters 15-19: -Invalid argument (Typing[4359]) -File "unpack_call1.php", line 42, characters 15-19: -An array cannot be unpacked into the required arguments of a function -File "unpack_call1.php", line 12, characters 19-19: -Definition is here -File "unpack_call1.php", line 51, characters 8-22: -Invalid argument (Typing[4359]) -File "unpack_call1.php", line 51, characters 8-22: -An array cannot be unpacked into the required arguments of a function -File "unpack_call1.php", line 3, characters 10-10: -Definition is here -File "unpack_call1.php", line 53, characters 8-14: -Invalid argument (Typing[4359]) -File "unpack_call1.php", line 53, characters 8-14: -An array cannot be unpacked into the required arguments of a function -File "unpack_call1.php", line 3, characters 10-10: -Definition is here -File "unpack_call1.php", line 69, characters 8-12: -Invalid argument (Typing[4359]) -File "unpack_call1.php", line 69, characters 8-12: -An array cannot be unpacked into the required arguments of a function -File "unpack_call1.php", line 3, characters 10-10: -Definition is here -File "unpack_call1.php", line 75, characters 8-12: -Invalid argument (Typing[4359]) -File "unpack_call1.php", line 75, characters 8-12: -An array cannot be unpacked into the required arguments of a function -File "unpack_call1.php", line 3, characters 10-10: -Definition is here -File "unpack_call1.php", line 85, characters 8-19: -Invalid argument (Typing[4110]) -File "unpack_call1.php", line 85, characters 8-19: -Expected `Traversable<[unresolved]>` (it is unpacked with `...`) -File "unpack_call1.php", line 90, characters 24-28: -But got `mixed` -File "unpack_call1.php", line 87, characters 8-14: -Invalid argument (Typing[4110]) -File "unpack_call1.php", line 87, characters 8-14: -Expected `Traversable<[unresolved]>` (it is unpacked with `...`) -File "unpack_call1.php", line 90, characters 24-28: -But got `mixed` +File "unpack_call1.php", line 38, characters 8-12: +Invalid argument (Typing[4359]) + File "unpack_call1.php", line 38, characters 8-12: + An array cannot be unpacked into the required arguments of a function + File "unpack_call1.php", line 3, characters 10-10: + Definition is here +File "unpack_call1.php", line 39, characters 21-25: +Invalid argument (Typing[4359]) + File "unpack_call1.php", line 39, characters 21-25: + An array cannot be unpacked into the required arguments of a function + File "unpack_call1.php", line 8, characters 19-29: + Definition is here +File "unpack_call1.php", line 40, characters 15-19: +Invalid argument (Typing[4359]) + File "unpack_call1.php", line 40, characters 15-19: + An array cannot be unpacked into the required arguments of a function + File "unpack_call1.php", line 12, characters 19-19: + Definition is here +File "unpack_call1.php", line 41, characters 21-25: +Invalid argument (Typing[4359]) + File "unpack_call1.php", line 41, characters 21-25: + An array cannot be unpacked into the required arguments of a function + File "unpack_call1.php", line 16, characters 19-29: + Definition is here +File "unpack_call1.php", line 42, characters 15-19: +Invalid argument (Typing[4359]) + File "unpack_call1.php", line 42, characters 15-19: + An array cannot be unpacked into the required arguments of a function + File "unpack_call1.php", line 12, characters 19-19: + Definition is here +File "unpack_call1.php", line 51, characters 8-22: +Invalid argument (Typing[4359]) + File "unpack_call1.php", line 51, characters 8-22: + An array cannot be unpacked into the required arguments of a function + File "unpack_call1.php", line 3, characters 10-10: + Definition is here +File "unpack_call1.php", line 53, characters 8-14: +Invalid argument (Typing[4359]) + File "unpack_call1.php", line 53, characters 8-14: + An array cannot be unpacked into the required arguments of a function + File "unpack_call1.php", line 3, characters 10-10: + Definition is here +File "unpack_call1.php", line 69, characters 8-12: +Invalid argument (Typing[4359]) + File "unpack_call1.php", line 69, characters 8-12: + An array cannot be unpacked into the required arguments of a function + File "unpack_call1.php", line 3, characters 10-10: + Definition is here +File "unpack_call1.php", line 75, characters 8-12: +Invalid argument (Typing[4359]) + File "unpack_call1.php", line 75, characters 8-12: + An array cannot be unpacked into the required arguments of a function + File "unpack_call1.php", line 3, characters 10-10: + Definition is here +File "unpack_call1.php", line 85, characters 8-19: +Invalid argument (Typing[4110]) + File "unpack_call1.php", line 85, characters 8-19: + Expected `Traversable<_>` (it is unpacked with `...`) + File "unpack_call1.php", line 90, characters 24-28: + But got `mixed` +File "unpack_call1.php", line 87, characters 8-14: +Invalid argument (Typing[4110]) + File "unpack_call1.php", line 87, characters 8-14: + Expected `Traversable<_>` (it is unpacked with `...`) + File "unpack_call1.php", line 90, characters 24-28: + But got `mixed` diff --git a/hphp/hack/test/typecheck/argument_unpacking/unpack_call3.php.exp b/hphp/hack/test/typecheck/argument_unpacking/unpack_call3.php.exp index f07cf0ed50b..a14d35fd42f 100644 --- a/hphp/hack/test/typecheck/argument_unpacking/unpack_call3.php.exp +++ b/hphp/hack/test/typecheck/argument_unpacking/unpack_call3.php.exp @@ -1,6 +1,6 @@ File "unpack_call3.php", line 7, characters 8-12: Invalid argument (Typing[4110]) -File "unpack_call3.php", line 7, characters 8-12: -Expected `Traversable<[unresolved]>` (it is unpacked with `...`) -File "unpack_call3.php", line 6, characters 11-18: -But got `string` + File "unpack_call3.php", line 7, characters 8-12: + Expected `Traversable<_>` (it is unpacked with `...`) + File "unpack_call3.php", line 6, characters 11-18: + But got `string` diff --git a/hphp/hack/test/typecheck/argument_unpacking/unpack_call6.php.exp b/hphp/hack/test/typecheck/argument_unpacking/unpack_call6.php.exp index bba0142f098..d239e23f495 100644 --- a/hphp/hack/test/typecheck/argument_unpacking/unpack_call6.php.exp +++ b/hphp/hack/test/typecheck/argument_unpacking/unpack_call6.php.exp @@ -1,6 +1,6 @@ File "unpack_call6.php", line 12, characters 13-17: Invalid argument (Typing[4110]) -File "unpack_call6.php", line 12, characters 13-17: -Expected `Traversable<[unresolved]>` (it is unpacked with `...`) -File "unpack_call6.php", line 11, characters 11-18: -But got `string` + File "unpack_call6.php", line 12, characters 13-17: + Expected `Traversable<_>` (it is unpacked with `...`) + File "unpack_call6.php", line 11, characters 11-18: + But got `string` diff --git a/hphp/hack/test/typecheck/argument_unpacking/unpack_call_mixed.php.exp b/hphp/hack/test/typecheck/argument_unpacking/unpack_call_mixed.php.exp index d756c9c4c1e..d88bc7b817a 100644 --- a/hphp/hack/test/typecheck/argument_unpacking/unpack_call_mixed.php.exp +++ b/hphp/hack/test/typecheck/argument_unpacking/unpack_call_mixed.php.exp @@ -1,6 +1,6 @@ File "unpack_call_mixed.php", line 5, characters 9-13: Typing error (Typing[4110]) File "unpack_call_mixed.php", line 5, characters 9-13: - Expected `Traversable<[unresolved]>` (it is unpacked with `...`) + Expected `Traversable<_>` (it is unpacked with `...`) File "unpack_call_mixed.php", line 3, characters 25-35: But got `?vec` diff --git a/hphp/hack/test/typecheck/arithmetic_any.php.exp b/hphp/hack/test/typecheck/arithmetic_any.php.exp index 5a5ec76e202..05d461780a0 100644 --- a/hphp/hack/test/typecheck/arithmetic_any.php.exp +++ b/hphp/hack/test/typecheck/arithmetic_any.php.exp @@ -23,9 +23,9 @@ File "arithmetic_any.php--file2.php", line 58, characters 3-13: File "arithmetic_any.php--file2.php", line 63, characters 3-13: _ File "arithmetic_any.php--file2.php", line 75, characters 35-45: - [unresolved] + _ File "arithmetic_any.php--file2.php", line 75, characters 48-58: - [unresolved] + _ File "arithmetic_any.php--file2.php", line 84, characters 3-13: _ File "arithmetic_any.php--file2.php", line 89, characters 3-13: diff --git a/hphp/hack/test/typecheck/array/safe_vector_array/disallows_array_of_int_when_array_of_tk_to_tv_is_required.php.exp b/hphp/hack/test/typecheck/array/safe_vector_array/disallows_array_of_int_when_array_of_tk_to_tv_is_required.php.exp index 1996c8efb00..635202a5181 100644 --- a/hphp/hack/test/typecheck/array/safe_vector_array/disallows_array_of_int_when_array_of_tk_to_tv_is_required.php.exp +++ b/hphp/hack/test/typecheck/array/safe_vector_array/disallows_array_of_int_when_array_of_tk_to_tv_is_required.php.exp @@ -11,6 +11,6 @@ Some type arguments violate their constraints (Typing[4323]) File "disallows_array_of_int_when_array_of_tk_to_tv_is_required.php", line 6, characters 24-34: Invalid argument (Typing[4110]) File "disallows_array_of_int_when_array_of_tk_to_tv_is_required.php", line 3, characters 39-52: - Expected `dict<[unresolved], [unresolved]>` + Expected `dict<_, _>` File "disallows_array_of_int_when_array_of_tk_to_tv_is_required.php", line 5, characters 15-25: But got `vec` diff --git a/hphp/hack/test/typecheck/array_append_set_bad.php.exp b/hphp/hack/test/typecheck/array_append_set_bad.php.exp index 97d06878d38..14effc79991 100644 --- a/hphp/hack/test/typecheck/array_append_set_bad.php.exp +++ b/hphp/hack/test/typecheck/array_append_set_bad.php.exp @@ -7,6 +7,6 @@ Invalid assignment (Typing[4110]) File "array_append_set_bad.php", line 20, characters 3-12: Set values must be arraykeys (Typing[4324]) File "array_append_set_bad.php", line 19, characters 8-12: - This container is an object of type Set<[unresolved]> + This container is an object of type Set<_> File "array_append_set_bad.php", line 20, characters 10-12: A float is not an arraykey diff --git a/hphp/hack/test/typecheck/array_sub.php.exp b/hphp/hack/test/typecheck/array_sub.php.exp index a5ef7e3eecb..33a99bba3e5 100644 --- a/hphp/hack/test/typecheck/array_sub.php.exp +++ b/hphp/hack/test/typecheck/array_sub.php.exp @@ -11,6 +11,6 @@ Some type arguments violate their constraints (Typing[4323]) File "array_sub.php", line 21, characters 12-13: Invalid argument (Typing[4110]) File "array_sub.php", line 12, characters 27-40: - Expected `dict<[unresolved], [unresolved]>` + Expected `dict<_, _>` File "array_sub.php", line 20, characters 15-25: But got `vec` diff --git a/hphp/hack/test/typecheck/array_sub2.php.exp b/hphp/hack/test/typecheck/array_sub2.php.exp index 88939cc9eee..b075343da9c 100644 --- a/hphp/hack/test/typecheck/array_sub2.php.exp +++ b/hphp/hack/test/typecheck/array_sub2.php.exp @@ -11,6 +11,6 @@ Some type arguments violate their constraints (Typing[4323]) File "array_sub2.php", line 21, characters 12-13: Invalid argument (Typing[4110]) File "array_sub2.php", line 12, characters 23-38: - Expected `dict` + Expected `dict` File "array_sub2.php", line 20, characters 15-25: But got `vec` diff --git a/hphp/hack/test/typecheck/assign_unresolved_obj_get.php.tast_typecheck_exp b/hphp/hack/test/typecheck/assign_unresolved_obj_get.php.tast_typecheck_exp index 48e5d52b074..938489b95bf 100644 --- a/hphp/hack/test/typecheck/assign_unresolved_obj_get.php.tast_typecheck_exp +++ b/hphp/hack/test/typecheck/assign_unresolved_obj_get.php.tast_typecheck_exp @@ -47,7 +47,7 @@ (Binop ((Eq None), (([14:3-5], C), (Lvar ([14:3-5], $c))), (([14:8-20], C), (New ( - (([14:12-13], C<[unresolved]>), + (([14:12-13], C<_>), (CI (([14:12-13], "\\C"), []))), [(([14:14-19], (float | num | int)), (Lvar ([14:14-19], $xory)))], diff --git a/hphp/hack/test/typecheck/await_as_an_expression/error/await_as_an_expression_awaiting_non_awaitable.php.exp b/hphp/hack/test/typecheck/await_as_an_expression/error/await_as_an_expression_awaiting_non_awaitable.php.exp index 64d81a5851a..2a1c8593137 100644 --- a/hphp/hack/test/typecheck/await_as_an_expression/error/await_as_an_expression_awaiting_non_awaitable.php.exp +++ b/hphp/hack/test/typecheck/await_as_an_expression/error/await_as_an_expression_awaiting_non_awaitable.php.exp @@ -1,6 +1,6 @@ File "await_as_an_expression_awaiting_non_awaitable.php", line 7, characters 17-22: `await` can only operate on an `Awaitable` (Typing[4110]) -File "await_as_an_expression_awaiting_non_awaitable.php", line 7, characters 17-22: -Expected `Awaitable<[unresolved]>` -File "await_as_an_expression_awaiting_non_awaitable.php", line 3, characters 18-20: -But got `int` + File "await_as_an_expression_awaiting_non_awaitable.php", line 7, characters 17-22: + Expected `Awaitable<_>` + File "await_as_an_expression_awaiting_non_awaitable.php", line 3, characters 18-20: + But got `int` diff --git a/hphp/hack/test/typecheck/await_on_illegal_value.php.exp b/hphp/hack/test/typecheck/await_on_illegal_value.php.exp index ad4eb9812bf..f52db332e6c 100644 --- a/hphp/hack/test/typecheck/await_on_illegal_value.php.exp +++ b/hphp/hack/test/typecheck/await_on_illegal_value.php.exp @@ -9,6 +9,6 @@ Invalid return type (Typing[4336]) File "await_on_illegal_value.php", line 13, characters 3-10: `await` can only operate on an `Awaitable` (Typing[4110]) File "await_on_illegal_value.php", line 13, characters 3-10: - Expected `Awaitable<[unresolved]>` + Expected `Awaitable<_>` File "await_on_illegal_value.php", line 13, characters 9-10: But got `int` diff --git a/hphp/hack/test/typecheck/await_precedence/strong_precedence/await_new_precedence.php.exp b/hphp/hack/test/typecheck/await_precedence/strong_precedence/await_new_precedence.php.exp index 0ef9abd05bc..6dd32815e8f 100644 --- a/hphp/hack/test/typecheck/await_precedence/strong_precedence/await_new_precedence.php.exp +++ b/hphp/hack/test/typecheck/await_precedence/strong_precedence/await_new_precedence.php.exp @@ -1,18 +1,18 @@ File "await_new_precedence.php", line 10, characters 14-15: This expression is of type `Awaitable`, but it's either being discarded or used in a dangerous way before being awaited (Typing[4015]) -File "await_new_precedence.php", line 8, characters 40-54: -This is why I think it is `Awaitable` + File "await_new_precedence.php", line 8, characters 40-54: + This is why I think it is `Awaitable` File "await_new_precedence.php", line 10, characters 19-20: This expression is of type `Awaitable`, but it's either being discarded or used in a dangerous way before being awaited (Typing[4015]) -File "await_new_precedence.php", line 8, characters 60-74: -This is why I think it is `Awaitable` + File "await_new_precedence.php", line 8, characters 60-74: + This is why I think it is `Awaitable` File "await_new_precedence.php", line 20, characters 3-30: This expression is of type `Awaitable`, but it's either being discarded or used in a dangerous way before being awaited (Typing[4015]) -File "await_new_precedence.php", line 17, characters 35-46: -This is why I think it is `Awaitable` + File "await_new_precedence.php", line 17, characters 35-46: + This is why I think it is `Awaitable` File "await_new_precedence.php", line 20, characters 18-19: Invalid argument (Typing[4110]) -File "await_new_precedence.php", line 17, characters 16-27: -Expected `Awaitable<[unresolved]>` -File "await_new_precedence.php", line 19, characters 30-32: -But got `int` + File "await_new_precedence.php", line 17, characters 16-27: + Expected `Awaitable<_>` + File "await_new_precedence.php", line 19, characters 30-32: + But got `int` diff --git a/hphp/hack/test/typecheck/await_precedence/weak_precedence/await_old_precedence.php.exp b/hphp/hack/test/typecheck/await_precedence/weak_precedence/await_old_precedence.php.exp index 3aff4c65c7f..c20a6b0db30 100644 --- a/hphp/hack/test/typecheck/await_precedence/weak_precedence/await_old_precedence.php.exp +++ b/hphp/hack/test/typecheck/await_precedence/weak_precedence/await_old_precedence.php.exp @@ -1,18 +1,18 @@ File "await_old_precedence.php", line 10, characters 14-15: This expression is of type `Awaitable`, but it's either being discarded or used in a dangerous way before being awaited (Typing[4015]) -File "await_old_precedence.php", line 8, characters 40-54: -This is why I think it is `Awaitable` + File "await_old_precedence.php", line 8, characters 40-54: + This is why I think it is `Awaitable` File "await_old_precedence.php", line 10, characters 19-20: This expression is of type `Awaitable`, but it's either being discarded or used in a dangerous way before being awaited (Typing[4015]) -File "await_old_precedence.php", line 8, characters 60-74: -This is why I think it is `Awaitable` + File "await_old_precedence.php", line 8, characters 60-74: + This is why I think it is `Awaitable` File "await_old_precedence.php", line 20, characters 3-30: This expression is of type `Awaitable`, but it's either being discarded or used in a dangerous way before being awaited (Typing[4015]) -File "await_old_precedence.php", line 17, characters 35-46: -This is why I think it is `Awaitable` + File "await_old_precedence.php", line 17, characters 35-46: + This is why I think it is `Awaitable` File "await_old_precedence.php", line 20, characters 18-19: Invalid argument (Typing[4110]) -File "await_old_precedence.php", line 17, characters 16-27: -Expected `Awaitable<[unresolved]>` -File "await_old_precedence.php", line 19, characters 30-32: -But got `int` + File "await_old_precedence.php", line 17, characters 16-27: + Expected `Awaitable<_>` + File "await_old_precedence.php", line 19, characters 30-32: + But got `int` diff --git a/hphp/hack/test/typecheck/concurrent/error/concurrent_non_awaitable.php.exp b/hphp/hack/test/typecheck/concurrent/error/concurrent_non_awaitable.php.exp index de40d4d7c50..40c2e42d03b 100644 --- a/hphp/hack/test/typecheck/concurrent/error/concurrent_non_awaitable.php.exp +++ b/hphp/hack/test/typecheck/concurrent/error/concurrent_non_awaitable.php.exp @@ -1,6 +1,6 @@ File "concurrent_non_awaitable.php", line 8, characters 16-20: `await` can only operate on an `Awaitable` (Typing[4110]) -File "concurrent_non_awaitable.php", line 8, characters 16-20: -Expected `Awaitable<[unresolved]>` -File "concurrent_non_awaitable.php", line 3, characters 17-19: -But got `int` + File "concurrent_non_awaitable.php", line 8, characters 16-20: + Expected `Awaitable<_>` + File "concurrent_non_awaitable.php", line 3, characters 17-19: + But got `int` diff --git a/hphp/hack/test/typecheck/continuation_is_not_awaitable2.php.exp b/hphp/hack/test/typecheck/continuation_is_not_awaitable2.php.exp index 4afe8194f45..53ea84e8e4f 100644 --- a/hphp/hack/test/typecheck/continuation_is_not_awaitable2.php.exp +++ b/hphp/hack/test/typecheck/continuation_is_not_awaitable2.php.exp @@ -3,4 +3,4 @@ Invalid return type (Typing[4110]) File "continuation_is_not_awaitable2.php", line 12, characters 17-30: Expected `Awaitable` File "continuation_is_not_awaitable2.php", line 12, characters 17-30: - But got `Generator<[unresolved], [unresolved], [unresolved]>` (result of function containing a `yield`) + But got `Generator<_, _, _>` (result of function containing a `yield`) diff --git a/hphp/hack/test/typecheck/control_flow/lambda.php.exp b/hphp/hack/test/typecheck/control_flow/lambda.php.exp index 44465f26cb6..bc8c564f89d 100644 --- a/hphp/hack/test/typecheck/control_flow/lambda.php.exp +++ b/hphp/hack/test/typecheck/control_flow/lambda.php.exp @@ -3,25 +3,25 @@ File "lambda.php", line 23, characters 5-15: File "lambda.php", line 24, characters 5-15: exact A File "lambda.php", line 51, characters 11-21: - [unresolved] + _ File "lambda.php", line 71, characters 9-19: - ([unresolved] | exact D | exact G | exact J) + (_ | exact D | exact G | exact J) File "lambda.php", line 23, characters 5-15:[2] (exact A | exact B | exact C) File "lambda.php", line 24, characters 5-15:[2] (exact A | exact B | exact C) File "lambda.php", line 51, characters 11-21:[2] - [unresolved] + _ File "lambda.php", line 71, characters 9-19:[2] - ([unresolved] | exact D | exact G | exact J) + (_ | exact D | exact G | exact J) File "lambda.php", line 23, characters 5-15:[3] (exact A | exact B | exact C) File "lambda.php", line 24, characters 5-15:[3] (exact A | exact B | exact C) File "lambda.php", line 51, characters 11-21:[3] - [unresolved] + _ File "lambda.php", line 71, characters 9-19:[3] - ([unresolved] | exact D | exact G | exact J) + (_ | exact D | exact G | exact J) File "lambda.php", line 86, characters 3-13: (exact A | exact B | exact C | exact E) File "lambda.php", line 87, characters 3-13: diff --git a/hphp/hack/test/typecheck/dynamic/collections.php.exp b/hphp/hack/test/typecheck/dynamic/collections.php.exp index 344ea028b55..aa26f4a6fbc 100644 --- a/hphp/hack/test/typecheck/dynamic/collections.php.exp +++ b/hphp/hack/test/typecheck/dynamic/collections.php.exp @@ -1,7 +1,7 @@ File "collections.php", line 8, characters 3-13: vec<(dynamic | int)> File "collections.php", line 10, characters 3-13: - Vector<[unresolved]> + Vector<_> File "collections.php", line 12, characters 3-13: - Map<[unresolved], [unresolved]> + Map<_, _> No errors diff --git a/hphp/hack/test/typecheck/dynamic/foreach_union.php.exp b/hphp/hack/test/typecheck/dynamic/foreach_union.php.exp dissimilarity index 66% index 5256b7d0aec..b15e76baaee 100644 --- a/hphp/hack/test/typecheck/dynamic/foreach_union.php.exp +++ b/hphp/hack/test/typecheck/dynamic/foreach_union.php.exp @@ -1,12 +1,12 @@ -File "foreach_union.php", line 12, characters 20-21: -Invalid argument (Typing[4110]) -File "foreach_union.php", line 5, characters 25-32: -Expected `vec` -File "foreach_union.php", line 7, characters 20-26: -But got `dynamic` -File "foreach_union.php", line 20, characters 12-13: -Invalid `foreach` (Typing[4110]) -File "foreach_union.php", line 20, characters 12-13: -Expected `Traversable<[unresolved]>` because this is used in a `foreach` statement -File "foreach_union.php", line 16, characters 33-33: -But got `C` +File "foreach_union.php", line 12, characters 20-21: +Invalid argument (Typing[4110]) + File "foreach_union.php", line 5, characters 25-32: + Expected `vec` + File "foreach_union.php", line 7, characters 20-26: + But got `dynamic` +File "foreach_union.php", line 20, characters 12-13: +Invalid `foreach` (Typing[4110]) + File "foreach_union.php", line 20, characters 12-13: + Expected `Traversable<_>` because this is used in a `foreach` statement + File "foreach_union.php", line 16, characters 33-33: + But got `C` diff --git a/hphp/hack/test/typecheck/enum_class_label/xcont.php.pess_exp b/hphp/hack/test/typecheck/enum_class_label/xcont.php.pess_exp index 52745f54cd8..92f73e48316 100644 --- a/hphp/hack/test/typecheck/enum_class_label/xcont.php.pess_exp +++ b/hphp/hack/test/typecheck/enum_class_label/xcont.php.pess_exp @@ -1,6 +1,6 @@ File "xcont.php.pess", line 70, characters 26-31: Invalid argument (Typing[4110]) File "BuiltinEnum.hhi", line 123, characters 109-142: - Expected `~HH\EnumClass\Label<[unresolved], [unresolved]>` + Expected `~HH\EnumClass\Label<_, _>` File "xcont.php.pess", line 67, characters 104-139: But got `HH\EnumClass\Label` diff --git a/hphp/hack/test/typecheck/erling_loop2.php.exp b/hphp/hack/test/typecheck/erling_loop2.php.exp index 3df2a28d3dc..7954e780351 100644 --- a/hphp/hack/test/typecheck/erling_loop2.php.exp +++ b/hphp/hack/test/typecheck/erling_loop2.php.exp @@ -3,4 +3,4 @@ Invalid return type (Typing[4110]) File "erling_loop2.php", line 16, characters 18-20: Expected `int` File "erling_loop2.php", line 18, characters 3-13: - But got `([unresolved] & (int | string))` + But got `(_ & (int | string))` diff --git a/hphp/hack/test/typecheck/explicit_type_collection/explicit_type_collection_wildcard_map1.php.exp b/hphp/hack/test/typecheck/explicit_type_collection/explicit_type_collection_wildcard_map1.php.exp index b2ba8c5d561..a17f28c6bf1 100644 --- a/hphp/hack/test/typecheck/explicit_type_collection/explicit_type_collection_wildcard_map1.php.exp +++ b/hphp/hack/test/typecheck/explicit_type_collection/explicit_type_collection_wildcard_map1.php.exp @@ -1,3 +1,3 @@ File "explicit_type_collection_wildcard_map1.php", line 6, characters 3-13: - Map<[unresolved], bool> + Map<_, bool> No errors diff --git a/hphp/hack/test/typecheck/explicit_type_collection/explicit_type_collection_wildcard_map2.php.exp b/hphp/hack/test/typecheck/explicit_type_collection/explicit_type_collection_wildcard_map2.php.exp index b9cd27f1536..884a31a58ef 100644 --- a/hphp/hack/test/typecheck/explicit_type_collection/explicit_type_collection_wildcard_map2.php.exp +++ b/hphp/hack/test/typecheck/explicit_type_collection/explicit_type_collection_wildcard_map2.php.exp @@ -1,3 +1,3 @@ File "explicit_type_collection_wildcard_map2.php", line 6, characters 3-13: - Map + Map No errors diff --git a/hphp/hack/test/typecheck/explicit_type_collection/explicit_type_collection_wildcard_map3.php.exp b/hphp/hack/test/typecheck/explicit_type_collection/explicit_type_collection_wildcard_map3.php.exp index 9f7b866d1ae..624cce32821 100644 --- a/hphp/hack/test/typecheck/explicit_type_collection/explicit_type_collection_wildcard_map3.php.exp +++ b/hphp/hack/test/typecheck/explicit_type_collection/explicit_type_collection_wildcard_map3.php.exp @@ -1,3 +1,3 @@ File "explicit_type_collection_wildcard_map3.php", line 6, characters 3-13: - Map<[unresolved], [unresolved]> + Map<_, _> No errors diff --git a/hphp/hack/test/typecheck/expression_trees/dict_error.php.exp b/hphp/hack/test/typecheck/expression_trees/dict_error.php.exp index fb2b83e6bd5..b8be36e3ef7 100644 --- a/hphp/hack/test/typecheck/expression_trees/dict_error.php.exp +++ b/hphp/hack/test/typecheck/expression_trees/dict_error.php.exp @@ -7,12 +7,12 @@ The values of this `dict` are incompatible (Typing[4110]) File "dict_error.php", line 61, characters 10-14: Typing error (Typing[4110]) File "dict_error.php", line 61, characters 10-14: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "dict_error.php", line 58, characters 15-24: But got `ExampleInt` File "dict_error.php", line 61, characters 12-13: Invalid argument (Typing[4110]) File "dict_error.php", line 52, characters 5-45: - Expected `Spliceable` + Expected `Spliceable` File "dict_error.php", line 58, characters 15-24: But got `ExampleInt` diff --git a/hphp/hack/test/typecheck/expression_trees/nested_splicing.php.exp b/hphp/hack/test/typecheck/expression_trees/nested_splicing.php.exp index 4f6d45ef479..3699bb45b7a 100644 --- a/hphp/hack/test/typecheck/expression_trees/nested_splicing.php.exp +++ b/hphp/hack/test/typecheck/expression_trees/nested_splicing.php.exp @@ -3,6 +3,6 @@ Splice syntax `${...}` cannot be nested. (Parsing[1002]) File "nested_splicing.php", line 6, characters 16-19: Typing error (Typing[4110]) File "nested_splicing.php", line 6, characters 16-19: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "nested_splicing.php", line 6, characters 18-18: But got `int` diff --git a/hphp/hack/test/typecheck/expression_trees/nested_splicing2.php.exp b/hphp/hack/test/typecheck/expression_trees/nested_splicing2.php.exp index 14e07b45332..a939777a9b5 100644 --- a/hphp/hack/test/typecheck/expression_trees/nested_splicing2.php.exp +++ b/hphp/hack/test/typecheck/expression_trees/nested_splicing2.php.exp @@ -3,6 +3,6 @@ Splice syntax `${...}` cannot be nested. (Parsing[1002]) File "nested_splicing2.php", line 6, characters 20-23: Typing error (Typing[4110]) File "nested_splicing2.php", line 6, characters 20-23: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "nested_splicing2.php", line 6, characters 22-22: But got `int` diff --git a/hphp/hack/test/typecheck/expression_trees/pipe2.php.exp b/hphp/hack/test/typecheck/expression_trees/pipe2.php.exp index eb0d8f6bdaf..8ba0a51d038 100644 --- a/hphp/hack/test/typecheck/expression_trees/pipe2.php.exp +++ b/hphp/hack/test/typecheck/expression_trees/pipe2.php.exp @@ -5,12 +5,12 @@ Wrong number of type arguments (expected 0, got 3) (Typing[4101]) File "pipe2.php", line 21, characters 30-52: Typing error (Typing[4110]) File "pipe2.php", line 21, characters 30-52: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "pipe2.php", line 9, characters 70-124: But got `ExampleDsl` File "pipe2.php", line 21, characters 33-50: Invalid argument (Typing[4110]) File "expr_tree.hhi", line 200, characters 5-47: - Expected `Spliceable` + Expected `Spliceable` File "pipe2.php", line 9, characters 70-124: But got `ExampleDsl` diff --git a/hphp/hack/test/typecheck/expression_trees/pipe5.php.exp b/hphp/hack/test/typecheck/expression_trees/pipe5.php.exp index c54fb7ebf37..594bf6bc6e3 100644 --- a/hphp/hack/test/typecheck/expression_trees/pipe5.php.exp +++ b/hphp/hack/test/typecheck/expression_trees/pipe5.php.exp @@ -5,12 +5,12 @@ Wrong number of type arguments (expected 0, got 3) (Typing[4101]) File "pipe5.php", line 17, characters 19-41: Typing error (Typing[4110]) File "pipe5.php", line 17, characters 19-41: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "pipe5.php", line 9, characters 70-124: But got `ExampleDsl` File "pipe5.php", line 17, characters 22-39: Invalid argument (Typing[4110]) File "expr_tree.hhi", line 200, characters 5-47: - Expected `Spliceable` + Expected `Spliceable` File "pipe5.php", line 9, characters 70-124: But got `ExampleDsl` diff --git a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/splice_err1.php.exp b/hphp/hack/test/typecheck/expression_trees/splice_err1.php.exp similarity index 68% copy from hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/splice_err1.php.exp copy to hphp/hack/test/typecheck/expression_trees/splice_err1.php.exp index c4ce8a20f09..7d6acc912fc 100644 --- a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/splice_err1.php.exp +++ b/hphp/hack/test/typecheck/expression_trees/splice_err1.php.exp @@ -1,12 +1,12 @@ File "splice_err1.php", line 9, characters 19-23: Typing error (Typing[4110]) File "splice_err1.php", line 9, characters 19-23: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "splice_err1.php", line 6, characters 8-8: But got `int` File "splice_err1.php", line 9, characters 21-22: Invalid argument (Typing[4110]) File "expr_tree.hhi", line 200, characters 5-47: - Expected `Spliceable` + Expected `Spliceable` File "splice_err1.php", line 6, characters 8-8: But got `int` diff --git a/hphp/hack/test/typecheck/expression_trees/splice_err4.php.exp b/hphp/hack/test/typecheck/expression_trees/splice_err4.php.exp index 5b97802f04f..e691a13a9c6 100644 --- a/hphp/hack/test/typecheck/expression_trees/splice_err4.php.exp +++ b/hphp/hack/test/typecheck/expression_trees/splice_err4.php.exp @@ -1,12 +1,12 @@ File "splice_err4.php", line 13, characters 23-27: Typing error (Typing[4110]) File "splice_err4.php", line 13, characters 23-27: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "splice_err4.php", line 9, characters 10-10: But got `int` File "splice_err4.php", line 13, characters 25-26: Invalid argument (Typing[4110]) File "expr_tree.hhi", line 200, characters 5-47: - Expected `Spliceable` + Expected `Spliceable` File "splice_err4.php", line 9, characters 10-10: But got `int` diff --git a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/dict_error.php.exp b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/dict_error.php.exp index 65a75244300..69f37f7cd6a 100644 --- a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/dict_error.php.exp +++ b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/dict_error.php.exp @@ -7,12 +7,12 @@ The values of this `dict` are incompatible (Typing[4110]) File "dict_error.php", line 57, characters 10-14: Typing error (Typing[4110]) File "dict_error.php", line 57, characters 10-14: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "dict_error.php", line 54, characters 15-24: But got `ExampleInt` File "dict_error.php", line 57, characters 12-13: Invalid argument (Typing[4110]) File "dict_error.php", line 48, characters 5-45: - Expected `Spliceable` + Expected `Spliceable` File "dict_error.php", line 54, characters 15-24: But got `ExampleInt` diff --git a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/nested_splicing.php.exp b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/nested_splicing.php.exp index 4f6d45ef479..3699bb45b7a 100644 --- a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/nested_splicing.php.exp +++ b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/nested_splicing.php.exp @@ -3,6 +3,6 @@ Splice syntax `${...}` cannot be nested. (Parsing[1002]) File "nested_splicing.php", line 6, characters 16-19: Typing error (Typing[4110]) File "nested_splicing.php", line 6, characters 16-19: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "nested_splicing.php", line 6, characters 18-18: But got `int` diff --git a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/nested_splicing2.php.exp b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/nested_splicing2.php.exp index 14e07b45332..a939777a9b5 100644 --- a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/nested_splicing2.php.exp +++ b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/nested_splicing2.php.exp @@ -3,6 +3,6 @@ Splice syntax `${...}` cannot be nested. (Parsing[1002]) File "nested_splicing2.php", line 6, characters 20-23: Typing error (Typing[4110]) File "nested_splicing2.php", line 6, characters 20-23: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "nested_splicing2.php", line 6, characters 22-22: But got `int` diff --git a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/pipe2.php.exp b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/pipe2.php.exp index eb0d8f6bdaf..8ba0a51d038 100644 --- a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/pipe2.php.exp +++ b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/pipe2.php.exp @@ -5,12 +5,12 @@ Wrong number of type arguments (expected 0, got 3) (Typing[4101]) File "pipe2.php", line 21, characters 30-52: Typing error (Typing[4110]) File "pipe2.php", line 21, characters 30-52: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "pipe2.php", line 9, characters 70-124: But got `ExampleDsl` File "pipe2.php", line 21, characters 33-50: Invalid argument (Typing[4110]) File "expr_tree.hhi", line 200, characters 5-47: - Expected `Spliceable` + Expected `Spliceable` File "pipe2.php", line 9, characters 70-124: But got `ExampleDsl` diff --git a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/pipe5.php.exp b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/pipe5.php.exp index c54fb7ebf37..594bf6bc6e3 100644 --- a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/pipe5.php.exp +++ b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/pipe5.php.exp @@ -5,12 +5,12 @@ Wrong number of type arguments (expected 0, got 3) (Typing[4101]) File "pipe5.php", line 17, characters 19-41: Typing error (Typing[4110]) File "pipe5.php", line 17, characters 19-41: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "pipe5.php", line 9, characters 70-124: But got `ExampleDsl` File "pipe5.php", line 17, characters 22-39: Invalid argument (Typing[4110]) File "expr_tree.hhi", line 200, characters 5-47: - Expected `Spliceable` + Expected `Spliceable` File "pipe5.php", line 9, characters 70-124: But got `ExampleDsl` diff --git a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/splice_err1.php.exp b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/splice_err1.php.exp index c4ce8a20f09..7d6acc912fc 100644 --- a/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/splice_err1.php.exp +++ b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/splice_err1.php.exp @@ -1,12 +1,12 @@ File "splice_err1.php", line 9, characters 19-23: Typing error (Typing[4110]) File "splice_err1.php", line 9, characters 19-23: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "splice_err1.php", line 6, characters 8-8: But got `int` File "splice_err1.php", line 9, characters 21-22: Invalid argument (Typing[4110]) File "expr_tree.hhi", line 200, characters 5-47: - Expected `Spliceable` + Expected `Spliceable` File "splice_err1.php", line 6, characters 8-8: But got `int` diff --git a/hphp/hack/test/typecheck/expression_trees/splice_err4.php.exp b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/splice_err4.php.exp similarity index 68% copy from hphp/hack/test/typecheck/expression_trees/splice_err4.php.exp copy to hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/splice_err4.php.exp index 5b97802f04f..e691a13a9c6 100644 --- a/hphp/hack/test/typecheck/expression_trees/splice_err4.php.exp +++ b/hphp/hack/test/typecheck/expression_trees_not_virtualize_functions/splice_err4.php.exp @@ -1,12 +1,12 @@ File "splice_err4.php", line 13, characters 23-27: Typing error (Typing[4110]) File "splice_err4.php", line 13, characters 23-27: - Expected `Spliceable<[unresolved], [unresolved], [unresolved]>` because this is being spliced into another Expression Tree + Expected `Spliceable<_, _, _>` because this is being spliced into another Expression Tree File "splice_err4.php", line 9, characters 10-10: But got `int` File "splice_err4.php", line 13, characters 25-26: Invalid argument (Typing[4110]) File "expr_tree.hhi", line 200, characters 5-47: - Expected `Spliceable` + Expected `Spliceable` File "splice_err4.php", line 9, characters 10-10: But got `int` diff --git a/hphp/hack/test/typecheck/ffp/function_async_lambda_bad.php.exp b/hphp/hack/test/typecheck/ffp/function_async_lambda_bad.php.exp index 1ef67b0a896..1780fe5a2d9 100644 --- a/hphp/hack/test/typecheck/ffp/function_async_lambda_bad.php.exp +++ b/hphp/hack/test/typecheck/ffp/function_async_lambda_bad.php.exp @@ -7,10 +7,10 @@ Invalid return type (Typing[4110]) File "function_async_lambda_bad.php", line 6, characters 18-20: Expected `int` File "function_async_lambda_bad.php", line 6, characters 18-20: - But got `Awaitable<[unresolved]>` (result of an `async` function) + But got `Awaitable<_>` (result of an `async` function) File "function_async_lambda_bad.php", line 10, characters 26-28: Invalid return type (Typing[4110]) File "function_async_lambda_bad.php", line 10, characters 26-28: Expected `int` File "function_async_lambda_bad.php", line 10, characters 26-28: - But got `Awaitable<[unresolved]>` (result of an `async` function) + But got `Awaitable<_>` (result of an `async` function) diff --git a/hphp/hack/test/typecheck/ffp/throw_yield.php.exp b/hphp/hack/test/typecheck/ffp/throw_yield.php.exp index 5bfae34cc2d..41d759dbb93 100644 --- a/hphp/hack/test/typecheck/ffp/throw_yield.php.exp +++ b/hphp/hack/test/typecheck/ffp/throw_yield.php.exp @@ -5,10 +5,10 @@ Invalid return type (Typing[4110]) File "throw_yield.php", line 4, characters 17-20: Expected `void` File "throw_yield.php", line 4, characters 17-20: - But got `Generator<[unresolved], [unresolved], [unresolved]>` (result of function containing a `yield`) + But got `Generator<_, _, _>` (result of function containing a `yield`) File "throw_yield.php", line 5, characters 9-15: Invalid exception (Typing[4110]) File "throw_yield.php", line 5, characters 9-15: Expected `Throwable` because it is used as an exception File "throw_yield.php", line 5, characters 9-15: - But got `?[unresolved]` (`$generator->send()` can always send a `null` back to a `yield`) + But got `?_` (`$generator->send()` can always send a `null` back to a `yield`) diff --git a/hphp/hack/test/typecheck/ffp/yield_bad1.php.exp b/hphp/hack/test/typecheck/ffp/yield_bad1.php.exp index c889b995382..43566d28478 100644 --- a/hphp/hack/test/typecheck/ffp/yield_bad1.php.exp +++ b/hphp/hack/test/typecheck/ffp/yield_bad1.php.exp @@ -7,6 +7,6 @@ Invalid return type (Typing[4110]) File "yield_bad1.php", line 4, characters 18-21: Expected `void` File "yield_bad1.php", line 4, characters 18-21: - But got `Generator<[unresolved], [unresolved], [unresolved]>` (result of function containing a `yield`) + But got `Generator<_, _, _>` (result of function containing a `yield`) File "yield_bad1.php", line 5, characters 3-5: Unbound name (typing): `foo` (Typing[4107]) diff --git a/hphp/hack/test/typecheck/ffp/yield_bad2.php.exp b/hphp/hack/test/typecheck/ffp/yield_bad2.php.exp index de297efa481..11b6af40db8 100644 --- a/hphp/hack/test/typecheck/ffp/yield_bad2.php.exp +++ b/hphp/hack/test/typecheck/ffp/yield_bad2.php.exp @@ -7,4 +7,4 @@ Invalid return type (Typing[4110]) File "yield_bad2.php", line 4, characters 18-21: Expected `void` File "yield_bad2.php", line 4, characters 18-21: - But got `Generator<[unresolved], [unresolved], [unresolved]>` (result of function containing a `yield`) + But got `Generator<_, _, _>` (result of function containing a `yield`) diff --git a/hphp/hack/test/typecheck/functional_generator.php.exp b/hphp/hack/test/typecheck/functional_generator.php.exp index 9c307a3671c..dd6f5b23a64 100644 --- a/hphp/hack/test/typecheck/functional_generator.php.exp +++ b/hphp/hack/test/typecheck/functional_generator.php.exp @@ -3,4 +3,4 @@ Invalid return type (Typing[4110]) File "functional_generator.php", line 27, characters 20-30: Expected `Stream` File "functional_generator.php", line 27, characters 20-30: - But got `Generator<[unresolved], [unresolved], [unresolved]>` (result of function containing a `yield`) + But got `Generator<_, _, _>` (result of function containing a `yield`) diff --git a/hphp/hack/test/typecheck/gen6.php.exp b/hphp/hack/test/typecheck/gen6.php.exp index b9a629f0346..6953c4acbb4 100644 --- a/hphp/hack/test/typecheck/gen6.php.exp +++ b/hphp/hack/test/typecheck/gen6.php.exp @@ -11,6 +11,6 @@ Invalid argument (Typing[4323]) File "gen6.php", line 12, characters 14-17: This type constraint is violated File "gen6.php", line 12, characters 14-17: - Expected `A<[unresolved]>` + Expected `A<_>` File "gen6.php", line 26, characters 15-15: But got `Z` diff --git a/hphp/hack/test/typecheck/hh_fixme_bug3.php.pess_exp b/hphp/hack/test/typecheck/hh_fixme_bug3.php.pess_exp index 59d620e8ef4..deefe857c92 100644 --- a/hphp/hack/test/typecheck/hh_fixme_bug3.php.pess_exp +++ b/hphp/hack/test/typecheck/hh_fixme_bug3.php.pess_exp @@ -1,7 +1,7 @@ File "hh_fixme_bug3.php.pess", line 19, characters 15-16: Invalid argument (Typing[4110]) File "hh_fixme_bug3.php.pess", line 10, characters 3-8: - Expected `~C<[unresolved]>` + Expected `~C<_>` File "hh_fixme_bug3.php.pess", line 17, characters 17-28: But got ` as C` File "hh_fixme_bug3.php.pess", line 19, characters 15-16: diff --git a/hphp/hack/test/typecheck/hhfixme_bug2.php.pess_exp b/hphp/hack/test/typecheck/hhfixme_bug2.php.pess_exp index 44a28f11720..f27455b7cbe 100644 --- a/hphp/hack/test/typecheck/hhfixme_bug2.php.pess_exp +++ b/hphp/hack/test/typecheck/hhfixme_bug2.php.pess_exp @@ -1,6 +1,6 @@ File "hhfixme_bug2.php.pess", line 12, characters 39-44: Invalid argument (Typing[4110]) File "hhfixme_bug2.php.pess", line 8, characters 55-56: - Expected `~[unresolved]` + Expected `~_` File "hhfixme_bug2.php.pess", line 10, characters 37-40: But got `null` diff --git a/hphp/hack/test/typecheck/hhfixme_bug2.php.tgt_pess_exp b/hphp/hack/test/typecheck/hhfixme_bug2.php.tgt_pess_exp index 934b3f0115d..160b4b28c32 100644 --- a/hphp/hack/test/typecheck/hhfixme_bug2.php.tgt_pess_exp +++ b/hphp/hack/test/typecheck/hhfixme_bug2.php.tgt_pess_exp @@ -1,6 +1,6 @@ File "hhfixme_bug2.php.pess", line 12, characters 39-44: Invalid argument (Typing[4110]) File "hhfixme_bug2.php.pess", line 8, characters 55-56: - Expected `~[unresolved]` + Expected `~_` File "hhfixme_bug2.php.pess", line 10, characters 35-38: But got `null` diff --git a/hphp/hack/test/typecheck/idx2_4.php.exp b/hphp/hack/test/typecheck/idx2_4.php.exp index 0140b5da63c..3264303ee04 100644 --- a/hphp/hack/test/typecheck/idx2_4.php.exp +++ b/hphp/hack/test/typecheck/idx2_4.php.exp @@ -1,6 +1,6 @@ File "idx2_4.php", line 9, characters 12-12: Invalid argument (Typing[4110]) File "idx.hhi", line 31, characters 4-25: - Expected `KeyedContainer<[unresolved], [unresolved]>` + Expected `KeyedContainer<_, _>` File "idx2_4.php", line 9, characters 12-12: But got `int` diff --git a/hphp/hack/test/typecheck/idx3_5.php.exp b/hphp/hack/test/typecheck/idx3_5.php.exp index 2b3c2cf3459..e9578998f39 100644 --- a/hphp/hack/test/typecheck/idx3_5.php.exp +++ b/hphp/hack/test/typecheck/idx3_5.php.exp @@ -1,6 +1,6 @@ File "idx3_5.php", line 9, characters 12-12: Invalid argument (Typing[4110]) File "idx.hhi", line 31, characters 4-25: - Expected `KeyedContainer<[unresolved], [unresolved]>` + Expected `KeyedContainer<_, _>` File "idx3_5.php", line 9, characters 12-12: But got `int` diff --git a/hphp/hack/test/typecheck/invalid_arraykey/invalid_arraykey.php.exp b/hphp/hack/test/typecheck/invalid_arraykey/invalid_arraykey.php.exp index 508b4537014..096b310ff91 100644 --- a/hphp/hack/test/typecheck/invalid_arraykey/invalid_arraykey.php.exp +++ b/hphp/hack/test/typecheck/invalid_arraykey/invalid_arraykey.php.exp @@ -37,9 +37,9 @@ Invalid index type for this Map (Typing[4324]) File "invalid_arraykey.php", line 16, characters 3-14: This value is not a valid key type for this container (Typing[4371]) File "invalid_arraykey.php", line 14, characters 8-12: - This container is an object of type Map<[unresolved], [unresolved]> + This container is an object of type Map<_, _> File "invalid_arraykey.php", line 16, characters 6-9: - Null cannot be used as a key for an object of type Map<[unresolved], [unresolved]> + Null cannot be used as a key for an object of type Map<_, _> File "invalid_arraykey.php", line 17, characters 3-13: Invalid index type for this Map (Typing[4324]) File "invalid_arraykey.php", line 14, characters 8-12: @@ -49,9 +49,9 @@ Invalid index type for this Map (Typing[4324]) File "invalid_arraykey.php", line 17, characters 3-13: This value is not a valid key type for this container (Typing[4371]) File "invalid_arraykey.php", line 14, characters 8-12: - This container is an object of type Map<[unresolved], [unresolved]> + This container is an object of type Map<_, _> File "invalid_arraykey.php", line 17, characters 6-8: - A float cannot be used as a key for an object of type Map<[unresolved], [unresolved]> + A float cannot be used as a key for an object of type Map<_, _> File "invalid_arraykey.php", line 21, characters 3-14: Invalid index type for this Vector (Typing[4324]) File "invalid_arraykey.php", line 21, characters 6-9: diff --git a/hphp/hack/test/typecheck/keys.php.exp b/hphp/hack/test/typecheck/keys.php.exp index 5a0c9bf769a..21c18b86b85 100644 --- a/hphp/hack/test/typecheck/keys.php.exp +++ b/hphp/hack/test/typecheck/keys.php.exp @@ -1,6 +1,6 @@ File "keys.php", line 9, characters 26-27: Invalid argument (Typing[4110]) File "keys.php", line 12, characters 37-54: - Expected `dict` + Expected `dict` File "keys.php", line 8, characters 8-19: But got `vec` diff --git a/hphp/hack/test/typecheck/lambda/async_lambda2.php.exp b/hphp/hack/test/typecheck/lambda/async_lambda2.php.exp index c802b3c78f5..51c3ab427b0 100644 --- a/hphp/hack/test/typecheck/lambda/async_lambda2.php.exp +++ b/hphp/hack/test/typecheck/lambda/async_lambda2.php.exp @@ -3,7 +3,7 @@ Invalid return type (Typing[4110]) File "async_lambda2.php", line 12, characters 31-33: Expected `int` File "async_lambda2.php", line 13, characters 10-24: - But got `Awaitable<[unresolved]>` (result of an `async` function) + But got `Awaitable<_>` (result of an `async` function) File "async_lambda2.php", line 13, characters 10-24: Invalid return type (Typing[4110]) File "async_lambda2.php", line 12, characters 31-33: diff --git a/hphp/hack/test/typecheck/lambda/variadics/lambda_unpacked_parameters.php.exp b/hphp/hack/test/typecheck/lambda/variadics/lambda_unpacked_parameters.php.exp index 0350f31d3d9..1f0c2589113 100644 --- a/hphp/hack/test/typecheck/lambda/variadics/lambda_unpacked_parameters.php.exp +++ b/hphp/hack/test/typecheck/lambda/variadics/lambda_unpacked_parameters.php.exp @@ -1,7 +1,7 @@ File "lambda_unpacked_parameters.php", line 11, characters 14-24: Invalid argument (Typing[4110]) File "lambda_unpacked_parameters.php", line 11, characters 14-24: - Expected `Traversable<[unresolved]>` (it is unpacked with `...`) + Expected `Traversable<_>` (it is unpacked with `...`) File "lambda_unpacked_parameters.php", line 9, characters 17-17: But got `int` File "lambda_unpacked_parameters.php", line 15, characters 14-14: diff --git a/hphp/hack/test/typecheck/list_generic_assign.php.exp b/hphp/hack/test/typecheck/list_generic_assign.php.exp index cf9eed2d0aa..51669d2c771 100644 --- a/hphp/hack/test/typecheck/list_generic_assign.php.exp +++ b/hphp/hack/test/typecheck/list_generic_assign.php.exp @@ -1,6 +1,6 @@ File "list_generic_assign.php", line 5, characters 3-19: Invalid assignment (Typing[4110]) -File "list_generic_assign.php", line 5, characters 3-14: -Expected `list([unresolved], [unresolved])` resulting from a list destructuring assignment or a splat -File "list_generic_assign.php", line 4, characters 18-18: -But got `T` + File "list_generic_assign.php", line 5, characters 3-14: + Expected `list(_, _)` resulting from a list destructuring assignment or a splat + File "list_generic_assign.php", line 4, characters 18-18: + But got `T` diff --git a/hphp/hack/test/typecheck/method_call_inference/expect_awaitable_in_await.php.exp b/hphp/hack/test/typecheck/method_call_inference/expect_awaitable_in_await.php.exp index 56040f13036..c47ad914c04 100644 --- a/hphp/hack/test/typecheck/method_call_inference/expect_awaitable_in_await.php.exp +++ b/hphp/hack/test/typecheck/method_call_inference/expect_awaitable_in_await.php.exp @@ -1,6 +1,6 @@ File "expect_awaitable_in_await.php", line 25, characters 24-25: Invalid argument (Typing[4110]) File "expect_awaitable_in_await.php", line 24, characters 41-59: - Expected `Awaitable<[unresolved]>` + Expected `Awaitable<_>` File "expect_awaitable_in_await.php", line 10, characters 27-30: But got `bool` diff --git a/hphp/hack/test/typecheck/namespace_collections3.php.exp b/hphp/hack/test/typecheck/namespace_collections3.php.exp index 987e44552da..973eb8095fe 100644 --- a/hphp/hack/test/typecheck/namespace_collections3.php.exp +++ b/hphp/hack/test/typecheck/namespace_collections3.php.exp @@ -2,7 +2,7 @@ File "namespace_collections3.php", line 14, characters 15-18: Unbound name: `Map` (Naming[2049]) File "namespace_collections3.php", line 16, characters 10-11: Invalid return type (Typing[4110]) -File "namespace_collections3.php", line 14, characters 15-28: -Expected `Map` -File "namespace_collections3.php", line 15, characters 8-13: -But got `Map<[unresolved], [unresolved]>` + File "namespace_collections3.php", line 14, characters 15-28: + Expected `Map` + File "namespace_collections3.php", line 15, characters 8-13: + But got `Map<_, _>` diff --git a/hphp/hack/test/typecheck/new_inference/async_lambda.php.exp b/hphp/hack/test/typecheck/new_inference/async_lambda.php.exp index f3922e753ac..6761ce9ce70 100644 --- a/hphp/hack/test/typecheck/new_inference/async_lambda.php.exp +++ b/hphp/hack/test/typecheck/new_inference/async_lambda.php.exp @@ -17,4 +17,4 @@ Invalid return type (Typing[4323]) File "collections/Set.hhi", line 195, characters 29-36: Expected `arraykey` File "async_lambda.php", line 6, characters 11-25: - But got `Awaitable<[unresolved]>` (result of an `async` function) + But got `Awaitable<_>` (result of an `async` function) diff --git a/hphp/hack/test/typecheck/new_inference/eager_solve/array_append_bad.php.exp b/hphp/hack/test/typecheck/new_inference/eager_solve/array_append_bad.php.exp index a1b4d5250ba..2a153bf5d5f 100644 --- a/hphp/hack/test/typecheck/new_inference/eager_solve/array_append_bad.php.exp +++ b/hphp/hack/test/typecheck/new_inference/eager_solve/array_append_bad.php.exp @@ -23,7 +23,7 @@ Set values must be arraykeys (Typing[4324]) File "array_append_bad.php", line 39, characters 12-15: A bool is not an arraykey File "array_append_bad.php", line 41, characters 3-21: -an object of type Map<[unresolved], [unresolved]> does not allow array append (Typing[4006]) +an object of type Map<_, _> does not allow array append (Typing[4006]) File "array_append_bad.php", line 27, characters 3-14: Definition is here File "array_append_bad.php", line 42, characters 3-21: diff --git a/hphp/hack/test/typecheck/new_inference/eager_solve/function_apply_hard.php.tast_typecheck_exp b/hphp/hack/test/typecheck/new_inference/eager_solve/function_apply_hard.php.tast_typecheck_exp index afef3365a9e..4fccefa86b1 100644 --- a/hphp/hack/test/typecheck/new_inference/eager_solve/function_apply_hard.php.tast_typecheck_exp +++ b/hphp/hack/test/typecheck/new_inference/eager_solve/function_apply_hard.php.tast_typecheck_exp @@ -108,7 +108,7 @@ (Lvar ([10:3-7], $obj))), (([10:10-21], Inv<(function(string): arraykey)>), (New ( - (([10:14-17], Inv<[unresolved]>), + (([10:14-17], Inv<_>), (CI ([10:14-17], "\\Inv"))), [], [(([10:18-20], (function(string): int)), diff --git a/hphp/hack/test/typecheck/new_inference/eager_solve/nullable_array_append_hard.php.tast_typecheck_exp b/hphp/hack/test/typecheck/new_inference/eager_solve/nullable_array_append_hard.php.tast_typecheck_exp index f167f2e5e83..cfa328e502e 100644 --- a/hphp/hack/test/typecheck/new_inference/eager_solve/nullable_array_append_hard.php.tast_typecheck_exp +++ b/hphp/hack/test/typecheck/new_inference/eager_solve/nullable_array_append_hard.php.tast_typecheck_exp @@ -92,7 +92,7 @@ (([8:3-7], Inv>), (Lvar ([8:3-7], $obj))), (([8:10-21], Inv>), (New ( - (([8:14-17], Inv<[unresolved]>), + (([8:14-17], Inv<_>), (CI ([8:14-17], "\\Inv"))), [], [(([8:18-20], ?vec), (Lvar ([8:18-20], $v)))], diff --git a/hphp/hack/test/typecheck/new_inference/instance_of_refinement.php.exp b/hphp/hack/test/typecheck/new_inference/instance_of_refinement.php.exp index bc6bd70f5ed..6178f42f8dd 100644 --- a/hphp/hack/test/typecheck/new_inference/instance_of_refinement.php.exp +++ b/hphp/hack/test/typecheck/new_inference/instance_of_refinement.php.exp @@ -31,7 +31,7 @@ Invalid argument (Typing[4110]) File "instance_of_refinement.php", line 17, characters 21-23: Expected `int` File "instance_of_refinement.php", line 50, characters 13-16: - But got `([unresolved] & T#1)` from this `is` expression test + But got `(_ & T#1)` from this `is` expression test File "instance_of_refinement.php", line 52, characters 16-24: Invalid argument (Typing[4110]) File "instance_of_refinement.php", line 17, characters 21-23: diff --git a/hphp/hack/test/typecheck/new_inference/oldtypehole/t21684610.php.exp b/hphp/hack/test/typecheck/new_inference/oldtypehole/t21684610.php.exp index 3db3c1533f1..e4be437cc33 100644 --- a/hphp/hack/test/typecheck/new_inference/oldtypehole/t21684610.php.exp +++ b/hphp/hack/test/typecheck/new_inference/oldtypehole/t21684610.php.exp @@ -5,7 +5,7 @@ Invalid argument (Typing[4323]) File "t21684610.php", line 9, characters 44-48: This type constraint is violated File "t21684610.php", line 9, characters 44-48: - Expected `I1<[unresolved]>` + Expected `I1<_>` File "t21684610.php", line 23, characters 27-27: But got `int` File "t21684610.php", line 27, characters 16-16: @@ -15,6 +15,6 @@ Invalid argument (Typing[4323]) File "t21684610.php", line 9, characters 44-48: This type constraint is violated File "t21684610.php", line 9, characters 44-48: - Expected `I1<[unresolved]>` + Expected `I1<_>` File "t21684610.php", line 27, characters 16-16: But got `int` diff --git a/hphp/hack/test/typecheck/new_inference/typehole/t21684610.php.exp b/hphp/hack/test/typecheck/new_inference/typehole/t21684610.php.exp index ae8fb74c04f..c1ce6af7200 100644 --- a/hphp/hack/test/typecheck/new_inference/typehole/t21684610.php.exp +++ b/hphp/hack/test/typecheck/new_inference/typehole/t21684610.php.exp @@ -5,6 +5,6 @@ Invalid argument (Typing[4323]) File "t21684610.php", line 8, characters 21-25: This type constraint is violated File "t21684610.php", line 8, characters 21-25: - Expected `I1<[unresolved]>` + Expected `I1<_>` File "t21684610.php", line 15, characters 10-10: But got `int` diff --git a/hphp/hack/test/typecheck/new_inference/untypeable/closure.php.tast_typecheck_exp b/hphp/hack/test/typecheck/new_inference/untypeable/closure.php.tast_typecheck_exp index f22786ef933..7ab6b4f615e 100644 --- a/hphp/hack/test/typecheck/new_inference/untypeable/closure.php.tast_typecheck_exp +++ b/hphp/hack/test/typecheck/new_inference/untypeable/closure.php.tast_typecheck_exp @@ -195,7 +195,7 @@ (([21:3-5], Ref<(int | string)>), (Lvar ([21:3-5], $r))), (([21:8-17], Ref<(int | string)>), (New ( - (([21:12-15], Ref<[unresolved]>), + (([21:12-15], Ref<_>), (CI ([21:12-15], "\\Ref"))), [], [], [], ([21:12-15], _)))) ))))); diff --git a/hphp/hack/test/typecheck/nonnull/await_nonnull.php.exp b/hphp/hack/test/typecheck/nonnull/await_nonnull.php.exp index 415175b1656..efaded7f93e 100644 --- a/hphp/hack/test/typecheck/nonnull/await_nonnull.php.exp +++ b/hphp/hack/test/typecheck/nonnull/await_nonnull.php.exp @@ -9,6 +9,6 @@ Invalid return type (Typing[4336]) File "await_nonnull.php", line 4, characters 3-10: `await` can only operate on an `Awaitable` (Typing[4110]) File "await_nonnull.php", line 4, characters 3-10: - Expected `Awaitable<[unresolved]>` + Expected `Awaitable<_>` File "await_nonnull.php", line 3, characters 18-24: But got `nonnull` diff --git a/hphp/hack/test/typecheck/nonnull/option_is_not_subtype_of_nonnull1.php.exp b/hphp/hack/test/typecheck/nonnull/option_is_not_subtype_of_nonnull1.php.exp dissimilarity index 63% index c4ef2a7d4f9..4903f744540 100644 --- a/hphp/hack/test/typecheck/nonnull/option_is_not_subtype_of_nonnull1.php.exp +++ b/hphp/hack/test/typecheck/nonnull/option_is_not_subtype_of_nonnull1.php.exp @@ -1,12 +1,12 @@ -File "option_is_not_subtype_of_nonnull1.php", line 8, characters 10-16: -Invalid return type (Typing[4110]) -File "option_is_not_subtype_of_nonnull1.php", line 7, characters 18-24: -Expected `nonnull` -File "option_is_not_subtype_of_nonnull1.php", line 3, characters 22-23: -But got `?[unresolved]` -File "option_is_not_subtype_of_nonnull1.php", line 8, characters 10-16: -Invalid return type (Typing[4110]) -File "option_is_not_subtype_of_nonnull1.php", line 7, characters 18-24: -Expected `nonnull` -File "option_is_not_subtype_of_nonnull1.php", line 3, characters 22-23: -But got `null` +File "option_is_not_subtype_of_nonnull1.php", line 8, characters 10-16: +Invalid return type (Typing[4110]) + File "option_is_not_subtype_of_nonnull1.php", line 7, characters 18-24: + Expected `nonnull` + File "option_is_not_subtype_of_nonnull1.php", line 3, characters 22-23: + But got `?_` +File "option_is_not_subtype_of_nonnull1.php", line 8, characters 10-16: +Invalid return type (Typing[4110]) + File "option_is_not_subtype_of_nonnull1.php", line 7, characters 18-24: + Expected `nonnull` + File "option_is_not_subtype_of_nonnull1.php", line 3, characters 22-23: + But got `null` diff --git a/hphp/hack/test/typecheck/nonnull/option_is_not_subtype_of_nonnull2.php.exp b/hphp/hack/test/typecheck/nonnull/option_is_not_subtype_of_nonnull2.php.exp dissimilarity index 63% index dd70d19ac9c..144fa7cca8a 100644 --- a/hphp/hack/test/typecheck/nonnull/option_is_not_subtype_of_nonnull2.php.exp +++ b/hphp/hack/test/typecheck/nonnull/option_is_not_subtype_of_nonnull2.php.exp @@ -1,12 +1,12 @@ -File "option_is_not_subtype_of_nonnull2.php", line 8, characters 10-24: -Invalid return type (Typing[4110]) -File "option_is_not_subtype_of_nonnull2.php", line 7, characters 41-47: -Expected `nonnull` -File "option_is_not_subtype_of_nonnull2.php", line 4, characters 34-35: -But got `?[unresolved]` -File "option_is_not_subtype_of_nonnull2.php", line 8, characters 10-24: -Invalid return type (Typing[4110]) -File "option_is_not_subtype_of_nonnull2.php", line 7, characters 41-47: -Expected `nonnull` -File "option_is_not_subtype_of_nonnull2.php", line 4, characters 34-35: -But got `null` +File "option_is_not_subtype_of_nonnull2.php", line 8, characters 10-24: +Invalid return type (Typing[4110]) + File "option_is_not_subtype_of_nonnull2.php", line 7, characters 41-47: + Expected `nonnull` + File "option_is_not_subtype_of_nonnull2.php", line 4, characters 34-35: + But got `?_` +File "option_is_not_subtype_of_nonnull2.php", line 8, characters 10-24: +Invalid return type (Typing[4110]) + File "option_is_not_subtype_of_nonnull2.php", line 7, characters 41-47: + Expected `nonnull` + File "option_is_not_subtype_of_nonnull2.php", line 4, characters 34-35: + But got `null` diff --git a/hphp/hack/test/typecheck/re_prefixed_string/re_prefixed_string.php.exp b/hphp/hack/test/typecheck/re_prefixed_string/re_prefixed_string.php.exp index bb5cfd6d933..1c62fce1d87 100644 --- a/hphp/hack/test/typecheck/re_prefixed_string/re_prefixed_string.php.exp +++ b/hphp/hack/test/typecheck/re_prefixed_string/re_prefixed_string.php.exp @@ -1,15 +1,15 @@ File "re_prefixed_string.php", line 23, characters 16-17: Invalid argument (Typing[4110]) -File "re_prefixed_string.php", line 26, characters 43-65: -Expected `HH\Lib\Regex\Pattern<[unresolved]>` -File "re_prefixed_string.php", line 20, characters 8-20: -But got `string` because this is the result of a concatenation + File "re_prefixed_string.php", line 26, characters 43-65: + Expected `HH\Lib\Regex\Pattern<_>` + File "re_prefixed_string.php", line 20, characters 8-20: + But got `string` because this is the result of a concatenation File "re_prefixed_string.php", line 26, characters 10-16: Invalid return type (Typing[4336]) -File "re_prefixed_string.php", line 26, characters 78-78: -Expected `T` -File "re_prefixed_string.php", line 26, characters 10-16: -But got `void` because this function does not always return a value + File "re_prefixed_string.php", line 26, characters 78-78: + Expected `T` + File "re_prefixed_string.php", line 26, characters 10-16: + But got `void` because this function does not always return a value File "re_prefixed_string.php", line 32, characters 13-35: Bad regex pattern; two named subpatterns have the same name [14]. (Typing[4275]) File "re_prefixed_string.php", line 33, characters 13-29: diff --git a/hphp/hack/test/typecheck/recursive_non_null_4.php.exp b/hphp/hack/test/typecheck/recursive_non_null_4.php.exp index c8f191335ea..a02f3839f89 100644 --- a/hphp/hack/test/typecheck/recursive_non_null_4.php.exp +++ b/hphp/hack/test/typecheck/recursive_non_null_4.php.exp @@ -1,9 +1,9 @@ File "recursive_non_null_4.php", line 6, characters 3-16: - Map<[unresolved], [unresolved]> + Map<_, _> File "recursive_non_null_4.php", line 13, characters 5-18: - Map<[unresolved], [unresolved]> + Map<_, _> File "recursive_non_null_4.php", line 18, characters 3-16: - Map<[unresolved], [unresolved]> + Map<_, _> File "recursive_non_null_4.php", line 23, characters 3-16: - Map<[unresolved], [unresolved]> + Map<_, _> No errors diff --git a/hphp/hack/test/typecheck/recursive_optional.php.exp b/hphp/hack/test/typecheck/recursive_optional.php.exp index 128b8837d8f..3771bdcd5f6 100644 --- a/hphp/hack/test/typecheck/recursive_optional.php.exp +++ b/hphp/hack/test/typecheck/recursive_optional.php.exp @@ -1,3 +1,3 @@ File "recursive_optional.php", line 18, characters 3-18: - ([unresolved] | [unresolved]) + (_ | _) No errors diff --git a/hphp/hack/test/typecheck/reified_generics/new_self_new_parent.php.exp b/hphp/hack/test/typecheck/reified_generics/new_self_new_parent.php.exp index 452a94b3a70..fe72f818035 100644 --- a/hphp/hack/test/typecheck/reified_generics/new_self_new_parent.php.exp +++ b/hphp/hack/test/typecheck/reified_generics/new_self_new_parent.php.exp @@ -1,7 +1,7 @@ File "new_self_new_parent.php", line 8, characters 5-15: - exact C<[unresolved]> + exact C<_> File "new_self_new_parent.php", line 10, characters 5-15: - exact A<[unresolved]> + exact A<_> File "new_self_new_parent.php", line 7, characters 10-19: Cannot call `new self` because the current class has reified generics. Try `new C` instead. (Typing[4310]) File "new_self_new_parent.php", line 9, characters 10-21: diff --git a/hphp/hack/test/typecheck/shape_idx4.php.exp b/hphp/hack/test/typecheck/shape_idx4.php.exp index 5ed39a24025..fc3ab3e1f79 100644 --- a/hphp/hack/test/typecheck/shape_idx4.php.exp +++ b/hphp/hack/test/typecheck/shape_idx4.php.exp @@ -7,6 +7,6 @@ Invalid argument (Typing[4110]) File "shape_idx4.php", line 7, characters 15-16: Invalid argument (Typing[4110]) File "shape_idx4.php", line 7, characters 15-16: - Expected `shape(?'x' => [unresolved], ...)` because `Shapes::idx` expects a shape + Expected `shape(?'x' => _, ...)` because `Shapes::idx` expects a shape File "shape_idx4.php", line 6, characters 15-17: But got `int` diff --git a/hphp/hack/test/typecheck/shapes_remove_key.php.pess_exp b/hphp/hack/test/typecheck/shapes_remove_key.php.pess_exp index e58e8d4c041..f5dfdba9084 100644 --- a/hphp/hack/test/typecheck/shapes_remove_key.php.pess_exp +++ b/hphp/hack/test/typecheck/shapes_remove_key.php.pess_exp @@ -1,6 +1,6 @@ File "shapes_remove_key.php.pess", line 14, characters 3-39: Invalid assignment (Typing[4110]) File "shapes_remove_key.php.pess", line 6, characters 38-39: - Expected `~[unresolved]` + Expected `~_` File "shapes_remove_key.php.pess", line 14, characters 15-39: But got `shape('a' => int, 'b' => int)` diff --git a/hphp/hack/test/typecheck/shapes_remove_key.php.tgt_pess_exp b/hphp/hack/test/typecheck/shapes_remove_key.php.tgt_pess_exp index e58e8d4c041..f5dfdba9084 100644 --- a/hphp/hack/test/typecheck/shapes_remove_key.php.tgt_pess_exp +++ b/hphp/hack/test/typecheck/shapes_remove_key.php.tgt_pess_exp @@ -1,6 +1,6 @@ File "shapes_remove_key.php.pess", line 14, characters 3-39: Invalid assignment (Typing[4110]) File "shapes_remove_key.php.pess", line 6, characters 38-39: - Expected `~[unresolved]` + Expected `~_` File "shapes_remove_key.php.pess", line 14, characters 15-39: But got `shape('a' => int, 'b' => int)` diff --git a/hphp/hack/test/typecheck/traversable_foreach3.php.exp b/hphp/hack/test/typecheck/traversable_foreach3.php.exp index 27a5cc09dae..243a8891cb7 100644 --- a/hphp/hack/test/typecheck/traversable_foreach3.php.exp +++ b/hphp/hack/test/typecheck/traversable_foreach3.php.exp @@ -1,6 +1,6 @@ File "traversable_foreach3.php", line 13, characters 12-13: Invalid `foreach` (Typing[4110]) -File "traversable_foreach3.php", line 13, characters 12-13: -Expected `KeyedTraversable<[unresolved], [unresolved]>` because this is used in a `foreach` statement -File "traversable_foreach3.php", line 12, characters 15-33: -But got `Traversable` + File "traversable_foreach3.php", line 13, characters 12-13: + Expected `KeyedTraversable<_, _>` because this is used in a `foreach` statement + File "traversable_foreach3.php", line 12, characters 15-33: + But got `Traversable` diff --git a/hphp/hack/test/typecheck/type_structure/type_structure1.php.exp b/hphp/hack/test/typecheck/type_structure/type_structure1.php.exp index 374676ed7c9..db52f326019 100644 --- a/hphp/hack/test/typecheck/type_structure/type_structure1.php.exp +++ b/hphp/hack/test/typecheck/type_structure/type_structure1.php.exp @@ -1,7 +1,7 @@ File "type_structure1.php", line 22, characters 5-44: TypeStructure File "type_structure1.php", line 23, characters 5-57: - classname> + classname> File "type_structure1.php", line 24, characters 5-57: classname File "type_structure1.php", line 27, characters 5-30: diff --git a/hphp/hack/test/typecheck/unify_unresolved.php.exp b/hphp/hack/test/typecheck/unify_unresolved.php.exp index f561810ca5c..b09c7212181 100644 --- a/hphp/hack/test/typecheck/unify_unresolved.php.exp +++ b/hphp/hack/test/typecheck/unify_unresolved.php.exp @@ -1,3 +1,3 @@ File "unify_unresolved.php", line 7, characters 3-13: - Vector<[unresolved]> + Vector<_> No errors diff --git a/hphp/hack/test/typecheck/union/generics.php.exp b/hphp/hack/test/typecheck/union/generics.php.exp index c9d4527ae4d..98f2dcbfb88 100644 --- a/hphp/hack/test/typecheck/union/generics.php.exp +++ b/hphp/hack/test/typecheck/union/generics.php.exp @@ -1,19 +1,19 @@ File "generics.php--file2.php", line 68, characters 3-13: exact A File "generics.php--file2.php", line 71, characters 3-13: - (exact A<[unresolved]> | exact A<[unresolved]>) + (exact A<_> | exact A<_>) File "generics.php--file2.php", line 74, characters 3-13: - (exact A | exact A<[unresolved]>) + (exact A | exact A<_>) File "generics.php--file2.php", line 77, characters 3-13: exact B File "generics.php--file2.php", line 80, characters 3-13: - (exact B<[unresolved]> | exact B<[unresolved]>) + (exact B<_> | exact B<_>) File "generics.php--file2.php", line 83, characters 3-13: A File "generics.php--file2.php", line 86, characters 3-13: - (A | exact A<[unresolved]>) + (A | exact A<_>) File "generics.php--file2.php", line 89, characters 3-13: - (exact A<[unresolved]> | A) + (exact A<_> | A) File "generics.php--file2.php", line 92, characters 3-13: (exact A | A) File "generics.php--file2.php", line 95, characters 3-13: @@ -29,7 +29,7 @@ File "generics.php--file2.php", line 105, characters 3-13: File "generics.php--file2.php", line 106, characters 3-34: bool File "generics.php--file2.php", line 109, characters 3-13: - (exact A | exact B<[unresolved]>) + (exact A | exact B<_>) File "generics.php--file2.php", line 110, characters 3-25: bool File "generics.php--file2.php", line 113, characters 3-13: diff --git a/hphp/hack/test/typecheck/union/map_corner_case.php.exp b/hphp/hack/test/typecheck/union/map_corner_case.php.exp index 16348a658e5..8a92fa42750 100644 --- a/hphp/hack/test/typecheck/union/map_corner_case.php.exp +++ b/hphp/hack/test/typecheck/union/map_corner_case.php.exp @@ -3,4 +3,4 @@ Invalid assignment (Typing[4110]) File "map_corner_case.php", line 13, characters 10-22: Expected `nothing` because a type could not be determined here File "map_corner_case.php", line 13, characters 27-32: - But got `Map<[unresolved], [unresolved]>` + But got `Map<_, _>` diff --git a/hphp/hack/test/typecheck/union/map_corner_case.php.legacy_decl.exp b/hphp/hack/test/typecheck/union/map_corner_case.php.legacy_decl.exp index 16348a658e5..8a92fa42750 100644 --- a/hphp/hack/test/typecheck/union/map_corner_case.php.legacy_decl.exp +++ b/hphp/hack/test/typecheck/union/map_corner_case.php.legacy_decl.exp @@ -3,4 +3,4 @@ Invalid assignment (Typing[4110]) File "map_corner_case.php", line 13, characters 10-22: Expected `nothing` because a type could not be determined here File "map_corner_case.php", line 13, characters 27-32: - But got `Map<[unresolved], [unresolved]>` + But got `Map<_, _>` diff --git a/hphp/hack/test/typecheck/union/mixed.php.exp b/hphp/hack/test/typecheck/union/mixed.php.exp index 71a1f3f6a24..d901f481f06 100644 --- a/hphp/hack/test/typecheck/union/mixed.php.exp +++ b/hphp/hack/test/typecheck/union/mixed.php.exp @@ -9,7 +9,7 @@ File "mixed.php", line 43, characters 3-13: File "mixed.php", line 54, characters 3-13: (function(string $s1, string $s2): (int | string)) File "mixed.php", line 63, characters 3-13: - ((function(?(dynamic | bool | float | resource | arraykey | HH\FormatString<[unresolved]>) $s1, ?(dynamic | bool | float | resource | arraykey | HH\FormatString<[unresolved]>) $s2): string) | (function(string $s1, string $s2): int)) + ((function(?(dynamic | bool | float | resource | arraykey | HH\FormatString<_>) $s1, ?(dynamic | bool | float | resource | arraykey | HH\FormatString<_>) $s2): string) | (function(string $s1, string $s2): int)) File "mixed.php", line 72, characters 3-13: A File "mixed.php", line 76, characters 3-13: diff --git a/hphp/hack/test/typecheck/variadic_args1.php.exp b/hphp/hack/test/typecheck/variadic_args1.php.exp index a518d990a9f..318d8edadfe 100644 --- a/hphp/hack/test/typecheck/variadic_args1.php.exp +++ b/hphp/hack/test/typecheck/variadic_args1.php.exp @@ -1,7 +1,7 @@ File "variadic_args1.php--strict.php", line 15, characters 20-24: Invalid argument (Typing[4110]) File "variadic_args1.php--strict.php", line 29, characters 34-46: - Expected `dict<[unresolved], [unresolved]>` + Expected `dict<_, _>` File "variadic_args1.php--strict.php", line 8, characters 21-25: But got `vec` (variadic argument) File "variadic_args1.php--strict.php", line 29, characters 34-46: diff --git a/hphp/hack/test/typecheck/yield/asyncgen11.php.exp b/hphp/hack/test/typecheck/yield/asyncgen11.php.exp index 38c7ff51a2c..2bf1ac280d9 100644 --- a/hphp/hack/test/typecheck/yield/asyncgen11.php.exp +++ b/hphp/hack/test/typecheck/yield/asyncgen11.php.exp @@ -3,4 +3,4 @@ Invalid `yield` (Typing[4110]) File "asyncgen11.php", line 3, characters 36-38: Expected `int` File "asyncgen11.php", line 4, characters 9-12: - But got `?[unresolved]` because `yield x` is equivalent to `yield null => x` in an `async` function + But got `?_` because `yield x` is equivalent to `yield null => x` in an `async` function diff --git a/hphp/hack/test/typecheck/yield/asyncgen2.php.exp b/hphp/hack/test/typecheck/yield/asyncgen2.php.exp index 4053a3c6ad0..cd6edb751d5 100644 --- a/hphp/hack/test/typecheck/yield/asyncgen2.php.exp +++ b/hphp/hack/test/typecheck/yield/asyncgen2.php.exp @@ -4,7 +4,7 @@ File "asyncgen2.php", line 15, characters 5-15: nothing File "asyncgen2.php", line 13, characters 12-14: Invalid `foreach` (Typing[4110]) -File "asyncgen2.php", line 13, characters 12-14: -Expected `KeyedTraversable<[unresolved], [unresolved]>` because this is used in a `foreach` statement -File "asyncgen2.php", line 7, characters 21-53: -But got `AsyncGenerator` + File "asyncgen2.php", line 13, characters 12-14: + Expected `KeyedTraversable<_, _>` because this is used in a `foreach` statement + File "asyncgen2.php", line 7, characters 21-53: + But got `AsyncGenerator` diff --git a/hphp/hack/test/typecheck/yield/asyncgen3.php.exp b/hphp/hack/test/typecheck/yield/asyncgen3.php.exp index 08b1797af7a..f95976e6744 100644 --- a/hphp/hack/test/typecheck/yield/asyncgen3.php.exp +++ b/hphp/hack/test/typecheck/yield/asyncgen3.php.exp @@ -5,4 +5,4 @@ Invalid return type (Typing[4110]) File "asyncgen3.php", line 7, characters 15-47: Expected `AsyncGenerator` File "asyncgen3.php", line 7, characters 15-47: - But got `Generator<[unresolved], [unresolved], [unresolved]>` (result of function containing a `yield`) + But got `Generator<_, _, _>` (result of function containing a `yield`) diff --git a/hphp/hack/test/typecheck/yield/asyncgen4.php.exp b/hphp/hack/test/typecheck/yield/asyncgen4.php.exp index 0af2ac48fbb..3bf600c260f 100644 --- a/hphp/hack/test/typecheck/yield/asyncgen4.php.exp +++ b/hphp/hack/test/typecheck/yield/asyncgen4.php.exp @@ -7,10 +7,10 @@ Invalid return type (Typing[4110]) File "asyncgen4.php", line 7, characters 21-48: Expected `Generator` File "asyncgen4.php", line 7, characters 21-48: - But got `AsyncGenerator<[unresolved], [unresolved], [unresolved]>` (result of `async function` containing a `yield`) + But got `AsyncGenerator<_, _, _>` (result of `async function` containing a `yield`) File "asyncgen4.php", line 13, characters 12-14: Invalid `foreach` (Typing[4110]) File "asyncgen4.php", line 13, characters 12-14: - Expected `AsyncKeyedIterator<[unresolved], [unresolved]>` because this is used in a `foreach` statement with `await as` + Expected `AsyncKeyedIterator<_, _>` because this is used in a `foreach` statement with `await as` File "asyncgen4.php", line 7, characters 21-48: But got `Generator` diff --git a/hphp/hack/test/typecheck/yield/asyncgen5.php.exp b/hphp/hack/test/typecheck/yield/asyncgen5.php.exp index d17206ebf15..cd11473b41d 100644 --- a/hphp/hack/test/typecheck/yield/asyncgen5.php.exp +++ b/hphp/hack/test/typecheck/yield/asyncgen5.php.exp @@ -3,4 +3,4 @@ Invalid return type (Typing[4110]) File "asyncgen5.php", line 7, characters 15-47: Expected `AsyncGenerator` File "asyncgen5.php", line 7, characters 15-47: - But got `Generator<[unresolved], [unresolved], [unresolved]>` (result of function containing a `yield`) + But got `Generator<_, _, _>` (result of function containing a `yield`) diff --git a/hphp/hack/test/typecheck/yield/asyncgen6.php.exp b/hphp/hack/test/typecheck/yield/asyncgen6.php.exp index 4c7e706a830..dbce8143c6c 100644 --- a/hphp/hack/test/typecheck/yield/asyncgen6.php.exp +++ b/hphp/hack/test/typecheck/yield/asyncgen6.php.exp @@ -1,6 +1,6 @@ File "asyncgen6.php", line 13, characters 3-11: `await` can only operate on an `Awaitable` (Typing[4110]) -File "asyncgen6.php", line 13, characters 3-11: -Expected `Awaitable<[unresolved]>` -File "asyncgen6.php", line 7, characters 21-53: -But got `AsyncGenerator` + File "asyncgen6.php", line 13, characters 3-11: + Expected `Awaitable<_>` + File "asyncgen6.php", line 7, characters 21-53: + But got `AsyncGenerator` diff --git a/hphp/hack/test/typecheck/yield/asyncgen9.php.exp b/hphp/hack/test/typecheck/yield/asyncgen9.php.exp index 841d9b2d133..890f9f37386 100644 --- a/hphp/hack/test/typecheck/yield/asyncgen9.php.exp +++ b/hphp/hack/test/typecheck/yield/asyncgen9.php.exp @@ -2,7 +2,7 @@ File "asyncgen9.php", line 4, characters 16-20: `await` can only be used inside `async` functions (NastCheck[3003]) File "asyncgen9.php", line 4, characters 12-14: Invalid `foreach` (Typing[4110]) -File "asyncgen9.php", line 4, characters 12-14: -Expected `AsyncIterator<[unresolved]>` because this is used in a `foreach` statement with `await as` -File "asyncgen9.php", line 8, characters 15-28: -But got `Awaitable` + File "asyncgen9.php", line 4, characters 12-14: + Expected `AsyncIterator<_>` because this is used in a `foreach` statement with `await as` + File "asyncgen9.php", line 8, characters 15-28: + But got `Awaitable` diff --git a/hphp/hack/test/typecheck/yield/yield_lambda_async.php.exp b/hphp/hack/test/typecheck/yield/yield_lambda_async.php.exp index 95e65c4709b..7408cfa0654 100644 --- a/hphp/hack/test/typecheck/yield/yield_lambda_async.php.exp +++ b/hphp/hack/test/typecheck/yield/yield_lambda_async.php.exp @@ -3,10 +3,10 @@ Invalid return type (Typing[4110]) File "yield_lambda_async.php", line 13, characters 12-42: Expected `AsyncGenerator` File "yield_lambda_async.php", line 13, characters 12-42: - But got `Generator<[unresolved], [unresolved], [unresolved]>` (result of function containing a `yield`) + But got `Generator<_, _, _>` (result of function containing a `yield`) File "yield_lambda_async.php", line 20, characters 18-43: Invalid return type (Typing[4110]) File "yield_lambda_async.php", line 20, characters 18-43: Expected `Generator` File "yield_lambda_async.php", line 20, characters 18-43: - But got `AsyncGenerator<[unresolved], [unresolved], [unresolved]>` (result of `async function` containing a `yield`) + But got `AsyncGenerator<_, _, _>` (result of `async function` containing a `yield`) diff --git a/hphp/hack/test/typecheck/yield_method.php.exp b/hphp/hack/test/typecheck/yield_method.php.exp index 40d8498ec5c..6c46f09c458 100644 --- a/hphp/hack/test/typecheck/yield_method.php.exp +++ b/hphp/hack/test/typecheck/yield_method.php.exp @@ -3,4 +3,4 @@ Invalid return type (Typing[4110]) File "yield_method.php", line 5, characters 24-26: Expected `int` File "yield_method.php", line 5, characters 24-26: - But got `Generator<[unresolved], [unresolved], [unresolved]>` (result of function containing a `yield`) + But got `Generator<_, _, _>` (result of function containing a `yield`) -- 2.11.4.GIT