Stereochemistry of 3-carboxylated 2,5-dihydrothiophene formation