Flexibility and development of mirroring mechanisms