mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-03 03:53:56 -07:00
Clang-format (#3028)
* 1/3 Add .clang-format file and travis compilation check * 2/3 Run clang-format * 3/3 Fix compilation problems due to include reordering * 3bis/3 AfterControlStatement: false
This commit is contained in:
parent
8dbdd24c8e
commit
b29bd9e070
272 changed files with 13378 additions and 9535 deletions
|
|
@ -1,12 +1,13 @@
|
|||
#ifndef MSVC_ROUND_FIX
|
||||
#define MSVC_ROUND_FIX
|
||||
/**
|
||||
* This helper function exists only because MS VC++ 2010 does not support round() in
|
||||
* This helper function exists only because MS VC++ 2010 does not support round() in
|
||||
* <cmath>. round() works with g++ and clang++ but is formally a C++11 extension.
|
||||
* So this file exists for MS VC++ only.
|
||||
*/
|
||||
inline double round(double val) {
|
||||
return floor(val + 0.5);
|
||||
inline double round(double val)
|
||||
{
|
||||
return floor(val + 0.5);
|
||||
}
|
||||
|
||||
#endif /* MSVC_ROUND_FIX */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue