I was thinking a similar thing a short time ago.
Of the four main roles that are commonly perceived as being needed in a D&D party (Fighter, Rogue, Cleric, Wizard), only two are really necessary. Wizard/Cleric is a totally arbitrary and unecessary seperation, and the Rogue's focus, skills, can easily be folded into any other role.
That distinction between combat classes. skill classes, and magic classes, is not very indicative of the current game anyways. In all of the various rule supplements, there are many classes which break these boundaries and don;t exist in any one role.
However, I think the game might be a little better (and more flexible) if every class got the same number of skill points, except had different class skills, so that when a skill becomes necessary, it is not always the same character who is in the limelight.
This is something of a sidetrack, but if you want to count real roles, rather than the classic roles of D&D, there are about 5 or 6 that I can think of. First, there would be the three classic miltary roles: infantry, archers, and cavalry. Second would be the spy/assassin/scout type. Third would the fantasy genre necessity of the spellcaster. Finally, there may or may not be a place for a wholly diplomatic/aristocratic type of character.
Thus, the roles would be:
Melee tank (melee weapons and ability to absorb damage, normal fighters and warblades)
Ranged fighter (ranged weapons and damage capability, not filled well in D&D)
Mounted combat specialist (people who can ride mounts, very much not seen in D&D)
Rogue types (people who attack from the shadows, rogues, ninjas, and assassins)
Spellcasters (people who are physically fragile but use magic, wizards, bards, and druids)
Other (non-combatants, diplomats, and strange hybrids of roles, I suppose)
The big problem with D&D is that is lumps the first three of these roles into the same class, fighter, even though they really are as different from each other as they are from spellcasting. It also artificially distinguishes Rogue types by also making them skill-monkeys, even though that is not necessary.
edit: Actually, I just had an interesting thought. The roles of archer and spellcaster are in fact quite similar (person who must be protected and does a lot of damage at range), especially in the case of destructive spellcasters. In many places (videogames, really), the two are almost indistiguishable.
So, in that case, the roles would be split into:
Melee tanks
Archers and offensive spellcasters
Cavalry
Support spellcasters (bards and maybe clerics)
Rogue types
I find myself questioning more and more the distinction between rogue and the first two categories, but I suppose any attempt at assigning roles is not going to be perfect.