make EXCLUDE_TAGS and TEXT_FLOW into sets

so that the `if x in TEXT_FLOW` test will be quicker - as it will be
called many times in a loop it seems worth it.