-
-
Notifications
You must be signed in to change notification settings - Fork 10.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Raising compiler minimum requirement to use some C++11 features? #4537
Comments
No objection! You could also bump it to C++14 (a lot of |
There's ABI compatibility to consider, but from a quick glance it doesn't seem like there's something relevant to ImGui there: https://gcc.gnu.org/wiki/Cxx11AbiCompatibility Also, not sure how strong that argument is, but checking the platforms I build my stuff for it seems like Maemo 5 would be affected as that has GCC 4.2.1 in its SDK and so far ImGui worked fine there. I'd probably be fine with disabling ImGui support on that platform though. Bumping to C++14 would be more problematic. |
I would actually consider going past C++11 as well, frankly to C++17 (gives you structured bindings, and even some optimization opportunities like guaranteed copy elision, etc.). Given that you aren't using any STL structures (that may have broken ABI compatibility), it still doesn't restrict someone from compiling their own code with a lower standard version but using your interfaces. (note: Amazon employee, but this is a personal opinion) |
C'mon, even when it was produced N900 wasn't very popular. Maemo was abandoned 10 years ago... Maybe it would be the best is to create another official release pre-update to C++11 or above. And then mark it clearly so people who use it on obsolete platforms could just update to that version. |
I'm part of a team that maintains software for some widely-deployed CNC machines. The controllers of many of those machines run on Windows CE/ARM, and the newest compiler for that platform is VS2008. We use ImGui for a debug interface. It is unlikely that those machines disappear in the next 10 years, since they have an average lifetime of >20 years. For me it would be fine to stick to an older version of ImGui though. I think it would be helpful to document the release where support was dropped. |
For me, personally, C++11 is fine. I am working with the Unreal Engine, which itself uses C++11, so anything past that wouldn't work out for me - and newer C++ versions didn't add anything useful anyway imo. |
This is not true. Unreal Engine has used C++14 for a while with an option to enable 17. From my memory of the period where I worked with the UE codebase, plenty of features in post-C++11 standards were used (e.g. capture initialization). Also, bear in mind that internal usage of C++17 doesn't preclude usage of the library from code that is C++14 or C++11 even. |
Thank you for your feedback! Likely I am going to mark 1.85 as "last version supporting VS2008/VS2010" and then upgrade afterwards. I can't provide long term maintenance of old tech (especially as none of the corporate users who may be affected are contributing to the project). It's just healthier moving onward and I've confirmed it with specific users aside of this thread. |
It would be great to have constexpr constructors for ImVec2 and ImVec4. |
Note that we can support |
VC2008 is need to modify some code because the stdint.h is not available. And the uint32_t need to change to unsigned int. Line 1654 in 677fe33
Lines 1672 to 1675 in 677fe33
Otherwise, I played the older Visual C++ Compiler 2008 for RISC, I compiled imgui is succeed.
|
@metarutaiga You should use msinttypes: https://github.com/chemeris/msinttypes when using VS2008. |
Not sure if C++11 is adapted yet or it's out of plans for now (didn't find any note on the release notes of v1.85), but I just wanted to ask for making the enums scoped when that happens (ie. |
…ditions) (#4537) Possible since we are now C++11 + fix warning in GetNavInputAmount().
Hey, I think you guys have some out-of-date docs that say Dear IMGUI doesn't require C++11 on https://imgui-test.readthedocs.io/en/latest/:
I'm not sure what the source is for this site, I think it used to be based on the README but it's out of date? |
It’s not ours and I don’t know who made it.
It’s one among several attempts from people to run a doc generating script and then lose interest in it. Would be good to find the owner.
|
…ls to be named in debuggers. (ocornut#4921, ocornut#4537) May affect binding generators.
… + fix additional warnings.
FYI i switched various loops to use range-based for with 82d177c |
… C++11. Kept redirection define. (#4537)
I am considering upping the minimum compiler requirements to use some C++ features.
Right now I'm mostly interested in using range-based for loops (
for (SomeType* node : containers) {}
)The minimum requirement would be raised to:
You can upvote this and I do expect a majority of people to be ok with this, but mostly I am interested in seeing if there are any strong argument AGAINST this.
(PS: we will keep avoiding the use of any C++ standard library header file. Only looking to use C++ core language feature)
The text was updated successfully, but these errors were encountered: