在c中使用虚函数

在c中使用虚函数

Hi All,How to implement virtual concept in c.TIAMohan 解决方案Probably by writing a C++ compiler in C.C doesn''t have virtual functions. What problem are you trying tosolve?--Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>San Diego Supercomputer Center <*> <http://users.sdsc.edu/~kst>We must do something. This is something. Therefore, we must do this.Assuming that by "virtual" you mean something along the lines of howthat word is used in another language which resembles, but mostemphatically is not the same as, C...Have, as the first member of some struct, a pointer to another structconsisting of members of pointer-to-function types.Tell us what YOU think this means, and why you want to do it in C.Brian 这篇关于在c中使用虚函数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
08-20 03:06