gedcom7code / c-converter

Converts GEDCOM 5.5.1 to GEDCOM 7
The Unlicense
3 stars 2 forks source link

shared NOTE conversion doesn't follow GEDCOM 7 recommendation #6

Open dthaler opened 3 years ago

dthaler commented 3 years ago

shared NOTE records with a single reference could be converted to non-shared NOTE structures, as recommended by the GEDCOM 7 spec: ("It is recommended that SNOTE be avoided when NOTE will suffice.")

However the converter is not currently following this recommendation, and just converts them to SNOTE.

tychonievich commented 3 years ago

True. This is noted in the README as a feature I've not yet implemented. The rough outline I'll need to add is

Pass 1: accumulate all 0 @ID@ NOTEs (full records) and all n NOTE @ID@ IDs to figure out which notes are pointed to exactly once

Pass 2: copy the records pointed to only once into the structures, removing them as records, and change multiple pointers to SNOTE instead

pipeline/noter2s.c is an incomplete attempt at this I have not yet taken time to finish.