Forum: GNU Radio gr_foo_sptr (vs) gr_foo

371d411c739f4bcedc3ba4ee0816ab5b?d=identicon&s=25 Naceur El Ouni (naeo)
on 2013-08-20 23:16
(Received via mailing list)
Hello,

I did spent time working on GNU radio C++ API,
And I was stuck debugging in some point where I need to get the gr_foo
to
retrieve the values of its members whereas I already instantiated
gr_foo_sptr instead.
Is there a way to fix this issue.

Example: I already instantiated gr_msg_queue_sptr,
gr_message_source_sptr
...

              and I got ‘gr_msg_queue_sptr’ has no member named
‘empty_p’
                           ‘gr_message_source_sptr’ has no member named
‘msgq’

Do I have to get rid of sptrs and instantiate gr_msg_queue and
gr_message_source instead
Or I may get around this.

Regards,



--
View this message in context:
http://gnuradio.4.n7.nabble.com/gr-foo-sptr-vs-gr-...
Sent from the GnuRadio mailing list archive at Nabble.com.
C539637020fd56193dd6daec746c4a84?d=identicon&s=25 Tom Rondeau (Guest)
on 2013-08-20 23:24
(Received via mailing list)
On Tue, Aug 20, 2013 at 5:15 PM, NaceurElOuni <naceuramine@gmail.com>
wrote:
>
>               and I got gr_msg_queue_sptr has no member named empty_p
>                            gr_message_source_sptr has no member named
> msgq
>
> Do I have to get rid of sptrs and instantiate gr_msg_queue and
> gr_message_source instead
> Or I may get around this.
>
> Regards,

Take a look at the Boost shared pointer documentation:
http://www.boost.org/doc/libs/1_54_0/libs/smart_pt...

You'll want to either use the '->' operator or you can get a pointer
to the original object using the get() function.

--
Tom
Visit us at GRCon13 Oct. 1 - 4
http://www.trondeau.com/grcon13
This topic is locked and can not be replied to.