Association between pre-diagnostic prevalence of 30 common diseases and the subsequent risk of dementia: a population-based retrospective cohort study in Taiwan | Synapse