Twitter can be a wonderful resource. Within half an hour of posting a request for help in identifying this sawfly larva, it had been identified by @SK53onOSM and Colin Perkins (@PershoreColin) as Apethymus serotinus.
For pictures of the adult insect, visit this blog
It exhibited typical sawfly larva behaviour when I gave it a gentle prod ....
........ curling itself up into a spiral.
The key distinction between a lepidopteran (butterfly or moth) caterpillar and a sawfly caterpillar lies in the number of legs: both have three pairs of true legs at the front but lepidopteran larvae only have four pairs of prolegs behind, whereas sawfly larvae have six or more pairs of prolegs.