Skip to content

Commit ff07ea7

Browse files
committed
Updated to the latest version of flatbuffers.
1 parent f731fc4 commit ff07ea7

File tree

3 files changed

+16
-13
lines changed

3 files changed

+16
-13
lines changed

Shared/external/flatbuffers/base.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -139,8 +139,8 @@
139139
#endif // !defined(FLATBUFFERS_LITTLEENDIAN)
140140

141141
#define FLATBUFFERS_VERSION_MAJOR 23
142-
#define FLATBUFFERS_VERSION_MINOR 1
143-
#define FLATBUFFERS_VERSION_REVISION 21
142+
#define FLATBUFFERS_VERSION_MINOR 3
143+
#define FLATBUFFERS_VERSION_REVISION 3
144144
#define FLATBUFFERS_STRING_EXPAND(X) #X
145145
#define FLATBUFFERS_STRING(X) FLATBUFFERS_STRING_EXPAND(X)
146146
namespace flatbuffers {
@@ -233,7 +233,7 @@ namespace flatbuffers {
233233
}
234234
#define FLATBUFFERS_HAS_STRING_VIEW 1
235235
// Check for absl::string_view
236-
#elif __has_include("absl/strings/string_view.h")
236+
#elif __has_include("absl/strings/string_view.h") && (__cplusplus >= 201411)
237237
#include "absl/strings/string_view.h"
238238
namespace flatbuffers {
239239
typedef absl::string_view string_view;

Shared/external/flatbuffers/stl_emulation.h

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -41,15 +41,18 @@
4141
#include <optional>
4242
#endif
4343

44-
// The __cpp_lib_span is the predefined feature macro.
45-
#if defined(FLATBUFFERS_USE_STD_SPAN)
46-
#include <span>
47-
#elif defined(__cpp_lib_span) && defined(__has_include)
48-
#if __has_include(<span>)
49-
#include <array>
50-
#include <span>
51-
#define FLATBUFFERS_USE_STD_SPAN
44+
#ifndef FLATBUFFERS_USE_STD_SPAN
45+
// Testing __cpp_lib_span requires including either <version> or <span>,
46+
// both of which were added in C++20.
47+
// See: https://en.cppreference.com/w/cpp/utility/feature_test
48+
#if defined(__cplusplus) && __cplusplus >= 202002L
49+
#define FLATBUFFERS_USE_STD_SPAN 1
5250
#endif
51+
#endif // FLATBUFFERS_USE_STD_SPAN
52+
53+
#if defined(FLATBUFFERS_USE_STD_SPAN)
54+
#include <array>
55+
#include <span>
5356
#else
5457
// Disable non-trivial ctors if FLATBUFFERS_SPAN_MINIMAL defined.
5558
#if !defined(FLATBUFFERS_TEMPLATES_ALIASES)

Shared/mslb_generated.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99
// Ensure the included flatbuffers.h is the same version as when this file was
1010
// generated, otherwise it may not be compatible.
1111
static_assert(FLATBUFFERS_VERSION_MAJOR == 23 &&
12-
FLATBUFFERS_VERSION_MINOR == 1 &&
13-
FLATBUFFERS_VERSION_REVISION == 21,
12+
FLATBUFFERS_VERSION_MINOR == 3 &&
13+
FLATBUFFERS_VERSION_REVISION == 3,
1414
"Non-compatible flatbuffers version included");
1515

1616
namespace mslb {

0 commit comments

Comments
 (0)