FHIR / sushi

SUSHI (aka "SUSHI Unshortens Short Hand Inputs") is a reference implementation command-line interpreter/compiler for FHIR Shorthand (FSH).
Apache License 2.0
145 stars 44 forks source link

Unfold choice type slices when no unfolded elements match #1373

Closed jafeltra closed 1 year ago

jafeltra commented 1 year ago

Fixes #1337

This PR fixes a bug where if the choice type was referenced by slice name (i.e. valueString) but there were other non-slice elements that could be unfolded, SUSHI would fail to ever unfold and find the choice type. This PR adds another place where choice type elements are unfolded so that all elements can be considered when finding a provided path.

I ran a regression on all repos from the last year and there were not changes and no significant differences in processing time. That said, if anyone doesn't think this is the right approach to resolving this issue, let me know!