Philipp,
Thanks for catching the typos (which I made despite building my own
prototype 8=).
Do we really need to add the new operator= ? Is it not covered by a
combination of the first operator= and the implicit conversion from
sc_signal<T,POL> to T provided by operator const T& ?
John A
From:
"Philipp A. Hartmann" <philipp.hartmann@offis.de>
To:
John Aynsley <john.aynsley@doulos.com>
Cc:
SystemC P1666 Technical <systemc-p1666-technical@eda.org>
Date:
22/11/2010 13:40
Subject:
Review: sc_writer_policy
John,
while cleaning up my implementation along the wording of the
sc_writer_policy in the new Draft LRM, I've noticed some minor issues in
the definitions:
Assignment operators sc_signal/buffer:
To support assignments from signals with different policies, I think
we should add an assignment operator, taking sc_signal_in_if<T> to
all signal variants.
For sc_signal, this would lead to (signal variant still needed to
avoid pre-defined operator=):
sc_signal<T,POL>& operator=( T const& );
sc_signal<T,POL>& operator=( sc_signal_in_if<T> const& );
sc_signal<T,POL>& operator=( sc_signal<T,POL> const& );
For sc_buffer, we can change the sc_signal overload to interface
variant:
sc_buffer<T,POL>& operator=( T const& );
sc_buffer<T,POL>& operator=( sc_signal_in_if<T> const& );
sc_buffer<T,POL>& operator=( sc_buffer<T,POL> const& );
Output stream operator (typos):
template <class T, sc_writer_policy WRITER_POLICY = SC_ONE_WRITER>
inline std::ostream&
operator<< ( std::ostream&, const sc_signal<T,WRITER_POLICY>& );
-> default argument not allowed for template functions [7.4.2]
In 7.4.11, the second template parameter is missing.
sc_signal<bool/sc_logic>::get_writer_policy
For the bool/sc_logic specialisations, the get_writer_policy functions
are missing.
Greertings from Oldenburg,
Philipp
-- Philipp A. Hartmann Hardware/Software Design Methodology Group OFFIS Institute for Information Technology R&D Division Transportation · FuE-Bereich Verkehr Escherweg 2 · 26121 Oldenburg · Germany · http://offis.de/en/ Phone/Fax: +49-441-9722-420/282 · PGP: 0x9161A5C0 · Skype: phi.har -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.Received on Mon Nov 22 07:00:42 2010
This archive was generated by hypermail 2.1.8 : Mon Nov 22 2010 - 07:00:45 PST