Why? Setting up one of the n sites a company operates on EU turf would certainly be easier than avoiding ASML altogether. How would it force setting up a competitor? There's a huge difference between "can't use outside" and "can't use exclusively outside".
Is this restraining supply in any real sense? ASML will want to setup new factories, so saying "one of those needs to be in the EU" is more about directing the funding rather than forcing it to not happen.
In principle I'm not against ensuring some protection of access to strategic resources for countries. (Note I say "access" and not "exclusive access").