View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0001535 | FreeCAD | Bug | public | 2014-05-07 18:46 | 2014-05-08 15:58 |
Reporter | mdinger | Assigned To | wmayer | ||
Priority | normal | Severity | minor | Reproducibility | have not tried |
Status | closed | Resolution | fixed | ||
OS | windows | ||||
Product Version | trunk | ||||
Summary | 0001535: Remove conflict between min/max macros and std::min/max | ||||
Description | windows.h defines a macro for min and max. This conflicts with std::min and std::max. The conflict is seen here where Qt Creator points out that this line is using a macro (when it shouldn't be). https://github.com/FreeCAD/FreeCAD_sf_master/blob/master/src/Mod/Sketcher/Gui/CommandCreateGeo.cpp#L848 Solution here: http://stackoverflow.com/questions/5004858/stdmin-gives-error Doesn't seem to give errors but Qt Creator notes it is an error. Fix here: https://github.com/mdinger/FreeCAD_sf_master/compare/min_max_macro_conflict I'm building but I'll probably request merge if no problems. | ||||
Tags | No tags attached. | ||||
FreeCAD Information | |||||
|
Do you get a build error or what is the actual problem? |
|
No, not a build error but Qt Creator's syntax highlighting marks it as red. Go here: 1. Tools->C++->Inspect C++ Code Model to go to C++ Code Model Inspector 2. Snapshots and Documents tab -> Select `Sketcher\Gui\CommandCreateGeo.cpp` 3. Click `Diagnostic Messages` tab at the bottom Among the list of warnings is an error. My fix is to fix this error. |
|
Granted, I'm not actually sure if this is a big problem but it does seem ambiguous to me once Qt Creator pointed it out. I'm not sure why there isn't a build error since the stackoverflow link is showing one for him. |
|
Builds and runs for both Qt Creator and VS for me. I should think it'd be good to merge if you think it's worth pulling in. |
Date Modified | Username | Field | Change |
---|---|---|---|
2014-05-07 18:46 | mdinger | New Issue | |
2014-05-07 20:07 | wmayer | Note Added: 0004636 | |
2014-05-07 20:31 | mdinger | Note Added: 0004637 | |
2014-05-07 20:44 | mdinger | Note Added: 0004638 | |
2014-05-07 21:16 | mdinger | Note Added: 0004639 | |
2014-05-08 15:58 | wmayer | Changeset attached | => FreeCAD Master master 6d17bbb7 |
2014-05-08 15:58 | wmayer | Assigned To | => wmayer |
2014-05-08 15:58 | wmayer | Status | new => closed |
2014-05-08 15:58 | wmayer | Resolution | open => fixed |