[wesnoth-commits] [wesnoth/wesnoth] ca3490: Disable -Wunused-lambda-capture on clang.

jostephd noreply at github.com
Tue Jun 11 13:16:20 UTC 2019


  Branch: refs/heads/1.14
  Home:   https://github.com/wesnoth/wesnoth
  Commit: ca34902a30c2a882a20fcb56fad77fcc8e35a2f9
      https://github.com/wesnoth/wesnoth/commit/ca34902a30c2a882a20fcb56fad77fcc8e35a2f9
  Author: josteph <josteph at fastmail.com>
  Date:   2019-06-11 (Tue, 11 Jun 2019)

  Changed paths:
    M CMakeLists.txt
    M SConstruct

  Log Message:
  -----------
  Disable -Wunused-lambda-capture on clang.

In a nutshell, capturing a local "const constexpr int foo;" variable
with [foo](){} warns on clang that the program would be valid even if
the square brackets had been left empty, but making them so warns on
VC15.  See
https://stackoverflow.com/questions/52416362/unused-lambda-capture-warning-when-capture-is-actually-used

Disable the warning since explicitly capturing foo is good practice.

(cherry picked from commit d76a7ba5d09ca4d8d847a42cb9ca8f1758ac5153)





More information about the Commits mailing list