Why seem interrupt handlers as member functions to be impossible?

Answer Posted / rohit sah

Interrupt handlers as member functions _are_ possible. But they must be static member functions. Static member functions don't make use of the implicit 'this' pointer required by normal member functions. The caller of the interrupt handler doesn't know anything about objects and 'this' pointers, so it can't pass a value of such a pointer.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

If you don’t declare a return value, what type of return value is assumed?

542


What is const pointer and const reference?

593


Write a C/C++ program that connects to a MySQL server and checks if the InnoDB plug-in is installed on it. If so, your program should print the maximum number of concurrent threads that the InnoDB plug-in can create

2070


Why the usage of pointers in C++ is not recommended ?

899


What is srand c++?

579






What is stoi in c++?

700


What do you mean by ‘void’ return type?

606


Which programming language should I learn first?

579


Is c++ vector a linked list?

551


Explain 'this' pointer and what would happen if a pointer is deleted twice?

604


How do pointers work?

703


What are keywords in c++?

600


Where do I find the current c or c++ standard documents?

583


What do you mean by late binding?

617


What is a local reference?

671