Jump to content

Can tell why this program not running?


Ganesan R

Recommended Posts

Dear Sir,

 

I am new to System C. The problem is number of forums offering support to system c problems are few. As such I want help in understanding why this elementary program is not compiling. It returns  error C2039: 'con_arrayfifo' : is not a member of 'arrayfifo'.

 

Now the program:

 

#include <systemc.h>
SC_MODULE(arrayfifo)
{
    
    SC_CTOR(arrayfifo) {
        SC_METHOD(con_arrayfifo);


    }


};

void arrayfifo::con_arrayfifo (void) {

    //delcare the fifo
    //sc_fifo<int> rowfifo[n];

}


int sc_main(int , char*[] )
{
    int m,n;
    cout << "Sadguru Jai Jai \n";
    cout << "Enter the value of m: \t";
    cin >> m;
    cout << "Enter the value of n: \t";
    cin >> n;
    cout << m <<"\t" << n <<"\n";
    arrayfifo arrayfifo1("arr_fifo");
    //con_arrayfifo(m,n);
    //sc_fifo<int> rowfifo[n];
    return 0;
}

 

The commented lines are intentional to find out why this program is not compiling.

Thanks in advance for your patience and reply back.

 

R. Ganesan

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...