Secretiveness in the judicial process should be sparingly applied, since openness and transparency are critically important to ensure public confidence in the system.

Even so, the suggestion that people suspected of certain serious crimes could be given anonymity to prevent so-called trial by media deserves fuller debate.

The notion was discussed yesterday in Holyrood's Justice Committee when the Justice Secretary commented that, if a person is arrested by the police, they are presumed innocent until proven otherwise, but that the media did not always portray it that way. Asked by committee convener Christine Grahame if there could be room for considering anonymity for accused parties in certain cases, he replied that he would be happy to look at the suggestion, since "these things do have great consequences".

They can. Depending on the circumstances of the case, an individual whose name is made known when detained or arrested, even if he or she is subsequently released without charge, can suffer distress as a result. The assumption among ill-informed members of the public that "there's no smoke without fire" can leave such individuals feeling they have been effectively condemned by public opinion, even if no further action is taken against them.

The most infamous such incident in recent years concerned Christopher Jefferies, who was the landlord of murdered Bristol architect Jo Yeates. Mr Jefferies was arrested but subsequently released and it was later found that Ms Yeates had been killed by engineer Vincent Tabak. Eight newspapers subsequently paid Mr Jefferies damages over their coverage of the case. No-one would wish an innocent loved one of theirs to suffer the indignities that Christopher Jefferies endured and, on face value, that appears to be a good reason to give arrested people anonymity.

Would anonymity truly serve the interests of open justice, however? The fact is that, as it is, media organisations often choose not to name people who have been detained or arrested, by convention, though there is no formal prohibition in law from doing so. If the principle is that all names of the arrested are withheld by law to protect reputations, then where does it end? Should it not then be extended also to give anonymity to anyone who is prosecuted but then acquitted? If so, the competing principle that justice should be public starts to be undermined.

Newspapers will accept any change to the law, but where they are apt to be less than impressed is hearing Mr MacAskill comment that enforcing anonymity in a world where social media is so popular would be difficult. Does this amount almost to admitting defeat? That would be no basis on which to decide this or any issue of media law. The same rules must apply to social media as to newspapers, and they must be enforced. It can be done: Lord McAlpine, who was libelled on Twitter, successfully sued those who defamed him. The challenge posed by social media is no reason not to change the rules but, before any such move is made, its implications must be given much deeper consideration.