typeof instance === "object". Special non-data but Structural type for any constructed object instance also used as data structures: new
Date and almost everything made with new keyword;
This quote shows us that equivalent/similar data types across languages are implemented and therefore grouped differently which means that we can’t use exactly same naming. Different naming forces new developer to think:
Why it's named like that? and that ends up with looking for it’s definition.
Having in mind that both
unpack are used only for
objects it’s confusing to use them in
Elixir for other data types like for example
Destructure naming could also be confusing for newbies as we have
unpack antonyms suggest that we have something
packed which is not always true. While it’s common to say that we are unpacking bits from
string still we can’t say that we are
unpacking something from
literal like for example:
5 = variable.
Generally i.e. for all data types I prefer to think about some connection of
take words (which are most common) like
taking by pattern or something like that.
@AstonJ Considering your
Erlang code we can say that we are
Height by 3-element tuple pattern of
Rectangle variable. What do you think about it?