Commit Graph

2 Commits

Author SHA1 Message Date
Stephen Kelly 69182ce4ed Features: Ensure that the cxx_auto_type test is correct.
SolarisStudio considers 'auto' to be a storage class specifier in
C++98 mode (as appropriate), and considers variables without a specified
type to be of type int.  So, it treats

 auto x = 3.14;

as

 auto int x = 3.14;

which in C++98 mode is equivalent to

 int x = 3.14;

and it does not fail to compile as expected.

Change the test to use a reference so that the type must be known.
2015-01-17 14:48:27 +01:00
Stephen Kelly f97bf4370c Features: Add cxx_auto_type.
Record the availability of this feature for GNU 4.8 on (UNIX AND
NOT APPLE) only.  In the future, availability can be recorded for
earlier GNU, for other platforms and for other compilers. Initially
the affected configurations are as restricted as possible to allow
for easy testing while extending the features vector in only one
dimension.

The error message when using the set_property API directly is not
very good, but follow up commits will provide origin debugging of
the property and a target_compile_features command which will
provide a configure-time backtrace when possible.
2014-04-07 18:11:18 +02:00