Commit Graph

7 Commits

Author SHA1 Message Date
Justin M. Keyes
411a06c8b6 API: Context 2019-07-27 16:36:57 +02:00
ZyX
5d47fe124a shada.h: Remove newline after INCLUDE_GENERATED_DECLARATIONS section 2015-10-08 22:00:47 +03:00
ZyX
931539d108 shada: Do not export shada_read_file
Unlike some wrapper functions it is not used actually, so no need to export it.
Also removed ShadaPosition typedef which was not used.
2015-10-08 22:00:14 +03:00
ZyX
8dafa533db shada: Translate errors and add error codes
Notes:
- E136 code greatly changed its meaning: now it is write error and not read
  error.
- E195 was removed because shada_read_everything will already do all the
  necessary error reporting.
- E886 can be reported by both :rshada and :wshada, but :rshada comes first and
  AFAIR it is the only error which is not E575 and can be reported by :rshada.
2015-10-08 22:00:14 +03:00
ZyX
941ec54aa1 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.
2015-10-08 21:59:55 +03:00
ZyX
94ed7ba03b shada: Skip reading some items if needed
Avoids unneeded malloc()s/free()s and lots of code for parsing.
2015-10-08 21:59:53 +03:00
ZyX
244dbe3a77 viminfo: First version of ShaDa file dumping
What works:

1. ShaDa file dumping: header, registers, jump list, history, search patterns,
   substitute strings, variables.
2. ShaDa file reading: registers, global marks, variables.

Most was not tested.

TODO:

1. Merging.
2. Reading history, local marks, jump and buffer lists.
3. Documentation update.
4. Converting some data from &encoding.
5. Safer variant of dumping viminfo (dump to temporary file then rename).
6. Removing old viminfo code (currently masked with `#if 0` in a ShaDa file for
   reference).
2015-10-08 21:59:51 +03:00