mirror of
https://github.com/godotengine/godot.git
synced 2025-10-19 16:03:29 +00:00
Thirdparty: Harmonize patches to document downstream changes
This commit is contained in:
parent
0d14ae58b0
commit
91907a89f7
141 changed files with 1274 additions and 3849 deletions
38
thirdparty/clipper2/patches/0001-disable-exceptions.patch
vendored
Normal file
38
thirdparty/clipper2/patches/0001-disable-exceptions.patch
vendored
Normal file
|
@ -0,0 +1,38 @@
|
|||
diff --git a/thirdparty/clipper2/include/clipper2/clipper.core.h b/thirdparty/clipper2/include/clipper2/clipper.core.h
|
||||
index 925c04685e..67dd731af6 100644
|
||||
--- a/thirdparty/clipper2/include/clipper2/clipper.core.h
|
||||
+++ b/thirdparty/clipper2/include/clipper2/clipper.core.h
|
||||
@@ -22,6 +22,8 @@
|
||||
#include <optional>
|
||||
#include "clipper2/clipper.version.h"
|
||||
|
||||
+#define CLIPPER2_THROW(exception) std::abort()
|
||||
+
|
||||
namespace Clipper2Lib
|
||||
{
|
||||
|
||||
@@ -79,18 +81,18 @@ namespace Clipper2Lib
|
||||
switch (error_code)
|
||||
{
|
||||
case precision_error_i:
|
||||
- throw Clipper2Exception(precision_error);
|
||||
+ CLIPPER2_THROW(Clipper2Exception(precision_error));
|
||||
case scale_error_i:
|
||||
- throw Clipper2Exception(scale_error);
|
||||
+ CLIPPER2_THROW(Clipper2Exception(scale_error));
|
||||
case non_pair_error_i:
|
||||
- throw Clipper2Exception(non_pair_error);
|
||||
+ CLIPPER2_THROW(Clipper2Exception(non_pair_error));
|
||||
case undefined_error_i:
|
||||
- throw Clipper2Exception(undefined_error);
|
||||
+ CLIPPER2_THROW(Clipper2Exception(undefined_error));
|
||||
case range_error_i:
|
||||
- throw Clipper2Exception(range_error);
|
||||
+ CLIPPER2_THROW(Clipper2Exception(range_error));
|
||||
}
|
||||
#else
|
||||
- ++error_code; // only to stop compiler warning
|
||||
+ if(error_code) {}; // only to stop compiler 'parameter not used' warning
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue