updated for version 7.0219
diff --git a/src/ascii.h b/src/ascii.h
index 4ab3518..b920d41 100644
--- a/src/ascii.h
+++ b/src/ascii.h
@@ -177,23 +177,17 @@
* Character that separates dir names in a path.
* For MS-DOS, WIN32 and OS/2 we use a backslash. A slash mostly works
* fine, but there are places where it doesn't (e.g. in a command name).
- * For Macintosh we use a colon.
* For Acorn we use a dot.
*/
#ifdef BACKSLASH_IN_FILENAME
# define PATHSEP psepc
# define PATHSEPSTR pseps
#else
-# ifdef COLON_AS_PATHSEP
-# define PATHSEP ':'
-# define PATHSEPSTR ":"
+# ifdef RISCOS
+# define PATHSEP '.'
+# define PATHSEPSTR "."
# else
-# ifdef RISCOS
-# define PATHSEP '.'
-# define PATHSEPSTR "."
-# else
-# define PATHSEP '/'
-# define PATHSEPSTR "/"
-# endif
+# define PATHSEP '/'
+# define PATHSEPSTR "/"
# endif
#endif
diff --git a/src/eval.c b/src/eval.c
index e5131f3..423129b 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -19326,8 +19326,7 @@
profile_end(&fp->uf_tm_start);
profile_sub_wait(&wait_start, &fp->uf_tm_start);
profile_add(&fp->uf_tm_total, &fp->uf_tm_start);
- profile_add(&fp->uf_tm_self, &fp->uf_tm_start);
- profile_sub(&fp->uf_tm_self, &fp->uf_tm_children);
+ profile_self(&fp->uf_tm_self, &fp->uf_tm_start, &fp->uf_tm_children);
if (fc.caller != NULL && &fc.caller->func->uf_profiling)
{
profile_add(&fc.caller->func->uf_tm_children, &fp->uf_tm_start);
@@ -19714,9 +19713,9 @@
++fp->uf_tml_count[fp->uf_tml_idx];
profile_end(&fp->uf_tml_start);
profile_sub_wait(&fp->uf_tml_wait, &fp->uf_tml_start);
- profile_add(&fp->uf_tml_self[fp->uf_tml_idx], &fp->uf_tml_start);
profile_add(&fp->uf_tml_total[fp->uf_tml_idx], &fp->uf_tml_start);
- profile_sub(&fp->uf_tml_self[fp->uf_tml_idx], &fp->uf_tml_children);
+ profile_self(&fp->uf_tml_self[fp->uf_tml_idx], &fp->uf_tml_start,
+ &fp->uf_tml_children);
}
fp->uf_tml_idx = -1;
}
diff --git a/src/ex_cmds2.c b/src/ex_cmds2.c
index 00dcea9..ad49d45 100644
--- a/src/ex_cmds2.c
+++ b/src/ex_cmds2.c
@@ -911,6 +911,28 @@
}
/*
+ * Add the "self" time from the total time and the children's time.
+ */
+ void
+profile_self(self, total, children)
+ proftime_T *self, *total, *children;
+{
+ /* Check that the result won't be negative. Can happen with recursive
+ * calls. */
+#ifdef WIN3264
+ if (total->QuadPart <= children->QuadPart)
+ return;
+#else
+ if (total->tv_sec < children->tv_sec
+ || (total->tv_sec == children->tv_sec
+ && total->tv_usec <= children->tv_usec))
+ return;
+#endif
+ profile_add(self, total);
+ profile_sub(self, children);
+}
+
+/*
* Get the current waittime.
*/
void
@@ -3000,8 +3022,8 @@
profile_end(&si->sn_pr_start);
profile_sub_wait(&wait_start, &si->sn_pr_start);
profile_add(&si->sn_pr_total, &si->sn_pr_start);
- profile_add(&si->sn_pr_self, &si->sn_pr_start);
- profile_sub(&si->sn_pr_self, &si->sn_pr_children);
+ profile_self(&si->sn_pr_self, &si->sn_pr_start,
+ &si->sn_pr_children);
}
}
#endif
@@ -3505,9 +3527,9 @@
++pp->snp_count;
profile_end(&si->sn_prl_start);
profile_sub_wait(&si->sn_prl_wait, &si->sn_prl_start);
- profile_add(&pp->sn_prl_self, &si->sn_prl_start);
profile_add(&pp->sn_prl_total, &si->sn_prl_start);
- profile_sub(&pp->sn_prl_self, &si->sn_prl_children);
+ profile_self(&pp->sn_prl_self, &si->sn_prl_start,
+ &si->sn_prl_children);
}
si->sn_prl_idx = -1;
}
diff --git a/src/main.c b/src/main.c
index 60aebf9..37d2e94 100644
--- a/src/main.c
+++ b/src/main.c
@@ -2589,6 +2589,9 @@
#ifdef SYS_VIMRC_FILE
(void)do_source((char_u *)SYS_VIMRC_FILE, FALSE, FALSE);
#endif
+#ifdef MACOS_X
+ (void)do_source((char_u *)"$VIMRUNTIME/macmap.vim", FALSE, FALSE);
+#endif
/*
* Try to read initialization commands from the following places:
diff --git a/src/memline.c b/src/memline.c
index b876261..876704a 100644
--- a/src/memline.c
+++ b/src/memline.c
@@ -2647,7 +2647,7 @@
/*
* Replace line lnum, with buffering, in current buffer.
*
- * If copy is TRUE, make a copy of the line, otherwise the line has been
+ * If "copy" is TRUE, make a copy of the line, otherwise the line has been
* copied to allocated memory already.
*
* Check: The caller of this function should probably also call
diff --git a/src/misc1.c b/src/misc1.c
index 8399535..60b87ca 100644
--- a/src/misc1.c
+++ b/src/misc1.c
@@ -4430,12 +4430,8 @@
/* server"user passwd"::device:[full.path.name]fname.extension;version" */
return (c == ':' || c == '[' || c == ']' || c == '/'
|| c == '<' || c == '>' || c == '"' );
-# else
-# ifdef COLON_AS_PATHSEP
- return (c == ':');
-# else /* Amiga */
+# else /* Amiga */
return (c == ':' || c == '/');
-# endif
# endif /* VMS */
# endif
# endif
diff --git a/src/proto/ex_cmds2.pro b/src/proto/ex_cmds2.pro
index cc56643..336e01e 100644
--- a/src/proto/ex_cmds2.pro
+++ b/src/proto/ex_cmds2.pro
@@ -15,6 +15,7 @@
void profile_end __ARGS((proftime_T *tm));
void profile_sub __ARGS((proftime_T *tm, proftime_T *tm2));
void profile_add __ARGS((proftime_T *tm, proftime_T *tm2));
+void profile_self __ARGS((proftime_T *self, proftime_T *total, proftime_T *children));
void profile_get_wait __ARGS((proftime_T *tm));
void profile_sub_wait __ARGS((proftime_T *tm, proftime_T *tma));
int profile_equal __ARGS((proftime_T *tm1, proftime_T *tm2));