C++: TDM-GCC: minimising includes

Discuss other programming languages besides AutoHotkey
User avatar
jeeswg
Posts: 5555
Joined: 19 Dec 2016, 01:58
Location: UK

C++: TDM-GCC: minimising includes

14 Dec 2018, 16:40

- I was wondering about any issues relating to minimising the number of included files in C++ code, for when compiling machine code.
- I noticed that min is not a built-in function, so I've replaced:
min(a, b)
with:
a < b ? a : b
The same applies to max. I wondered if other people add the include, or change the code, or use macros even, and whether there are other little issues like this. Thanks.
- I believe the include for the max/min functions is #include "windows.h"
User avatar
nnnik
Posts: 3685
Joined: 30 Sep 2013, 01:01
Location: Germany

Re: C++: TDM-GCC: minimising includes

14 Dec 2018, 17:22

Yes there are many issues. I have summarized a few of the problems in my MCode tutorial.
Recommends AHK Studio

Return to “Other Programming Languages”

Who is online

Users browsing this forum: No registered users and 3 guests