Well, that's interesting. I don't have a Due, so I compiled for a Mega. That works just fine.
I just tried that example for the Mega, and it compiles. So, I tried compiling for the Due, even though I don't have one. It fails, just like it fails for you.
I think you need to move this to the Due part of the forum.