Finally we have the takeFlag() function which deactivates an existing flag to activate it on the current element(s).
Check the example from the spec.
Currently it activates the flag no matter what. The flag needs to be activated on at least one of the elements matched by the selector.