Repository: incubator-impala
Updated Branches:
  refs/heads/master 1f80396b2 -> 894bb7785


Qualify min() in header

Change-Id: I840869bc2b8ffebc34f4bf4bbefe89976d4e54f2
Reviewed-on: http://gerrit.cloudera.org:8080/5991
Reviewed-by: Jim Apple <[email protected]>
Tested-by: Impala Public Jenkins


Project: http://git-wip-us.apache.org/repos/asf/incubator-impala/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-impala/commit/065bbda9
Tree: http://git-wip-us.apache.org/repos/asf/incubator-impala/tree/065bbda9
Diff: http://git-wip-us.apache.org/repos/asf/incubator-impala/diff/065bbda9

Branch: refs/heads/master
Commit: 065bbda991adad716c7ff77c80245ca48d0c8ba4
Parents: 1f80396
Author: Henry Robinson <[email protected]>
Authored: Thu Feb 9 17:45:16 2017 -0800
Committer: Impala Public Jenkins <[email protected]>
Committed: Tue Feb 14 09:07:51 2017 +0000

----------------------------------------------------------------------
 be/src/exprs/anyval-util.h | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-impala/blob/065bbda9/be/src/exprs/anyval-util.h
----------------------------------------------------------------------
diff --git a/be/src/exprs/anyval-util.h b/be/src/exprs/anyval-util.h
index 429322a..dfcf1ec 100644
--- a/be/src/exprs/anyval-util.h
+++ b/be/src/exprs/anyval-util.h
@@ -18,6 +18,8 @@
 #ifndef IMPALA_EXPRS_ANYVAL_UTIL_H
 #define IMPALA_EXPRS_ANYVAL_UTIL_H
 
+#include <algorithm>
+
 #include "runtime/runtime-state.h"
 #include "runtime/string-value.inline.h"
 #include "runtime/timestamp-value.h"
@@ -218,7 +220,7 @@ class AnyValUtil {
   static void TruncateIfNecessary(const FunctionContext::TypeDesc& type, 
StringVal *val) {
     if (type.type == FunctionContext::TYPE_VARCHAR) {
       DCHECK(type.len >= 0);
-      val->len = min(val->len, type.len);
+      val->len = std::min(val->len, type.len);
     }
   }
 

Reply via email to