mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Benjamin Bannier <>
Subject Re: Review Request 57382: Removed unused lambda captures.
Date Wed, 08 Mar 2017 11:27:06 GMT

This is an automatically generated e-mail. To reply, visit:

(Updated March 8, 2017, 12:27 p.m.)

Review request for mesos and Till Toenshoff.

Repository: mesos


This commit removes unused lambda captures of pointer and reference
types which do not extend any lifetimes.


  src/master/http.cpp de2cc03e6c7a3b75224113f56ce268937ead2929 
  src/tests/api_tests.cpp 52f58a4d6b1ea75744de1c3d2f0f064d9299fe1d 
  src/tests/master_quota_tests.cpp 91219d6693fdd119ed3b0bf734eaa55da9c58b0a 


Testing (updated)

`make check` (OS X w/ clang-trunk, Fedora25 w/ gcc-5.4.1)

clang-5.0.0 (`a66cd5133b2d412ed1f44e55a69841b63d0d5e45`) warns about these unused, side-effect
free captures, e.g.,

    $ clang-check src/master/http.cpp
    ../../src/master/http.cpp:2856:47: error: lambda capture 'tasksApprover' is not used
            writer->field("orphan_tasks", [this, &tasksApprover](
    1 error generated.
With this patch no such warnings are emitted anymore.


Benjamin Bannier

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message