[Zucchini] Add io_utils

Desktop / Chromium - huangs [google.com] - 12 July 2017 13:59 EDT

This CL adds Zucchini utilities related to parsing and printing, along with tests. Details:- LimitedOutputStream: Used for printing error messages without flooding console with output.
- AsHex: Syntactical sugar for iostream-printing of hex values.
- PrefixSep: Syntactical sugar for iostream-printing of list of values.- EatChar and StrictUInt: Parse command line parameters. Will be used to parse imposed matches.

Bug: 729154 Change-Id: I232295419172a5b52cbb39cea89009a2e03fb684 Reviewed-on: https://chromium-review.googlesource.com/567265 Commit-Queue: Erik Chen

477a9e3 [Zucchini] Add io_utils.
chrome/installer/zucchini/BUILD.gn | 3 +
chrome/installer/zucchini/io_utils.cc | 52 ++++++++
chrome/installer/zucchini/io_utils.h | 144 ++++++++++++++++++++++
chrome/installer/zucchini/io_utils_unittest.cc | 159 +++++++++++++++++++++++++
4 files changed, 358 insertions(+)

Upstream: git.chromium.org


  • Share