summaryrefslogtreecommitdiff
path: root/build
diff options
context:
space:
mode:
authorKjell Ahlstedt <kjell.ahlstedt@bredband.net>2012-09-12 16:59:08 +0200
committerKjell Ahlstedt <kjell.ahlstedt@bredband.net>2012-09-12 16:59:08 +0200
commit7ee60984bb1354ef9b549450fb6e7fe1dc0d07ac (patch)
treec8e35bd459603e043f141fef3207e6960bc8e3d5 /build
parent1c2c94f611071085af02a4d5eea83a0958cd9cff (diff)
downloadglibmm-7ee60984bb1354ef9b549450fb6e7fe1dc0d07ac.tar.gz
Use std::time_t instead of ::time_t.
* build/c_std.m4: * glib/src/date.[hg|ccg]: Use std::time_t instead of ::time_t. Only std::time_t is required to be declared in <ctime>, which is recommended instead of <time.h> in C++ programs.
Diffstat (limited to 'build')
-rw-r--r--build/c_std.m414
1 files changed, 7 insertions, 7 deletions
diff --git a/build/c_std.m4 b/build/c_std.m4
index 606aef6e..f9850238 100644
--- a/build/c_std.m4
+++ b/build/c_std.m4
@@ -15,23 +15,23 @@
## You should have received a copy of the GNU Lesser General Public License
## along with this library. If not, see <http://www.gnu.org/licenses/>.
-#serial 20110910
+#serial 20120912
## GLIBMM_C_STD_TIME_T_IS_NOT_INT32
##
-## Test whether time_t and gint32 are typedefs of the same builting type. If
-## they aren't then they can be used for method overload. In that case
+## Test whether std::time_t and gint32 are typedefs of the same builting type.
+## If they aren't then they can be used for method overload. In that case
## GLIBMM_HAVE_C_STD_TIME_T_IS_NOT_INT32 is defined to 1.
##
AC_DEFUN([GLIBMM_C_STD_TIME_T_IS_NOT_INT32],
[
AC_CACHE_CHECK(
- [whether time_t is not equivalent to gint32, meaning that it can be used for a method overload],
+ [whether std::time_t is not equivalent to gint32, meaning that it can be used for a method overload],
[glibmm_cv_c_std_time_t_is_not_int32],
[
AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
[[
- #include <time.h>
+ #include <ctime>
]],[[
typedef signed int gint32;
class Test
@@ -39,7 +39,7 @@ AC_DEFUN([GLIBMM_C_STD_TIME_T_IS_NOT_INT32],
void something(gint32 val)
{}
- void something(time_t val)
+ void something(std::time_t val)
{}
};
]])],
@@ -50,5 +50,5 @@ AC_DEFUN([GLIBMM_C_STD_TIME_T_IS_NOT_INT32],
AS_VAR_IF([glibmm_cv_c_std_time_t_is_not_int32], ['yes'],
[AC_DEFINE([GLIBMM_HAVE_C_STD_TIME_T_IS_NOT_INT32], [1],
- [Defined when time_t is not equivalent to gint32, meaning that it can be used for a method overload])])[]dnl
+ [Defined when std::time_t is not equivalent to gint32, meaning that it can be used for a method overload])])[]dnl
])