Commit Graph

5 Commits

Author SHA1 Message Date
Kitware Robot d9fd2f5402 Revise C++ coding style using clang-format
Run the `Utilities/Scripts/clang-format.bash` script to update
all our C++ code to a new style defined by `.clang-format`.
Use `clang-format` version 3.8.

* If you reached this commit for a line in `git blame`, re-run the blame
  operation starting at the parent of this commit to see older history
  for the content.

* See the parent commit for instructions to rebase a change across this
  style transition commit.
2016-05-16 16:05:19 -04:00
Brad King ecb1d5b47a Features: VS 2013 Update 3 supports initializer lists (#15494)
VS 2013 originally claimed to support initializer lists but a bug was
found in which it generated bad code silently.  For this reason we
previously considered support to not be present.  However, Update 3 adds
a hard error on cases that previously generated bad code, so it is now
safe to use initializer lists with VS 2013 Update 3 or greater.  At
worst a compiler error will be issued in the cases that do not work, but
that is no different from any other compiler-specific workaround a
project code may need.
2015-04-06 10:06:26 -04:00
Brad King 827309af76 Tests: Fix CompileFeatures cxx_generalized_initializers example
The only reason this failed to compile on VS 2013 was because the
compiler uses different initializer_list constructor argument types than
our dummy implementation.  The standard does not specify the non-default
constructor argument types for initializer_list.  Use a template to
match any two-arg constructor a compiler might select (e.g. begin/end or
begin/len).  Use #error to preserve the error on VS 2013.
2015-04-06 10:05:37 -04:00
Stephen Kelly 0798d1e5b0 Features: Extend the generalized_initializers test for GNU < 4.7.
That compiler requires a different initializer_list constructor, so
update the test to match.
2015-01-15 22:13:22 +01:00
Stephen Kelly e74b216c90 Features: Add cxx_generalized_initializers. 2014-04-08 11:05:56 +02:00