Merlin, Prospero, Soumaoro, Circe, Mimir, all predate Gandalf, and every character I just mentioned, in D&D terms, vaguely inhabits the "wizard" archetype.
Despite this, no iteration of Dungeons & Dragons™ could successfully approximate them in play. They are inspirations that the game draws...