diff --git a/gdb/ui-style.h b/gdb/ui-style.h
index fc40b93709d..201a6f302d9 100644
--- a/gdb/ui-style.h
+++ b/gdb/ui-style.h
@@ -19,6 +19,8 @@
 #ifndef GDB_UI_STYLE_H
 #define GDB_UI_STYLE_H
 
+#include <array>
+
 /* One of the color spaces that usually supported by terminals.  */
 enum class color_space
 {
