diff options
author | Loïc Blot <nerzhul@users.noreply.github.com> | 2017-10-09 11:32:06 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-10-09 11:32:06 +0200 |
commit | 17016090e38cc44e58517129278c28dd7943b4cc (patch) | |
tree | a0ba6d0628f333c28b2e584cc6eb6d1ef413aa07 /src | |
parent | e6e5fa3bf8853f149fdef16b39af3981097176a4 (diff) | |
download | minetest-17016090e38cc44e58517129278c28dd7943b4cc.tar.gz minetest-17016090e38cc44e58517129278c28dd7943b4cc.tar.bz2 minetest-17016090e38cc44e58517129278c28dd7943b4cc.zip |
Travis: Update clang from 4.0 to 5.0 (#6467)
* Update clang from 4.0 to 5.0
Diffstat (limited to 'src')
-rw-r--r-- | src/chatmessage.h | 5 | ||||
-rw-r--r-- | src/client/renderingengine.cpp | 29 | ||||
-rw-r--r-- | src/environment.h | 4 | ||||
-rw-r--r-- | src/httpfetch.h | 4 | ||||
-rw-r--r-- | src/network/peerhandler.h | 4 | ||||
-rw-r--r-- | src/profiler.cpp | 5 | ||||
-rw-r--r-- | src/sound.h | 5 | ||||
-rw-r--r-- | src/wieldmesh.h | 4 |
8 files changed, 38 insertions, 22 deletions
diff --git a/src/chatmessage.h b/src/chatmessage.h index 06c5ea664..f4ecd631d 100644 --- a/src/chatmessage.h +++ b/src/chatmessage.h @@ -36,8 +36,9 @@ struct ChatMessage ChatMessage(const std::wstring &m = L"") : message(m) {} ChatMessage(ChatMessageType t, const std::wstring &m, const std::wstring &s = L"", - std::time_t ts = std::time(0)) - : type(t), message(m), sender(s), timestamp(ts) + std::time_t ts = std::time(0)) : + type(t), + message(m), sender(s), timestamp(ts) { } diff --git a/src/client/renderingengine.cpp b/src/client/renderingengine.cpp index 705871160..b3abd824d 100644 --- a/src/client/renderingengine.cpp +++ b/src/client/renderingengine.cpp @@ -93,10 +93,11 @@ RenderingEngine::RenderingEngine(IEventReceiver *receiver) params.HighPrecisionFPU = g_settings->getBool("high_precision_fpu"); params.ZBufferBits = 24; #ifdef __ANDROID__ + // clang-format off params.PrivateData = porting::app_global; - params.OGLES2ShaderPath = std::string( - porting::path_user + DIR_DELIM + "media" + DIR_DELIM + "Shaders" + - DIR_DELIM).c_str(); + params.OGLES2ShaderPath = std::string(porting::path_user + DIR_DELIM + "media" + + DIR_DELIM + "Shaders" + DIR_DELIM).c_str(); + // clang-format on #endif m_device = createDeviceEx(params); @@ -233,7 +234,7 @@ bool RenderingEngine::setWindowIcon() const HICON hicon = LoadIcon(GetModuleHandle(NULL), MAKEINTRESOURCE(130) // The ID of the ICON defined in // winresource.rc - ); + ); if (hicon) { SendMessage(hWnd, WM_SETICON, ICON_BIG, reinterpret_cast<LPARAM>(hicon)); @@ -997,8 +998,14 @@ void RenderingEngine::draw_plain(Camera *camera, bool show_hud, Hud *hud, const char *RenderingEngine::getVideoDriverName(irr::video::E_DRIVER_TYPE type) { static const char *driver_ids[] = { - "null", "software", "burningsvideo", "direct3d8", "direct3d9", - "opengl", "ogles1", "ogles2", + "null", + "software", + "burningsvideo", + "direct3d8", + "direct3d9", + "opengl", + "ogles1", + "ogles2", }; return driver_ids[type]; @@ -1007,8 +1014,14 @@ const char *RenderingEngine::getVideoDriverName(irr::video::E_DRIVER_TYPE type) const char *RenderingEngine::getVideoDriverFriendlyName(irr::video::E_DRIVER_TYPE type) { static const char *driver_names[] = { - "NULL Driver", "Software Renderer", "Burning's Video", - "Direct3D 8", "Direct3D 9", "OpenGL", "OpenGL ES1", "OpenGL ES2", + "NULL Driver", + "Software Renderer", + "Burning's Video", + "Direct3D 8", + "Direct3D 9", + "OpenGL", + "OpenGL ES1", + "OpenGL ES2", }; return driver_names[type]; diff --git a/src/environment.h b/src/environment.h index 1a1debcb9..f568ba228 100644 --- a/src/environment.h +++ b/src/environment.h @@ -106,7 +106,7 @@ protected: /* * Below: values managed by m_time_lock - */ + */ // Time of day in milli-hours (0-23999), determines day and night u32 m_time_of_day; // Time of day in 0...1 @@ -122,7 +122,7 @@ protected: std::atomic<u32> m_day_count; /* * Above: values managed by m_time_lock - */ + */ /* TODO: Add a callback function so these can be updated when a setting * changes. At this point in time it doesn't matter (e.g. /set diff --git a/src/httpfetch.h b/src/httpfetch.h index db43e3a4b..ae8b5afb5 100644 --- a/src/httpfetch.h +++ b/src/httpfetch.h @@ -78,8 +78,8 @@ struct HTTPFetchResult HTTPFetchResult() = default; - HTTPFetchResult(const HTTPFetchRequest &fetch_request) - : caller(fetch_request.caller), request_id(fetch_request.request_id) + HTTPFetchResult(const HTTPFetchRequest &fetch_request) : + caller(fetch_request.caller), request_id(fetch_request.request_id) { } }; diff --git a/src/network/peerhandler.h b/src/network/peerhandler.h index 70e416e90..208ab801e 100644 --- a/src/network/peerhandler.h +++ b/src/network/peerhandler.h @@ -63,8 +63,8 @@ enum PeerChangeType : u8 struct PeerChange { - PeerChange(PeerChangeType t, session_t _peer_id, bool _timeout) - : type(t), peer_id(_peer_id), timeout(_timeout) + PeerChange(PeerChangeType t, session_t _peer_id, bool _timeout) : + type(t), peer_id(_peer_id), timeout(_timeout) { } PeerChange() = delete; diff --git a/src/profiler.cpp b/src/profiler.cpp index 738a5b7e3..f8d4fc181 100644 --- a/src/profiler.cpp +++ b/src/profiler.cpp @@ -22,8 +22,9 @@ with this program; if not, write to the Free Software Foundation, Inc., static Profiler main_profiler; Profiler *g_profiler = &main_profiler; ScopeProfiler::ScopeProfiler( - Profiler *profiler, const std::string &name, ScopeProfilerType type) - : m_profiler(profiler), m_name(name), m_type(type) + Profiler *profiler, const std::string &name, ScopeProfilerType type) : + m_profiler(profiler), + m_name(name), m_type(type) { if (m_profiler) m_timer = new TimeTaker(m_name); diff --git a/src/sound.h b/src/sound.h index f52746369..0ad34e5cd 100644 --- a/src/sound.h +++ b/src/sound.h @@ -34,8 +34,9 @@ public: struct SimpleSoundSpec { SimpleSoundSpec(const std::string &name = "", float gain = 1.0f, - float fade = 0.0f, float pitch = 1.0f) - : name(name), gain(gain), fade(fade), pitch(pitch) + float fade = 0.0f, float pitch = 1.0f) : + name(name), + gain(gain), fade(fade), pitch(pitch) { } diff --git a/src/wieldmesh.h b/src/wieldmesh.h index 23e3abf29..87b8a8efe 100644 --- a/src/wieldmesh.h +++ b/src/wieldmesh.h @@ -46,8 +46,8 @@ struct ItemPartColor ItemPartColor() = default; - ItemPartColor(bool override, video::SColor color) - : override_base(override), color(color) + ItemPartColor(bool override, video::SColor color) : + override_base(override), color(color) { } }; |