It’s 1947 and 93-year-old Sherlock Holmes (Ian McKellen) grapples with a failing memory as he strives to reconstruct a troubling case from his past.

As Arthur Conan Doyle’s great detective reconstructs the case that precipitated his retirement to the Sussex countryside, there is also another mystery to solve, involving his cherished bees and his widowed housekeeper Laura Linney’s bright young son (Milo Parker, very impressive).

These puzzles might not have have the fiendish elegance of the best Holmes mysteries and their unravelling proceeds at an understandably gentle pace. However, there is much to relish in this tender, melancholy drama based on Mitch Cullin’s 2005 novel, A Slight Trick of the Mind.

McKellen is superb, both as the halting nonagenarian and, in flashbacks, as the spry, supremely confident detective of 35 years earlier.

In a nice, teasingly self-referential touch, McKellen drops in on a matinee screening of a black-and-white 1940s Sherlock Holmes adventure whose camped-up, silver screen detective is none other than Nicholas Rowe, star of 1985’s juvenile romp, Young Sherlock Holmes.

This film is not showing on BBC2 Wales.