I couldnt even test the benefits of your patch (using Xfree86+Mesa headers here, no complain from the compiler)
Yeah I know, on my box there is no complaints either... But well, to be on the safe side, I remove all 'typedefs' from the auto-generated files to be sure to never have this issue again ;-)
Lionel