Scottish stage and screen star Alan Cumming has launched a foul-mouthed tirade over the prospect of Donald Trump becoming American president. 

The New York-based actor branded Trump a "racist and a sexist" and said the US was on the brink of "going back to medieval times". 

He made the remarks during his Edinburgh International Festival show. 

And Cumming urged his fellow American citizens to wake up over the prospect of Trump moving into the White House within the next few months. 

The Cabaret star attacked the Republican candidate for clumsily wading into the aftermath of the Brexit debate during a visit to his "shabby old golf course" in Ayrshire. 

Read more: Alan Cumming talks politics and his career path

The Perthshire-born actor said Trump's much-publicised blunder, when he mistakenly tweeted that Scotland had voted to leave the EU, had exposed his lack of grasp of international affairs. 

However, Cumming has laughed off his own controversial intervention into the post-Brexit debate, when he suggested that "stupid English people" were to blame for the Brexit result. 

He later apologised for "any offence caused", but said his sense of humour had been misunderstood. 

Speaking during his cabaret show, Cumming told the audience that he would have voted to remain in the EU had he been able to participate in June's referendum. 

He added: "What I thought was absolutely hilariously serendipitous was that on the day the Brexit result was announced, by the jingling of the political spheres, Donald Trump landed in Scotland. 

"Running for American president obviously wasn't enough of a job for him - he was here to promote his shabby old golf course. 

Read more: Alan Cumming talks politics and his career path

"He tweeted to say 'Just arrived in Scotland. The people is going nuts. They've taken back their country. 

"We voted to stay you stupid, c***. If that lack of grasp of international politics is not a reason for this man not to be the president of the United States of America I do not know what is. 

"If you know any Americans tell them to get their s*** together. He's racist and sexist and I just think we're on the bring of going back into medieval times if he gets anywhere near that White House." 

Cumming, who shot to fame in Fringe double act Victor and Barry with Forbes Masson, is appearing in a late-night cabaret show for the whole of the Festival. 

Read more: Alan Cumming talks politics and his career path

It is inspired by dressing-room parties he hosted during the Broadway run of Cabaret, the show which helped Cumming make his name in the United States when he first performed it there in 1998. 

Cumming is also hosting a number of late-night after-parties at the festival's headquarters at The Hub, on the Royal Mile, which has been transformed into "Club Cumming" for the month.