Error in changing of root version from 6 to 5

Dear All,
I’m beginner in root.
I had written a c++ code to our analysis using root-6-18-04. Everything works well. For some special reasons, I force to change root version to 5-34-3. When I try to run again my code, it gives following error

Error: Can’t call basic_ifstream<char,char_traits >::basic_ifstream<char,char_traits >(filename) in current scope ttww_model_analysis_3lepton_same_sign_fitting.C:990:
Possible candidates are…
public: basic_ifstream<char,char_traits > basic_ifstream<char,char_traits >::basic_ifstream<char,char_traits >(void);
public: basic_ifstream<char,char_traits > basic_ifstream<char,char_traits >::basic_ifstream<char,char_traits >(const char* s,ios_base::openmode mode=ios_base::in);
*** Interpreter error recovered ***

It should be mentioned here, in a part of our code, i use ifstream function to read a piece of text file. Also below line gives above error.
that part including ifstream is as follows
string filename="/data/ttwwmodel/ttww_yt_reweighting_original.lhe";

ifstream myfile (filename);

Would you please clearly help me to solve this problem?

Bests,

Mahdi

You can try to compile the code with ACLiC.

Thanks a lot for you answer. But as I already told, I’m beginner in root and c++.
Would you please write linux commands that are needed to compile my code by ACLiC?
Should I install this compiler separately?

All the Bests,

Mahdi

What is the set of commands that leads to the error you mentioned?

To use ACLiC, if you are doing

root [] .L myscript.C

do

root [] .L myscript.C+

Thanks again.
But nothing changed.

The next step is to hide from CINT the offending functions, using

#ifndef __CINT__

Cheers,
Philippe.