r/C_Programming • u/Gullible_Ostrich_370 • Jul 17 '26
C with classes
I'm curious to know: who uses some C++ features when coding in C? And what feature(s) are you using?
29
Upvotes
r/C_Programming • u/Gullible_Ostrich_370 • Jul 17 '26
I'm curious to know: who uses some C++ features when coding in C? And what feature(s) are you using?
View all comments
1
u/Conscious_Buddy1338 Jul 22 '26
For me it was interesting to know that you can use some OOP stuff in C. Instead of methods from C++, you can declare the pointer to function in C structure. And you can call the functions pointed by this pointer via syntax like you call the method of class in C++.