Hmmm...it's possible that you got ahold of some laced/contaminated weed, but there are other possibilities that are just as likely.
First of all, why are you so convinced it was glass/something sharp? What exactly does it feel like, and is there anything that makes it better or worse? Does it get worse at certain times of the day? What other symptoms besides pain are you having?
Quality weed, and even mids, aren't all that likely to be contaminated, as there's no need to increase potency or fuck with perfection. Schwag (brown or grass-green, no smell, lots of seeds, pressed, and ugly) is more likely to have come from a shady place in a large shipment and be weighed down or tampered with to increase potency. I've heard of dealers pissing on weed to increase weight, and even bought several bags from a past dealer that had obviously been re-wet because they they were so moldy they had to be thrown out! Talk about PISSED
Aside from glass/fiberglass, weed can be grown in less-than-ideal growing conditions, requiring lots of harsh chemical fertilizers to make it grow. This is often the case with hydroponic weed, which is grown in water using tons of fertilizers and the like.
Mold is a common contaminant of marijuana and can cause some SERIOUS complications (I speak from experience on that one). It doesn't have to be visible either, and to the untrained eye, it looks just like trichomes or white hairs.
Then there's weed that's just not dried and cured properly that burns the fuck out of your throat and chest when you hit it. Both this and the mold problem can be helped by storing your weed in a jar instead of a baggie, especially if you plan to have the same bag for a while.
Incidents like the glass thing, weed sprayed with Paraquat in the '70s, and even getting ahold of "laced" bud with other drugs in it is far less common than any of the above possibilities, but it's not unheard of. If you're having problems with your lungs, regardless of the cause, you need to be treated by a doctor ASAP. Even though the problem started with the weed, there's no way to be 100% sure that was the cause, so you don't need to mention it to the doctor unless he asks. If your current doc isn't helpful, go somewhere else. It does help to go in prepared, though. Keeping a "pain journal" of when your symptoms are worst, what the sensations are like, and other details will help your doctor see you're serious about this and aren't some idiot off the street.