Sounds like you have the class method FATTopology::update() declared, which is hiding your definition of update outside the class, at the top or bottom of the file. If you want to use the class method, do what the error message says:Simulator::Schedule (Seconds (5), &FATTopology::update, ipv41, ipv4ifIndex1);If you want the free function, trySimulator::Schedule (Seconds (5), &::update, ipv41, ipv4ifIndex1);Peter
On Wednesday, November 27, 2013 12:48:03 AM UTC-8, feroz...@gmail.com wrote:
Simulator::Schedule (Seconds (5), &update,ipv41, ipv4ifIndex1); //ipv41 is a pointer to a node, and ipv4ifindex1 is an interface of it which has failed
../scratch/now.cc: In member function ‘void FATTopology::TestOnOffM()’:
../scratch/now.cc:605: error: ISO C++ forbids taking the address of an unqualified or parenthesized non-static member function to form a pointer to member function. Say ‘&FATTopology::update’
In file included from ./ns3/core-module.h:42,
from ../scratch/now.cc:57:
./ns3/make-event.h: In member function ‘void ns3::MakeEvent(MEM, OBJ, T1)::EventMemberImpl1::Notify() [with MEM = void (FATTopology::*)(ns3::Ptr<ns3::Ipv4>, uint32_t), OBJ = ns3::Ptr<ns3::Ipv4>, T1 = unsigned int]’:
../scratch/now.cc:942: instantiated from here
./ns3/make-event.h:124: error: pointer to member type ‘void (FATTopology::)(ns3::Ptr<ns3::Ipv4>, uint32_t)’ incompatible with object type ‘ns3::Ipv4’
*if i try to include it outside the class at the end to get rid of building errors, i still get the above errors,
What should i try?
--
You received this message because you are subscribed to a topic in the Google Groups "ns-3-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/ns-3-users/qzgPr0kKY3U/unsubscribe.
To unsubscribe from this group and all its topics, send an email to ns-3-users+...@googlegroups.com.
To post to this group, send email to ns-3-...@googlegroups.com.
Visit this group at http://groups.google.com/group/ns-3-users.
For more options, visit https://groups.google.com/groups/opt_out.