MegaGlest / megaglest-source

MegaGlest real-time strategy game engine (cross-platform, 3-d)
http://megaglest.org/
344 stars 89 forks source link

warning: ‘throw’ will always call ‘terminate’ #235

Open Rampoina opened 1 year ago

Rampoina commented 1 year ago

The compilation throws this warning:

/mg-rampoina/source/glest_game/graphics/renderer.cpp: In destructor ‘virtual Glest::Game::Renderer::~Renderer()’:
/mg-rampoina/source/glest_game/graphics/renderer.cpp:353:17: warning: ‘throw’ will always call ‘terminate’ [-Wterminate]
  353 |                 throw megaglest_runtime_error(szBuf);
      |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/mg-rampoina/source/glest_game/graphics/renderer.cpp:353:17: note: in C++11 destructors default to ‘noexcept’

https://github.com/MegaGlest/megaglest-source/blob/develop/source/glest_game/graphics/renderer.cpp#L353