Police joked about arresting Sir Cliff Richard at Wimbledon when investigating a child sex-assault allegation, a journalist has told a High Court judge.
BBC reporter Dan Johnson, who broke a story about Sir Cliff being investigated and his home being searched, told colleague Declan Wilson about the joke, Mr Justice Mann heard.
Mr Wilson told the judge how the idea left him "incredulous".
Sir Cliff has sued the BBC over coverage of the South Yorkshire Police search in August 2014 and wants damages at the "top end" of the scale.
He says the coverage, which involved the use of a helicopter, was a "very serious invasion" of his privacy.
The 77-year-old singer said he decided not to attend Wimbledon in 2015 because the investigation was on-going and he was under "suspicion".
The BBC disputes his claims.
Bosses say coverage of the search of the apartment in Sunningdale, Berkshire, was accurate and in good faith.
Mr Justice Mann has heard how Mr Johnson asked a South Yorkshire Police press officer if Sir Cliff was on the "radar" after getting a tip that the singer was being investigated.
Lawyers representing Sir Cliff have suggested that reporter Dan Johnson had "strong-armed" South Yorkshire Police into telling him a search of Sir Cliff's apartment would take place.
They have suggested that he threatened to reveal information about their sex-assault investigation against detectives' wishes if he did not get co-operation.
Mr Johnson has denied the suggestion.
He said he had "an understanding" with a detective leading the investigation.
Mr Johnson said the understanding was that if he "kept quiet" about the investigation, police "confirm details of the search".
The judge heard how he had told Mr Wilson, a BBC editor, what police had said a few weeks before the search.
"My understanding is that the police had 'opened the books', that is to say they openly gave Dan lots of detail about the investigation," Mr Wilson said in a written witness statement.
"I specifically remember Dan telling me that the police even joked that they had considered arresting Sir Cliff Richard at Wimbledon tennis tournament that year.
"The idea that the police might try to arrest Sir Cliff Richard at an event with such a public profile left me incredulous - even if the police were joking."
Lawyers have told Mr Justice Mann how in late 2013 a man made an allegation to the Metropolitan Police.
He said he had been sexually assaulted by Sir Cliff during an event featuring evangelist Billy Graham at Sheffield United's Bramall Lane football stadium, when he was a child in 1985.
Met Police officers passed the allegation to South Yorkshire Police in July 2014.
Sir Cliff denied the allegation and in June 2016 prosecutors announced that he would face no charges.
A BBC spokesman said that the corporation had reported Sir Cliff's "full denial of the allegations at every stage".
South Yorkshire Police agreed to pay Sir Cliff £400,000 after settling a claim he brought against the force, the judge has heard.
The singer had initially also sued the force but Mr Justice Mann was told in May 2017 how that dispute was settled.