Fix ICE when a struct variant enum is imported from an external crate

Fixes #19340
Second ICE case

Detailed description coming soon