Deleted Added
sdiff udiff text old ( 13039:0c8ecf92a420 ) new ( 13040:877a6e22f8d4 )
full compact
1/*
2 * Copyright 2018 Google, Inc.
3 *
4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are
6 * met: redistributions of source code must retain the above copyright
7 * notice, this list of conditions and the following disclaimer;
8 * redistributions in binary form must reproduce the above copyright

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

171sc_time::value() const
172{
173 return val;
174}
175
176double
177sc_time::to_double() const
178{
179 warn("%s not implemented.\n", __PRETTY_FUNCTION__);
180 return 0.0;
181}
182double
183sc_time::to_seconds() const
184{
185 warn("%s not implemented.\n", __PRETTY_FUNCTION__);
186 return 0.0;
187}
188

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

239sc_time &
240sc_time::operator -= (const sc_time &t)
241{
242 val -= t.val;
243 return *this;
244}
245
246sc_time &
247sc_time::operator *= (double)
248{
249 warn("%s not implemented.\n", __PRETTY_FUNCTION__);
250 return *this;
251}
252
253sc_time &
254sc_time::operator /= (double)
255{
256 warn("%s not implemented.\n", __PRETTY_FUNCTION__);
257 return *this;
258}
259
260void
261sc_time::print(std::ostream &os) const
262{
263 if (val == 0) {
264 os << "0 s";

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

305
306const sc_time
307operator - (const sc_time &a, const sc_time &b)
308{
309 return sc_time::from_value(a.value() - b.value());
310}
311
312const sc_time
313operator * (const sc_time &, double)
314{
315 warn("%s not implemented.\n", __PRETTY_FUNCTION__);
316 return sc_time();
317}
318
319const sc_time
320operator * (double, const sc_time &)
321{
322 warn("%s not implemented.\n", __PRETTY_FUNCTION__);
323 return sc_time();
324}
325
326const sc_time
327operator / (const sc_time &, double)
328{
329 warn("%s not implemented.\n", __PRETTY_FUNCTION__);
330 return sc_time();
331}
332
333double
334operator / (const sc_time &, const sc_time &)
335{
336 warn("%s not implemented.\n", __PRETTY_FUNCTION__);
337 return 0.0;
338}
339
340std::ostream &
341operator << (std::ostream &os, const sc_time &t)
342{
343 t.print(os);
344 return os;
345}

--- 77 unchanged lines hidden ---