⸻ Ban DHMO 🇦🇺 ⸻@aussie.zone to Programmer Humor@lemmy.mlEnglish · 11 months agoThe C++ learning processaussie.zoneexternal-linkmessage-square97linkfedilinkarrow-up1287arrow-down15file-text
arrow-up1282arrow-down1external-linkThe C++ learning processaussie.zone⸻ Ban DHMO 🇦🇺 ⸻@aussie.zone to Programmer Humor@lemmy.mlEnglish · 11 months agomessage-square97linkfedilinkfile-text
minus-squareSpaceNoodle@lemmy.worldlinkfedilinkarrow-up0·11 months agoHow do you implement an interface in C++ without an abstract class?
minus-squaremagic_lobster_party@fedia.iolinkfedilinkarrow-up0·11 months agoAsk Bjarne to add interfaces enough many times until he gives in. On a more serious note, I’m not exactly sure what the best C++ practice is. I guess you just have to live with abstract classes if you really want interfaces.
minus-squareSpaceNoodle@lemmy.worldlinkfedilinkarrow-up1·11 months agoAn abstract class with no member variables serves the same purpose in C++.
How do you implement an interface in C++ without an abstract class?
Ask Bjarne to add interfaces enough many times until he gives in.
On a more serious note, I’m not exactly sure what the best C++ practice is. I guess you just have to live with abstract classes if you really want interfaces.
An abstract class with no member variables serves the same purpose in C++.