The temporary sheriffs - recently made redundant following an appeal court ruling that they contravene the European Convention on Human Rights, introduced in Scotland in May - are now being challenged on different grounds.
It is claimed the use of temporary sheriffs on a permanent, albeit part-time basis, contravenes the Sheriff Courts (Scotland) Act 1971, which allows for the use of temporaries only in times of emergency. Neil Davidson QC is arguing that since 1977, the legislation has been abused since the courts have been dependent on temporary posts instead of being staffed by independent judges.
If the appeal against temporaries - who dealt with 25 per cent of the workload in criminal and civil cases - is upheld, legal experts fear prisoners could be freed, even if they entered guilty pleas and couples could find their divorces invalid.
The gravity of the case is such that the Lord Advocate himself appeared before senior Scottish judges to argue the case