processIdentifiers function

Handle identifiers that may be illegal (e.g. containing spaces).