Hacker News new | ask | show | jobs
by notresidenter 583 days ago
You should look at `func_get_args()` usage in the wild. This is sometimes used for (mostly outdated) good-enough reasons and doing this might break it?
1 comments

I know of func_get_args, but proper variadic functions have been a thing since PHP 5.6 (released more than 10 years ago) using the ... operator. Also, my initial proposal doesn't break existing code :).
Variadic functions serve a purpose but also change how the engine parses arguments. func_get_args is faster and more efficient.