How arrays work

I wrote this array under the
interp_ff_impl::work(int noutput_items,
gr_vector_const_void_star &input_items,
gr_vector_void_star &output_items)

int f[m];
I could not initialise by
int f[m]={0};
block is also not work can we write array like the above in gnuradio c++
code

On Fri, Dec 27, 2013 at 4:43 AM, MHMND Herath [email protected] wrote:

    I wrote this array under the

interp_ff_impl::work(int noutput_items,
gr_vector_const_void_star &input_items,
gr_vector_void_star &output_items)

int f[m];
I could not initialise by
int f[m]={0};
block is also not work can we write array like the above in gnuradio c++ code

This is really a C++ question and not a GNU Radio question. But,
anyways, without more information about ‘m’, I would say no, generally
this is not acceptable C++ code since you’re trying to create an array
with a variable as the size of the array.

But look to the C++ forums and reask the question there if you cannot
find it.

Tom

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs