On master PeriodDtype has a `.dtype_code` attribute. ```python In [5]: pd.PeriodDtype('D').dtype_code Out[5]: 6000 ``` That wasn't there in 1.0.x. I think we want it to be private.