| 22 | std::stringstream buffer; |
| 23 | |
| 24 | struct Stream { |
| 25 | Stream(std::ostream& stream); |
| 26 | |
| 27 | template <typename T> |
| 28 | Stream& operator<<(T value); |
| 29 | |
| 30 | template <typename T> |
| 31 | Stream& operator<<(const std::vector<T> values){ |
| 32 | *this << (u32_t)values.size(); |
| 33 | for(T value : values){ |
| 34 | *this << value; |
| 35 | } |
| 36 | return *this; |
| 37 | } |
| 38 | |
| 39 | Stream& operator<<(std::stringstream& value); |
| 40 | private: |
| 41 | std::ostream& stream; |
| 42 | }; |
| 43 | }; |
| 44 | |
| 45 | struct Type : public Section { |