11:43 AM PT -- It appears the Shelby County Sheriff's Office made a mistake on its website, mistakenly posting that Williams was charged with cocaine possession, when it SHOULD have said codeine possession.
Ex-NBA player Shawne Williams -- a former 1st round draft pick -- was arrested in Tennessee last night for possession of weed and codeine ... and cops believe he may have been trying to sell it.
According to reports, Williams' night went to hell when an officer on a routine patrol claims he smelled marijuana coming from a Porsche Panamera which was parked near a Cricket wireless store.
When the cop approached the car, the person inside -- Williams -- reportedly said, "Officer I ain't gonna lie to you, there's a blunt in the car and some syrup."
The cop searched the car ... and reportedly found a partially smoked blunt, another blunt that hadn't been smoked, and a bottle of codeine cough syrup (for which he did not have a prescription).
According to the Williams' booking sheet, posted on the Shelby County Sheriff’s Office website, the 26-year-old was arrested for possession of weed and codeine with intent to manufacture, deliver or sell.
Story developing ..