Skip to content

Clarifications on when array shapes are enforced #7004

Answered by ondrejmirtes
herndlm asked this question in Support
Discussion options

You must be logged in to vote

Foo::fromArray1($data); could/should report an error on level 9 but I guess that $data consists of ArrayType with implicit MixedType, not explicit MixedType. It can be seen in IsArrayFunctionTypeSpecifyingExtension. My bet is that if you modify that to return explicit MixedType, the error is going to be reported.

Replies: 3 comments 4 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@herndlm
Comment options

@flobee
Comment options

Comment options

You must be logged in to vote
2 replies
@herndlm
Comment options

@herndlm
Comment options

Answer selected by herndlm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Support
Labels
None yet
3 participants