Preserve array keys in PhutilReadableSerializer::printShallowRecursive()
Summary: See T582. When a user phlog()'s a value into DarkConsole and then
clicks it for details, printShallow() incorrectly rekeys arrays because PHP
subtly discards keys in array_slice(). Instead, explicitly preserve keys.
Test Plan:
- Added a phlog() for an array with keys 1, 2.
- Clicked it in DarkConsole for details, saw keys 0, 1.
- Applied patch, saw keys 1, 2.
Reviewers: Girish, tuomaspelkonen, edward
Reviewed By: tuomaspelkonen
CC: aran, tuomaspelkonen
Differential Revision: 1029