Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc weird aligning and double text and missing information #116

Closed
flip111 opened this issue Dec 6, 2014 · 3 comments
Closed

doc weird aligning and double text and missing information #116

flip111 opened this issue Dec 6, 2014 · 3 comments

Comments

@flip111
Copy link

flip111 commented Dec 6, 2014

consider:

>>> doc array_reduce
function array_reduce($arg, $callback, $initial = unknown)

Description:
  Iteratively reduce the array to a single value using a callback function

  array_reduce applies iteratively the callback function to the elements of the array, so as
  to reduce the array to a single value.

Param:
  array     $array     The input array.
  callable  $callback  Holds the return value of the previous iteration; in the case of the first
                       iteration it instead holds the value of initial.

                       Holds the value of the current iteration.
  mixed     $carry     Holds the return value of the previous iteration; in the case of the first
                       iteration it instead holds the value of initial.
  mixed     $item      Holds the value of the current iteration.
  mixed     $initial   If the optional initial is available, it will be used at the beginning of
                       the process, or as a final result in case the array is empty.

Return:
  mixed  Returns the resulting value.

         If the array is empty and initial is not passed, array_reduce returns null.

Reference: http://php.net/manual/en/function.array-reduce.php

problem 1: $carry and $item are idented on the php website, but not in psysh
problem 2: double sentences such as Holds the value of the current iteration
problem 3: missing information function header mixed callback ( mixed $carry , mixed $item )

@bobthecow
Copy link
Owner

Good catch. I'll take a look at it and see if I can get it to make sense.

@bobthecow
Copy link
Owner

Update: the fix for this is actually quite a bit of work. I've got an initial shot at it, but it's not all fixed just yet. Sorry about the delay.

@bobthecow
Copy link
Owner

Closing in favor of #599

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants