aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoroni-link <knil.ino@gmail.com>2014-04-01 13:09:03 +0200
committerThiago de Arruda <tpadilha84@gmail.com>2014-04-02 18:52:16 -0300
commit6c902e21047d17655fa55864004d77e53eda4428 (patch)
treef77a201eb754a2993985e3cfe86bc598e24884a3
parent5aa1128e97632e8770965f8cffc308351fde68a8 (diff)
downloadrneovim-6c902e21047d17655fa55864004d77e53eda4428.tar.gz
rneovim-6c902e21047d17655fa55864004d77e53eda4428.tar.bz2
rneovim-6c902e21047d17655fa55864004d77e53eda4428.zip
remove HAVE_STRFTIME
strftime is a C99 standard function.
-rw-r--r--config/config.h.in1
-rw-r--r--src/eval.c6
-rw-r--r--src/undo.c2
3 files changed, 0 insertions, 9 deletions
diff --git a/config/config.h.in b/config/config.h.in
index 8a9946f656..5ec578136f 100644
--- a/config/config.h.in
+++ b/config/config.h.in
@@ -61,7 +61,6 @@
#define HAVE_SIGVEC 1
#define HAVE_ST_BLKSIZE 1
#define HAVE_STRCASECMP 1
-#define HAVE_STRFTIME 1
#define HAVE_STRING_H 1
#define HAVE_STRINGS_H 1
#define HAVE_STRNCASECMP 1
diff --git a/src/eval.c b/src/eval.c
index 3d0d461cbe..f7bc70fc17 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -716,9 +716,7 @@ static void f_sqrt(typval_T *argvars, typval_T *rettv);
static void f_str2float(typval_T *argvars, typval_T *rettv);
static void f_str2nr(typval_T *argvars, typval_T *rettv);
static void f_strchars(typval_T *argvars, typval_T *rettv);
-#ifdef HAVE_STRFTIME
static void f_strftime(typval_T *argvars, typval_T *rettv);
-#endif
static void f_stridx(typval_T *argvars, typval_T *rettv);
static void f_string(typval_T *argvars, typval_T *rettv);
static void f_strlen(typval_T *argvars, typval_T *rettv);
@@ -7037,9 +7035,7 @@ static struct fst {
{"str2nr", 1, 2, f_str2nr},
{"strchars", 1, 1, f_strchars},
{"strdisplaywidth", 1, 2, f_strdisplaywidth},
-#ifdef HAVE_STRFTIME
{"strftime", 1, 2, f_strftime},
-#endif
{"stridx", 2, 3, f_stridx},
{"string", 1, 1, f_string},
{"strlen", 1, 1, f_strlen},
@@ -14024,7 +14020,6 @@ static void f_str2nr(typval_T *argvars, typval_T *rettv)
rettv->vval.v_number = n;
}
-#ifdef HAVE_STRFTIME
/*
* "strftime({format}[, {time}])" function
*/
@@ -14074,7 +14069,6 @@ static void f_strftime(typval_T *argvars, typval_T *rettv)
vim_free(enc);
}
}
-#endif
/*
* "stridx()" function
diff --git a/src/undo.c b/src/undo.c
index 7e01408537..656b38d3cd 100644
--- a/src/undo.c
+++ b/src/undo.c
@@ -2497,7 +2497,6 @@ void ex_undolist(exarg_T *eap)
*/
static void u_add_time(char_u *buf, size_t buflen, time_t tt)
{
-#ifdef HAVE_STRFTIME
struct tm *curtime;
if (time(NULL) - tt >= 100) {
@@ -2509,7 +2508,6 @@ static void u_add_time(char_u *buf, size_t buflen, time_t tt)
/* longer ago */
(void)strftime((char *)buf, buflen, "%Y/%m/%d %H:%M:%S", curtime);
} else
-#endif
vim_snprintf((char *)buf, buflen, _("%ld seconds ago"),
(long)(time(NULL) - tt));
}