Something strange happens: I did not change any part of my ns3 C ++ code, and starting compilation is an error:
[ 815/1681] cxx: scratch/initial-scenario.cc -> build/scratch/initial-scenario.cc.1.o
In file included from ../scratch/initial-scenario.cc:3:
In file included from ./ns3/core-module.h:18:
In file included from ./ns3/calendar-scheduler.h:24:
In file included from ./ns3/scheduler.h:25:
In file included from ./ns3/object.h:29:
In file included from ./ns3/object-base.h:23:
In file included from ./ns3/type-id.h:25:
In file included from ./ns3/trace-source-accessor.h:24:
./ns3/callback.h:1244:54: error: expression with side effects will be evaluated despite being used as an operand to 'typeid' [-Werror,-Wpotentially-evaluated-expression]
"got=" << Demangle ( typeid (*other).name () ) << std::endl <<
^
./ns3/fatal-error.h:98:32: note: expanded from macro 'NS_FATAL_ERROR'
std::cerr << "msg=\"" << msg << "\", "; \
^
1 error generated.
I do not understand why this error came out. It is strange that I work with two identical codes in two different directories, and an error appears in both cases, but I did not change anything. Could it be a compiler problem? Any suggestion?
source
share