Title: The endogeneity of exchange rate regimes