sc_in.hh (12841:22aa7ba47bf9) sc_in.hh (12868:23162a436538)
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
9 * notice, this list of conditions and the following disclaimer in the
10 * documentation and/or other materials provided with the distribution;
11 * neither the name of the copyright holders nor the names of its
12 * contributors may be used to endorse or promote products derived from
13 * this software without specific prior written permission.
14 *
15 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
16 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
17 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
18 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
19 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
20 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
21 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
22 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
23 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
25 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 *
27 * Authors: Gabe Black
28 */
29
30#ifndef __SYSTEMC_EXT_CHANNEL_SC_IN_HH__
31#define __SYSTEMC_EXT_CHANNEL_SC_IN_HH__
32
33#include <string>
34
35#include "../core/sc_port.hh"
36#include "sc_signal_in_if.hh"
37#include "sc_signal_inout_if.hh"
38#include "warn_unimpl.hh"
39
40namespace sc_core
41{
42
43class sc_event;
44class sc_event_finder;
45class sc_trace_file;
46
47template <class T>
48class sc_in : public sc_port<sc_signal_in_if<T>, 1>
49{
50 public:
51 sc_in() : sc_port<sc_signal_in_if<T>, 1>() {}
52 explicit sc_in(const char *name) : sc_port<sc_signal_in_if<T>, 1>(name) {}
53 virtual ~sc_in() {}
54
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
9 * notice, this list of conditions and the following disclaimer in the
10 * documentation and/or other materials provided with the distribution;
11 * neither the name of the copyright holders nor the names of its
12 * contributors may be used to endorse or promote products derived from
13 * this software without specific prior written permission.
14 *
15 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
16 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
17 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
18 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
19 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
20 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
21 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
22 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
23 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
25 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 *
27 * Authors: Gabe Black
28 */
29
30#ifndef __SYSTEMC_EXT_CHANNEL_SC_IN_HH__
31#define __SYSTEMC_EXT_CHANNEL_SC_IN_HH__
32
33#include <string>
34
35#include "../core/sc_port.hh"
36#include "sc_signal_in_if.hh"
37#include "sc_signal_inout_if.hh"
38#include "warn_unimpl.hh"
39
40namespace sc_core
41{
42
43class sc_event;
44class sc_event_finder;
45class sc_trace_file;
46
47template <class T>
48class sc_in : public sc_port<sc_signal_in_if<T>, 1>
49{
50 public:
51 sc_in() : sc_port<sc_signal_in_if<T>, 1>() {}
52 explicit sc_in(const char *name) : sc_port<sc_signal_in_if<T>, 1>(name) {}
53 virtual ~sc_in() {}
54
55 // Deprecated binding constructors.
56 explicit sc_in(const sc_signal_in_if<T> &interface) :
57 sc_port<sc_signal_in_if<T>, 1>(interface)
58 {}
59 sc_in(const char *name, const sc_signal_in_if<T> &interface) :
60 sc_port<sc_signal_in_if<T>, 1>(name, interface)
61 {}
62 explicit sc_in(sc_port_b<sc_signal_in_if<T> > &parent) :
63 sc_port<sc_signal_in_if<T>, 1>(parent)
64 {}
65 sc_in(const char *name, sc_port_b<sc_signal_in_if<T> > &parent) :
66 sc_port<sc_signal_in_if<T>, 1>(name, parent)
67 {}
68 explicit sc_in(sc_port<sc_signal_in_if<T>, 1> &parent) :
69 sc_port<sc_signal_in_if<T>, 1>(parent)
70 {}
71 sc_in(const char *name, sc_port<sc_signal_in_if<T>, 1> &parent) :
72 sc_port<sc_signal_in_if<T>, 1>(name, parent)
73 {}
74
55 virtual void
56 bind(const sc_signal_in_if<T> &)
57 {
58 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
59 }
60 void
61 operator () (const sc_signal_in_if<T> &)
62 {
63 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
64 }
65
66 virtual void
67 bind(sc_port<sc_signal_in_if<T>, 1> &)
68 {
69 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
70 }
71 void
72 operator () (sc_port<sc_signal_in_if<T>, 1> &)
73 {
74 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
75 }
76
77 virtual void
78 bind(sc_port<sc_signal_inout_if<T>, 1> &)
79 {
80 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
81 }
82 void
83 operator () (sc_port<sc_signal_inout_if<T>, 1> &)
84 {
85 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
86 }
87
88 virtual void
89 end_of_elaboration()
90 {
91 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
92 }
93
94 const T &
95 read() const
96 {
97 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
98 return *(const T *)nullptr;
99 }
100 operator const T& () const
101 {
102 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
103 return *(const T *)nullptr;
104 }
105
106 const sc_event &
107 default_event() const
108 {
109 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
110 return *(const sc_event *)nullptr;
111 }
112 const sc_event &
113 value_changed_event() const
114 {
115 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
116 return *(const sc_event *)nullptr;
117 }
118 bool
119 event() const
120 {
121 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
122 return false;
123 }
124 sc_event_finder &
125 value_changed() const
126 {
127 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
128 return *(sc_event_finder *)nullptr;
129 }
130
131 virtual const char *kind() const { return "sc_in"; }
132
133 private:
134 // Disabled
135 sc_in(const sc_in<T> &) : sc_port<sc_signal_in_if<T>, 1>() {}
136 sc_in<T> &operator = (const sc_in<T> &) { return *this; }
137};
138
139template <class T>
140inline void
141sc_trace(sc_trace_file *, const sc_in<T> &, const std::string &)
142{
143 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
144}
145
146template <>
147class sc_in<bool> : public sc_port<sc_signal_in_if<bool>, 1>
148{
149 public:
150 sc_in() : sc_port<sc_signal_in_if<bool>, 1>() {}
151 explicit sc_in(const char *name) :
152 sc_port<sc_signal_in_if<bool>, 1>(name) {}
153 virtual ~sc_in() {}
154
75 virtual void
76 bind(const sc_signal_in_if<T> &)
77 {
78 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
79 }
80 void
81 operator () (const sc_signal_in_if<T> &)
82 {
83 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
84 }
85
86 virtual void
87 bind(sc_port<sc_signal_in_if<T>, 1> &)
88 {
89 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
90 }
91 void
92 operator () (sc_port<sc_signal_in_if<T>, 1> &)
93 {
94 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
95 }
96
97 virtual void
98 bind(sc_port<sc_signal_inout_if<T>, 1> &)
99 {
100 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
101 }
102 void
103 operator () (sc_port<sc_signal_inout_if<T>, 1> &)
104 {
105 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
106 }
107
108 virtual void
109 end_of_elaboration()
110 {
111 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
112 }
113
114 const T &
115 read() const
116 {
117 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
118 return *(const T *)nullptr;
119 }
120 operator const T& () const
121 {
122 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
123 return *(const T *)nullptr;
124 }
125
126 const sc_event &
127 default_event() const
128 {
129 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
130 return *(const sc_event *)nullptr;
131 }
132 const sc_event &
133 value_changed_event() const
134 {
135 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
136 return *(const sc_event *)nullptr;
137 }
138 bool
139 event() const
140 {
141 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
142 return false;
143 }
144 sc_event_finder &
145 value_changed() const
146 {
147 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
148 return *(sc_event_finder *)nullptr;
149 }
150
151 virtual const char *kind() const { return "sc_in"; }
152
153 private:
154 // Disabled
155 sc_in(const sc_in<T> &) : sc_port<sc_signal_in_if<T>, 1>() {}
156 sc_in<T> &operator = (const sc_in<T> &) { return *this; }
157};
158
159template <class T>
160inline void
161sc_trace(sc_trace_file *, const sc_in<T> &, const std::string &)
162{
163 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
164}
165
166template <>
167class sc_in<bool> : public sc_port<sc_signal_in_if<bool>, 1>
168{
169 public:
170 sc_in() : sc_port<sc_signal_in_if<bool>, 1>() {}
171 explicit sc_in(const char *name) :
172 sc_port<sc_signal_in_if<bool>, 1>(name) {}
173 virtual ~sc_in() {}
174
175 // Deprecated binding constructors.
176 explicit sc_in(const sc_signal_in_if<bool> &interface) :
177 sc_port<sc_signal_in_if<bool>, 1>(interface)
178 {}
179 sc_in(const char *name, const sc_signal_in_if<bool> &interface) :
180 sc_port<sc_signal_in_if<bool>, 1>(name, interface)
181 {}
182 explicit sc_in(sc_port_b<sc_signal_in_if<bool> > &parent) :
183 sc_port<sc_signal_in_if<bool>, 1>(parent)
184 {}
185 sc_in(const char *name, sc_port_b<sc_signal_in_if<bool> > &parent) :
186 sc_port<sc_signal_in_if<bool>, 1>(name, parent)
187 {}
188 explicit sc_in(sc_port<sc_signal_in_if<bool>, 1> &parent) :
189 sc_port<sc_signal_in_if<bool>, 1>(parent)
190 {}
191 sc_in(const char *name, sc_port<sc_signal_in_if<bool>, 1> &parent) :
192 sc_port<sc_signal_in_if<bool>, 1>(name, parent)
193 {}
194
155 virtual void
156 bind(const sc_signal_in_if<bool> &)
157 {
158 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
159 }
160 void
161 operator () (const sc_signal_in_if<bool> &)
162 {
163 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
164 }
165
166 virtual void
167 bind(sc_port<sc_signal_in_if<bool>, 1> &)
168 {
169 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
170 }
171 void
172 operator () (sc_port<sc_signal_in_if<bool>, 1> &)
173 {
174 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
175 }
176
177 virtual void
178 bind(sc_port<sc_signal_inout_if<bool>, 1> &)
179 {
180 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
181 }
182 void
183 operator () (sc_port<sc_signal_inout_if<bool>, 1> &)
184 {
185 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
186 }
187
188 virtual void
189 end_of_elaboration()
190 {
191 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
192 }
193
194 const bool &
195 read() const
196 {
197 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
198 return *(const bool *)nullptr;
199 }
200 operator const bool& () const
201 {
202 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
203 return *(const bool *)nullptr;
204 }
205
206 const sc_event &
207 default_event() const
208 {
209 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
210 return *(const sc_event *)nullptr;
211 }
212 const sc_event &
213 value_changed_event() const
214 {
215 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
216 return *(const sc_event *)nullptr;
217 }
218 const sc_event &
219 posedge_event() const
220 {
221 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
222 return *(const sc_event *)nullptr;
223 }
224 const sc_event &
225 negedge_event() const
226 {
227 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
228 return *(const sc_event *)nullptr;
229 }
230
231 bool
232 event() const
233 {
234 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
235 return false;
236 }
237 bool
238 posedge() const
239 {
240 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
241 return false;
242 }
243 bool
244 negedge() const
245 {
246 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
247 return false;
248 }
249
250 sc_event_finder &
251 value_changed() const
252 {
253 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
254 return *(sc_event_finder *)nullptr;
255 }
256 sc_event_finder &
257 pos() const
258 {
259 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
260 return *(sc_event_finder *)nullptr;
261 }
262 sc_event_finder &
263 neg() const
264 {
265 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
266 return *(sc_event_finder *)nullptr;
267 }
268
269 virtual const char *kind() const { return "sc_in"; }
270
271 private:
272 // Disabled
273 sc_in(const sc_in<bool> &) : sc_port<sc_signal_in_if<bool>, 1>() {}
274 sc_in<bool> &operator = (const sc_in<bool> &) { return *this; }
275};
276
277template <>
278inline void
279sc_trace<bool>(sc_trace_file *, const sc_in<bool> &, const std::string &)
280{
281 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
282}
283
284template <>
285class sc_in<sc_dt::sc_logic> :
286 public sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>
287{
288 public:
289 sc_in() : sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>() {}
290 explicit sc_in(const char *name) :
291 sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>(name)
292 {}
293 virtual ~sc_in() {}
294
195 virtual void
196 bind(const sc_signal_in_if<bool> &)
197 {
198 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
199 }
200 void
201 operator () (const sc_signal_in_if<bool> &)
202 {
203 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
204 }
205
206 virtual void
207 bind(sc_port<sc_signal_in_if<bool>, 1> &)
208 {
209 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
210 }
211 void
212 operator () (sc_port<sc_signal_in_if<bool>, 1> &)
213 {
214 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
215 }
216
217 virtual void
218 bind(sc_port<sc_signal_inout_if<bool>, 1> &)
219 {
220 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
221 }
222 void
223 operator () (sc_port<sc_signal_inout_if<bool>, 1> &)
224 {
225 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
226 }
227
228 virtual void
229 end_of_elaboration()
230 {
231 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
232 }
233
234 const bool &
235 read() const
236 {
237 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
238 return *(const bool *)nullptr;
239 }
240 operator const bool& () const
241 {
242 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
243 return *(const bool *)nullptr;
244 }
245
246 const sc_event &
247 default_event() const
248 {
249 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
250 return *(const sc_event *)nullptr;
251 }
252 const sc_event &
253 value_changed_event() const
254 {
255 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
256 return *(const sc_event *)nullptr;
257 }
258 const sc_event &
259 posedge_event() const
260 {
261 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
262 return *(const sc_event *)nullptr;
263 }
264 const sc_event &
265 negedge_event() const
266 {
267 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
268 return *(const sc_event *)nullptr;
269 }
270
271 bool
272 event() const
273 {
274 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
275 return false;
276 }
277 bool
278 posedge() const
279 {
280 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
281 return false;
282 }
283 bool
284 negedge() const
285 {
286 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
287 return false;
288 }
289
290 sc_event_finder &
291 value_changed() const
292 {
293 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
294 return *(sc_event_finder *)nullptr;
295 }
296 sc_event_finder &
297 pos() const
298 {
299 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
300 return *(sc_event_finder *)nullptr;
301 }
302 sc_event_finder &
303 neg() const
304 {
305 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
306 return *(sc_event_finder *)nullptr;
307 }
308
309 virtual const char *kind() const { return "sc_in"; }
310
311 private:
312 // Disabled
313 sc_in(const sc_in<bool> &) : sc_port<sc_signal_in_if<bool>, 1>() {}
314 sc_in<bool> &operator = (const sc_in<bool> &) { return *this; }
315};
316
317template <>
318inline void
319sc_trace<bool>(sc_trace_file *, const sc_in<bool> &, const std::string &)
320{
321 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
322}
323
324template <>
325class sc_in<sc_dt::sc_logic> :
326 public sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>
327{
328 public:
329 sc_in() : sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>() {}
330 explicit sc_in(const char *name) :
331 sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>(name)
332 {}
333 virtual ~sc_in() {}
334
335 // Deprecated binding constructors.
336 explicit sc_in(const sc_signal_in_if<sc_dt::sc_logic> &interface) :
337 sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>(interface)
338 {}
339 sc_in(const char *name,
340 const sc_signal_in_if<sc_dt::sc_logic> &interface) :
341 sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>(name, interface)
342 {}
343 explicit sc_in(sc_port_b<sc_signal_in_if<sc_dt::sc_logic> > &parent) :
344 sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>(parent)
345 {}
346 sc_in(const char *name,
347 sc_port_b<sc_signal_in_if<sc_dt::sc_logic> > &parent) :
348 sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>(name, parent)
349 {}
350 explicit sc_in(sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1> &parent) :
351 sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>(parent)
352 {}
353 sc_in(const char *name,
354 sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1> &parent) :
355 sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>(name, parent)
356 {}
357
295 virtual void
296 bind(const sc_signal_in_if<sc_dt::sc_logic> &)
297 {
298 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
299 }
300 void
301 operator () (const sc_signal_in_if<sc_dt::sc_logic> &)
302 {
303 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
304 }
305
306 virtual void
307 bind(sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1> &)
308 {
309 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
310 }
311 void
312 operator () (sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1> &)
313 {
314 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
315 }
316
317 virtual void
318 bind(sc_port<sc_signal_inout_if<sc_dt::sc_logic>, 1> &)
319 {
320 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
321 }
322 void
323 operator () (sc_port<sc_signal_inout_if<sc_dt::sc_logic>, 1> &)
324 {
325 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
326 }
327
328 virtual void
329 end_of_elaboration()
330 {
331 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
332 }
333
334 const sc_dt::sc_logic &
335 read() const
336 {
337 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
338 return *(const sc_dt::sc_logic *)nullptr;
339 }
340 operator const sc_dt::sc_logic& () const
341 {
342 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
343 return *(const sc_dt::sc_logic *)nullptr;
344 }
345
346 const sc_event &
347 default_event() const
348 {
349 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
350 return *(const sc_event *)nullptr;
351 }
352 const sc_event &
353 value_changed_event() const
354 {
355 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
356 return *(const sc_event *)nullptr;
357 }
358 const sc_event &
359 posedge_event() const
360 {
361 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
362 return *(const sc_event *)nullptr;
363 }
364 const sc_event &
365 negedge_event() const
366 {
367 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
368 return *(const sc_event *)nullptr;
369 }
370
371 bool
372 event() const
373 {
374 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
375 return false;
376 }
377 bool
378 posedge() const
379 {
380 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
381 return false;
382 }
383 bool
384 negedge() const
385 {
386 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
387 return false;
388 }
389
390 sc_event_finder &
391 value_changed() const
392 {
393 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
394 return *(sc_event_finder *)nullptr;
395 }
396 sc_event_finder &
397 pos() const
398 {
399 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
400 return *(sc_event_finder *)nullptr;
401 }
402 sc_event_finder &
403 neg() const
404 {
405 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
406 return *(sc_event_finder *)nullptr;
407 }
408
409 virtual const char *kind() const { return "sc_in"; }
410
411 private:
412 // Disabled
413 sc_in(const sc_in<sc_dt::sc_logic> &) :
414 sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>()
415 {}
416 sc_in<sc_dt::sc_logic> &
417 operator = (const sc_in<sc_dt::sc_logic> &)
418 {
419 return *this;
420 }
421};
422
423template <>
424inline void
425sc_trace<sc_dt::sc_logic>(
426 sc_trace_file *, const sc_in<sc_dt::sc_logic> &, const std::string &)
427{
428 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
429}
430
431} // namespace sc_core
432
433#endif //__SYSTEMC_EXT_CHANNEL_SC_IN_HH__
358 virtual void
359 bind(const sc_signal_in_if<sc_dt::sc_logic> &)
360 {
361 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
362 }
363 void
364 operator () (const sc_signal_in_if<sc_dt::sc_logic> &)
365 {
366 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
367 }
368
369 virtual void
370 bind(sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1> &)
371 {
372 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
373 }
374 void
375 operator () (sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1> &)
376 {
377 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
378 }
379
380 virtual void
381 bind(sc_port<sc_signal_inout_if<sc_dt::sc_logic>, 1> &)
382 {
383 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
384 }
385 void
386 operator () (sc_port<sc_signal_inout_if<sc_dt::sc_logic>, 1> &)
387 {
388 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
389 }
390
391 virtual void
392 end_of_elaboration()
393 {
394 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
395 }
396
397 const sc_dt::sc_logic &
398 read() const
399 {
400 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
401 return *(const sc_dt::sc_logic *)nullptr;
402 }
403 operator const sc_dt::sc_logic& () const
404 {
405 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
406 return *(const sc_dt::sc_logic *)nullptr;
407 }
408
409 const sc_event &
410 default_event() const
411 {
412 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
413 return *(const sc_event *)nullptr;
414 }
415 const sc_event &
416 value_changed_event() const
417 {
418 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
419 return *(const sc_event *)nullptr;
420 }
421 const sc_event &
422 posedge_event() const
423 {
424 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
425 return *(const sc_event *)nullptr;
426 }
427 const sc_event &
428 negedge_event() const
429 {
430 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
431 return *(const sc_event *)nullptr;
432 }
433
434 bool
435 event() const
436 {
437 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
438 return false;
439 }
440 bool
441 posedge() const
442 {
443 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
444 return false;
445 }
446 bool
447 negedge() const
448 {
449 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
450 return false;
451 }
452
453 sc_event_finder &
454 value_changed() const
455 {
456 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
457 return *(sc_event_finder *)nullptr;
458 }
459 sc_event_finder &
460 pos() const
461 {
462 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
463 return *(sc_event_finder *)nullptr;
464 }
465 sc_event_finder &
466 neg() const
467 {
468 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
469 return *(sc_event_finder *)nullptr;
470 }
471
472 virtual const char *kind() const { return "sc_in"; }
473
474 private:
475 // Disabled
476 sc_in(const sc_in<sc_dt::sc_logic> &) :
477 sc_port<sc_signal_in_if<sc_dt::sc_logic>, 1>()
478 {}
479 sc_in<sc_dt::sc_logic> &
480 operator = (const sc_in<sc_dt::sc_logic> &)
481 {
482 return *this;
483 }
484};
485
486template <>
487inline void
488sc_trace<sc_dt::sc_logic>(
489 sc_trace_file *, const sc_in<sc_dt::sc_logic> &, const std::string &)
490{
491 sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
492}
493
494} // namespace sc_core
495
496#endif //__SYSTEMC_EXT_CHANNEL_SC_IN_HH__