If Riaad Moosa ever performs standup at the Edinburgh festival, he says, this could be useful material. "What do you mean you're Muslim and Indian and you're from South Africa? That could be a peg to build a whole show around."

Moosa has other identities as a doctor and an actor: he starred in the hit comedy Material and is currently filming an adaptation of Nelson Mandela's autobiography Long Walk to Freedom.

His talent for comedy was evident in gigs while he was studying at medical school. He started work as a doctor but recalls: "What I wanted to do was the comedy and I found that. I found my bliss, I think." Now he wins awards, plays to sell-out audiences with shows such as Strictly Halaal and Riaad Moosa for the Baracka and has a slot on the satirical TV show Late Nite News. He has tackled thorny subjects such as Islamophobia after the 11 September terrorist attacks.

Eighteen years after apartheid, South Africa remains one of the world's most unequal societies but, as London's Olympic opening ceremony suggested, a sign of a nation's political maturity is its ability to laugh at itself.

Moosa reflects: "Racial humour is very predominant in South African standup, but I think that's as a result of our history and us coming to terms with what we've been through. When we started standup, we would mostly perform for white audiences and over the years we've started to see a wider variety of people and even specific genres where you have specifically Indian shows and Xhosa or Zulu or Afrikaans shows. "However, things are changing again as now we are beginning to have more common experience as South Africans. Remember, we really grew up separately; our life experience was very different because of segregation. So I think comedy is a good space to work those things out and educate everyone about the different experiences and different race groups in South Africa."

His humour exploits identity politics to the full. "I use myself as a template for my comedy. So first my background as a Muslim man, my being a doctor, I talk about my family quite a lot, my kids. Anything that resonates with me I talk about. The important thing is it should be able to work in a family setting."

Comedy thrives on mocking the powerful, he continues, but in South Africa everyone still considers themselves an underdog. "The hierarchy hasn't really been sorted out as yet. It depends on perspective, what people will laugh at. We were working these things out as a nation. I think comedy tells a lot; you can tell what people think by what they laugh at."

The dominance of American and British culture on South African TV means that comedians from those countries can make local references and still raise a laugh. The reverse is not yet true for comedians from South Africa. But this can change, Moosa believes. "I think the more we go out and the more we do our shows and talk about our experience, the better it will become. It's down to South Africans to start performing on an international stage more and more."

Loyiso Gola, performing at Edinburgh this year and host of Late Nite News, South Africa's answer to The Daily Show With Jon Stewart. "There's a young hipness to the way he does it; Jon Stewart is more of a comedic newsman. Loyiso is a bit more flippant."