Oil rose on Wednesday, with Brent above $40 for the first time since March, as optimism mounted that major producers will extend…