From 5e199fcd858c51d913840a5582939b4d88f9fb04 Mon Sep 17 00:00:00 2001 From: tomvg Date: Tue, 12 Oct 2021 11:36:19 +0200 Subject: [PATCH] Include for std::max for msvc 2017, (#226) Msvc defined its own (lowercase) macros for min/max. Because of this, the std::min and std::max functions need to be explicitly included or otherwise are not availible. In the msvc 2019 compiler this issue seems fixed. However, on msvc 2017 not including causes compilation errors. Adding the include is a simple fix that does not hurt the other platforms and enables compilation on msvc 2017. --- src/ftxui/dom/scroll_indicator.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/ftxui/dom/scroll_indicator.cpp b/src/ftxui/dom/scroll_indicator.cpp index b003cbd4..2167d3ae 100644 --- a/src/ftxui/dom/scroll_indicator.cpp +++ b/src/ftxui/dom/scroll_indicator.cpp @@ -1,3 +1,5 @@ +#include // For std::max + #include "ftxui/dom/elements.hpp" #include "ftxui/dom/node.hpp" #include "ftxui/dom/node_decorator.hpp" // for NodeDecorator