I would say it's not so much a matter of the word legislation "not working" in the blank, but more a matter of autonomy being a much better fit.
This happens a lot with GRE verbal questions. They don't merely asking which of the two (or more) words can fit in the blank grammatically, but they also expecting some degree of reading comprehension, so that the best word is chosen.
As a simpler example, imagine a sentence like:
It was summertime, the time when Paul liked to look at the _______ leaves.
Paul was in New York City, looking at the long line of _______ taxis.
We can put any color we want in those blanks, and the sentences would still be grammatical. But if it's summertime, we expect most leaves to be green, and if we are in New York, we expect most of the taxicabs to be yellow. Green and yellow are better answers than pink and red – even though nothing prevents a taxi company from painting their cabs red.
With that in mind, let's say that a local school district has recently passed some new legislation, but a new federal mandate will wreak havoc on the new city law. In that case, I suppose a lawyer arguing in court on behalf of city might say:
The city government feels that new federal impositions represents an undue infringement on their legislation.
That makes sense, but I had to contrive an example to make it work. The following sentence, on the other hand, makes sense on its own and doesn't need a hypothetical example as a backdrop:
The city government feels that new federal impositions represent an undue infringement on their autonomy.