4 ms·
My early C code would have been awfully slow without them. We needed enums and good inlining before we could ditch (most) macros. When did Zorland/Zortech C b
by peterfirefly 1y ago
My early C code would have been awfully slow without them. We needed enums and good inlining before we could ditch (most) macros. When did Zorland/Zortech C become good enough?
There are still a few special cases where macros are useful, such as the multiple #include trick where a macro #defined before the #include determines what the macro invocations in the include file does -- really helpful for building certain kinds of tables.
- WalterBright 1y agoZortech had an inliner even before it was Zortech. The #include trick is called the "X Macro". I used it extensively, and eventually just removed it.
- peterfirefly 1y agoWas it reliable enough? (I have never played with it -- I saw the ads in Byte but I never met anybody who had tried it. It seemed so ridiculously cheap that I felt it had to be a scam ;) )
- WalterBright 1y agoIt was frequently better and faster than the others. Mine was the first (for the PC) to add data flow analysis.