Mel tells the story somewhat differently. According to him, he loved Bergman's idea but not his script. He brought Richard Pryor and a few others on board to overhaul it rather drastically. He says in fact that he couldn't have done it without Pryor. As for Young Frankenstein, he says that Gene showed him his draft, that he loved the idea immediately, and they spent the rest of the conversation working out the casting. It's true that the genesis of those two films came from elsewhere, but I've never heard Mel try to take credit for something he didn't do. He certainly has done enough; The Producers was one of the finest comedies ever made in Roger Ebert's opinion (and mine).
There's a good story about that too. According to Mel, he wrote the character of Max Bialystock right from the get-go with Zero Mostel in mind, but Zero, who was notoriously difficult to work with, didn't want to do it. So Mel enlisted his wife to nag him. Finally Zero called on the phone and growled, "Okay, you win, I'll do it. My wife talked me into it."
As far as I have been able to determine, the story about John Wayne is true too.
Another tidbit: Hackman's parting line, "Wait! Where are you going? I was going to make espresso!" was ad-libbed, like Estelle Reiner's line in When Harry Met Sally.
My favorite moments in Young Frankenstein (difficult to choose from among so many) are probably when Cloris Leachman is leading them up the stairs and tells them to stay close to the candles that aren't lit, and when Madeline Kahn arrives at the castle. Wilder turns to Feldman and says, "Igor, help me with the bags." Feldman drops into a Groucho Marx dialect and responds, "Soitenly. You take the blonde and I'll take the one in the turban."