fix bug with multiple target modules per msgid

Messages that are defined for multiple target modules should be written
to every of those modules. This change adds an example that fails
without the fix.