The copyright office has been quite clear (rightly so imo) that AI output is not protected by copyright without substantial human creative expression in the final product and purely prompt-created works simply don't qualify.
Indeed, I expect people muddling their codebases with AI output are going to find themselves in an interesting position of having to prove how much code humans actually wrote to enforce copyright claims if their code ever gets leaked.