The cognitive consequences of epilepsy