renamed scanner to be consistent with casefolding