Fix cross-crate tuple structs in statics

Fixes #17169.
Fixes #17649.