Skip to content

Advice on using list on vec is confusing #1367

@qawt

Description

@qawt

Please complete the information below:

Where is the problem?

https://docs.hhvm.com/hack/expressions-and-operators/list

"You may also use list() on a vec, but it is not recommended."

What is the problem?

  1. It doesn't explain why, and what bad things could happen
  2. The example below literally does exactly that "foreach ($vec_of_tuples as list($first, $second, $third)) {" as an example.
  3. nit: "My personal favorite place" Who is this, and is this credible?

Please don't change anything below this point.


  • Build ID: HHVM=HHVM-4.164.0:HSL=v4.108.1:2024-02-08T13:44:46+0000:1fa47f258c6b68f8ec01899aa82fd6ffa0957109
  • Page requested: /hack/expressions-and-operators/list
  • Page requested at: Wed, 17 Apr 2024 20:37:50 +0000

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions