如何用 C 编写面向对象的代码?
问题描述:
用 C 编写面向对象的代码有哪些方法?尤其是关于多态性.
What are some ways to write object-oriented code in C? Especially with regard to polymorphism.
另见此堆栈溢出问题C 中的面向对象.
See also this Stack Overflow question Object-orientation in C.
答
是的.事实上,Axel Schreiner 提供了他的书ANSI 中的面向对象编程-C"是免费的,它非常彻底地涵盖了该主题.
Yes. In fact Axel Schreiner provides his book "Object-oriented Programming in ANSI-C" for free which covers the subject quite thoroughly.