Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
API page: http://api.drupal.org/api/drupal/includes%21module.inc/function/module_i...
The gist of this comment http://api.drupal.org/comment/35778#comment-35778 should be added to the docs for both functions.
Comment | File | Size | Author |
---|---|---|---|
#5 | drupal-module-invoke-args-d7-1936166-2.patch | 1.3 KB | markpavlitski |
#2 | drupal-module-invoke-args-d8-1936166-2.patch | 1.1 KB | markpavlitski |
Comments
Comment #1
jhodgdonSounds like a good thing to document that arguments are not passed by reference. Should probably also mention that if you need to pass things by reference, you can use drupal_alter() (or alter hooks in general).
Comment #2
markpavlitski CreditAttribution: markpavlitski commentedThis patch documents that arguments are passed by value and refers to drupal_alter() as an alternative.
Comment #3
jhodgdonThanks! I'll get this committed shortly unless one of the other maintainers gets to it first.
Comment #4
jhodgdonThanks! Committed to 8.x. Needs porting to 7.x.
Comment #5
markpavlitski CreditAttribution: markpavlitski commentedD7 patch attached.
Comment #6
jhodgdonThanks! Committed to 7.x.