The coffin of Ali Ahmed Mushaima is carried by demonstrators (Twitter)

Bahrain security forces have clashed with protesters who had gathered to mourn a 23-year-old demonstrator who died in police custody.

Riot police fired water cannons at protesters throwing stones and petrol bombs at the end of the funeral of Ali Ahmed Mushaima, who was arrested after taking part in a protest rally in March.

According to the government, Mushaima died of complications from sickle cell anemia, a condition for which he had been undergoing treatment at the Salmaniya Medical Complex since August.

"The death was natural and caused by sickle cell complications," said Bahrain's Information Affairs Authority.

But opposition members said Mushaima was denied adequate medical treatment in jail.

"Due to his medical condition, his lawyer had tried more than once to ensure adequate medical attention for him, but the prison authorities failed to provide such attention," Mohammed al-Maskati, head of the Bahrain Youth Society for Human Rights, said.

Mushaima was serving a seven-year sentence for vandalism, rioting, assaulting a police officer, and resisting arrest.

Earlier this week nine medics working at the Salmaniya Medical Complex were jailed after an appeal court upheld their conviction for playing a role in anti-government protests.

"[They] transformed the hospital to a place of illegal gatherings and strikes in violation of laws," prosecutors said.

Doctors said they were treating wounded demonstrators.

Protests demanding more democracy and a trade-off of powers between the majoritory Shia Muslim community and the Sunni ruling elite started in February 2011.

In September, in an exclusive interview to IBTimes UK, Bahraini opposition leader and former MP Ali Alaswad said that only political reforms and an elected and accountable government could solve Bahrain's problems.