Lung disease in middle-aged people may up dementia later