Update gitignore for CMake and Visual Studio
[platform/upstream/glog.git] / m4 / using_operator.m4
1 AC_DEFUN([AC_CXX_USING_OPERATOR],
2   [AC_CACHE_CHECK(
3       whether compiler supports using ::operator<<,
4       ac_cv_cxx_using_operator,
5       [AC_LANG_SAVE
6        AC_LANG_CPLUSPLUS
7        AC_TRY_COMPILE([#include <iostream>
8                        std::ostream& operator<<(std::ostream&, struct s);],
9                       [using ::operator<<; return 0;],
10                       ac_cv_cxx_using_operator=1,
11                       ac_cv_cxx_using_operator=0)
12       AC_LANG_RESTORE])
13   if test "$ac_cv_cxx_using_operator" = 1; then
14     AC_DEFINE(HAVE_USING_OPERATOR, 1, [define if the compiler supports using expression for operator])
15   fi])