Merge.hs: cleanup: factor out flag cleaning to 'leave_only_dynamic_fas' helper

Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>