patch 7.4.2024
Problem: More buf_valid() calls can be optimized.
Solution: Use bufref_valid() instead.
diff --git a/src/structs.h b/src/structs.h
index e092e6b..0cf2800 100644
--- a/src/structs.h
+++ b/src/structs.h
@@ -1431,7 +1431,7 @@
char_u *ch_callback; /* call when a msg is not handled */
partial_T *ch_partial;
- buf_T *ch_buffer; /* buffer to read from or write to */
+ bufref_T ch_bufref; /* buffer to read from or write to */
int ch_nomodifiable; /* TRUE when buffer can be 'nomodifiable' */
int ch_nomod_error; /* TRUE when e_modifiable was given */
int ch_buf_append; /* write appended lines instead top-bot */
@@ -2925,7 +2925,7 @@
int use_aucmd_win; /* using aucmd_win */
win_T *save_curwin; /* saved curwin */
win_T *new_curwin; /* new curwin */
- buf_T *new_curbuf; /* new curbuf */
+ bufref_T new_curbuf; /* new curbuf */
char_u *globaldir; /* saved value of globaldir */
#endif
} aco_save_T;