Commit 8d119e05 authored by Filip Roséen's avatar Filip Roséen Committed by Jean-Baptiste Kempf

mkv: fix build failure when compiled with llvm

LLVM treats a typedef with forward-declaration inside a local struct as
a forward-declaration for a nested type of that struct, effectively
erroring on the implementation of the dispatchers.

This patch fixes that issue by forcing the name to referr to a type in
the sourrounding scope (by introducing a proper forward-declaration).
Signed-off-by: Jean-Baptiste Kempf's avatarJean-Baptiste Kempf <jb@videolan.org>
parent c7ccd77d
......@@ -90,6 +90,7 @@ namespace {
#define MKV_SWITCH_CREATE(DispatchType_, GroupName_, PayloadType_) \
typedef DispatcherTag<__LINE__> GroupName_ ## _tag_t; \
extern GroupName_##_tag_t GroupName_ ## _tag; \
struct GroupName_; \
struct GroupName_##_base : DispatchContainer<GroupName_##_tag_t, &GroupName_##_tag, DispatchType_> { \
typedef PayloadType_ payload_t; \
typedef DispatchType_ dispatch_t; \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment