mirror of
https://github.com/neovim/neovim.git
synced 2024-12-31 17:13:26 -07:00
shada: Reassign some entry types to WantInfo and WantMarks
kShaDaWantMarks now loads only local file change list and file-local marks. kShaDaWantInfo now loads global marks and jump list.
This commit is contained in:
parent
42536abd33
commit
941ec54aa1
@ -536,7 +536,7 @@ static void shada_read(FILE *const fp, const int flags)
|
||||
}
|
||||
case kSDItemJump:
|
||||
case kSDItemGlobalMark: {
|
||||
if (!(flags & kShaDaWantMarks)
|
||||
if (!(flags & kShaDaWantInfo)
|
||||
|| (cur_entry.type == kSDItemGlobalMark
|
||||
&& get_viminfo_parameter('f') == 0)) {
|
||||
shada_free_shada_entry(&cur_entry);
|
||||
@ -1734,9 +1734,9 @@ shada_read_next_item_start:
|
||||
}
|
||||
break;
|
||||
}
|
||||
case kSDItemBufferList:
|
||||
case kSDItemChange:
|
||||
case kSDItemGlobalMark:
|
||||
case kSDItemJump:
|
||||
case kSDItemBufferList:
|
||||
case kSDItemVariable:
|
||||
case kSDItemRegister:
|
||||
case kSDItemHistoryEntry:
|
||||
@ -1747,7 +1747,7 @@ shada_read_next_item_start:
|
||||
}
|
||||
break;
|
||||
}
|
||||
case kSDItemGlobalMark:
|
||||
case kSDItemChange:
|
||||
case kSDItemLocalMark: {
|
||||
if (!(flags & kShaDaWantMarks)) {
|
||||
SKIP;
|
||||
|
@ -6,7 +6,7 @@ typedef long ShadaPosition;
|
||||
/// Flags for shada_read_file and children
|
||||
enum {
|
||||
kShaDaWantInfo = 1, ///< Load non-mark information
|
||||
kShaDaWantMarks = 2, ///< Load file marks
|
||||
kShaDaWantMarks = 2, ///< Load local file marks and change list
|
||||
kShaDaForceit = 4, ///< Overwrite info already read
|
||||
kShaDaGetOldfiles = 8, ///< Load v:oldfiles.
|
||||
kShaDaWantHeader = 16, ///< Do not skip header (shada_read_next_item).
|
||||
|
Loading…
Reference in New Issue
Block a user