serialize.hh (13415:dfba7ea400e2) serialize.hh (13567:08896772e474)
1/*
2 * Copyright (c) 2015, 2018 ARM Limited
3 * All rights reserved
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software

--- 275 unchanged lines hidden (view full) ---

284{
285 os << value;
286}
287
288template <class T>
289bool
290parseParam(const std::string &s, BitUnionType<T> &value)
291{
1/*
2 * Copyright (c) 2015, 2018 ARM Limited
3 * All rights reserved
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software

--- 275 unchanged lines hidden (view full) ---

284{
285 os << value;
286}
287
288template <class T>
289bool
290parseParam(const std::string &s, BitUnionType<T> &value)
291{
292 auto storage = static_cast<BitUnionBaseType<T>>(value);
292 // Zero initialize storage to avoid leaking an uninitialized value
293 BitUnionBaseType<T> storage = BitUnionBaseType<T>();
293 auto res = to_number(s, storage);
294 value = storage;
295 return res;
296}
297
298template <class T>
299void
300showParam(CheckpointOut &os, const BitUnionType<T> &value)

--- 381 unchanged lines hidden ---
294 auto res = to_number(s, storage);
295 value = storage;
296 return res;
297}
298
299template <class T>
300void
301showParam(CheckpointOut &os, const BitUnionType<T> &value)

--- 381 unchanged lines hidden ---