Rankin brings Edinburgh copper John Rebus out of semi-retirement for Rather Be the Devil.

In his 23rd mystery, Rebus kicks around a cold case while two of his colleagues work on a fresh one. What’s the appeal of this dual structure?

I do like playing the past against the present. Some historical crime will come to light or impinge on the present. Maybe it’s so I can show some of the changes that take place in any society or culture over a passage of time. But also, Rebus is no longer a serving detective. It’s difficult for him to become involved in contemporary cases, so he focuses on unsolved ones. I think mortality is tapping him on the shoulder, and he wants to leave behind as little unsolved business as possible.

Can you foresee a day when you retire Rebus for good?

I did think I had seen the last of Rebus when he retired at the end of Exit Music. But then he insisted on an encore, and that encore has lasted a further four books. If he continues to age at his current rate, then he will have to shuffle off the stage eventually. I can’t see him detecting into his 80s. But I may have run out of steam and stories long before then. And I do have other characters such as Siobhan Clarke and Malcolm Fox as backup, should I need them. But there has never been a plan. Right now, I have no ideas for future books—but then I’ve not read the newspapers today.

The year 2017 marks 30 years of John Rebus. How have you kept the series fresh and dynamic?

The Rebus books are set mostly in real time, and I think that helps. The characters age and evolve, the world around them changes, new crimes, technologies, and problems emerge. At the same time, I’m changing as a writer, so each book is a little different, another step in my progression.

How has Scotland, and more specifically Edinburgh, changed as you’ve been writing?

There have been major political, social, and economic changes in Scotland over the past 30 years. The Scottish National Party used to be a small party, with no grip on power. Now they’ve been in government for nine years. We’ve had a hotly contested independence referendum, a financial crash that almost ruined Edinburgh (Royal Bank of Scotland has its HQ here and went overnight from global player to basket case). There have also been major structural changes in the way Scotland is policed. We’ve had terrorism, too—most seismically, Lockerbie. I bring these issues into my stories because they shape my environment and the lives of my fictional characters.