aboutsummaryrefslogtreecommitdiff
path: root/CruUI/base.h
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2018-09-02 15:02:51 +0800
committercrupest <crupest@outlook.com>2018-09-02 15:02:51 +0800
commitf3d62dec00748a306af658b87bffc54e4949a4f4 (patch)
tree5b5c81605838595b16eb868cb0d216f37bac0500 /CruUI/base.h
parentd0fe3828bdda050316a331cefecec88987963b3e (diff)
downloadcru-f3d62dec00748a306af658b87bffc54e4949a4f4.tar.gz
cru-f3d62dec00748a306af658b87bffc54e4949a4f4.tar.bz2
cru-f3d62dec00748a306af658b87bffc54e4949a4f4.zip
...
Diffstat (limited to 'CruUI/base.h')
-rw-r--r--CruUI/base.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/CruUI/base.h b/CruUI/base.h
index 0d401a3a..83d1968c 100644
--- a/CruUI/base.h
+++ b/CruUI/base.h
@@ -1,10 +1,15 @@
#pragma once
+// ReSharper disable once CppUnusedIncludeDirective
#include "global_macros.h"
+
#include <folly/String.h>
#include <folly/Function.h>
+#include <stdexcept>
+
+
namespace cru
{
enum class FlowControl
@@ -39,4 +44,9 @@ namespace cru
{
virtual ~Interface() = default;
};
+
+ [[noreturn]] inline void UnreachableCode()
+ {
+ throw std::logic_error("Unreachable code.");
+ }
}