In generated numpy code, copy arrays that are also written to, otherwise...

... it is possible that aliased variables lead to incorrect results that are difficult to debug. Fixes #259