You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kudu.apache.org by da...@apache.org on 2016/10/20 18:15:34 UTC

kudu git commit: tool_action_test.cc: specify lambda return type

Repository: kudu
Updated Branches:
  refs/heads/master 6bc075385 -> abd87164f


tool_action_test.cc: specify lambda return type

A user reported that they were unable to compile tool_action_test.cc on
OS X 10.11 with either the system Clang or thirdparty Clang. It appears
that these toolchains are not able to infer the correct return type for
a lambda. I'm not able to repro the failure, but the original user
confirmed that this patch fixed the issue. Failure:

    /Users/<user>/ProjectFiles/kudu/src/kudu/tools/tool_action_test.cc:384:5: error: return type 'kudu::Status' must match previous return type 'const ::kudu::Status' when lambda
          expression has unspecified explicit return type
        return Status::OK();
        ^
    1 error generated.

Change-Id: I52824e85a37c67bea8a2373264e8198d8d2294f4
Reviewed-on: http://gerrit.cloudera.org:8080/4773
Reviewed-by: Todd Lipcon <to...@apache.org>
Tested-by: Kudu Jenkins


Project: http://git-wip-us.apache.org/repos/asf/kudu/repo
Commit: http://git-wip-us.apache.org/repos/asf/kudu/commit/abd87164
Tree: http://git-wip-us.apache.org/repos/asf/kudu/tree/abd87164
Diff: http://git-wip-us.apache.org/repos/asf/kudu/diff/abd87164

Branch: refs/heads/master
Commit: abd87164fbaed626f6a374f49959bbba57dead67
Parents: 6bc0753
Author: Dan Burkert <da...@apache.org>
Authored: Thu Oct 20 10:50:02 2016 -0700
Committer: Dan Burkert <da...@apache.org>
Committed: Thu Oct 20 18:15:14 2016 +0000

----------------------------------------------------------------------
 src/kudu/tools/tool_action_test.cc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kudu/blob/abd87164/src/kudu/tools/tool_action_test.cc
----------------------------------------------------------------------
diff --git a/src/kudu/tools/tool_action_test.cc b/src/kudu/tools/tool_action_test.cc
index 360c677..b1b9b3f 100644
--- a/src/kudu/tools/tool_action_test.cc
+++ b/src/kudu/tools/tool_action_test.cc
@@ -348,7 +348,7 @@ void GeneratorThread(
   shared_ptr<KuduSession> session(client->NewSession());
   uint64_t idx = 0;
 
-  auto generator = [&]() {
+  auto generator = [&]() -> Status {
     RETURN_NOT_OK(session->SetMutationBufferFlushWatermark(
                      FLAGS_buffer_flush_watermark_pct));
     RETURN_NOT_OK(session->SetMutationBufferSpace(