builtin/ls-tree: convert to struct object_id