The expression too difficult a task sounds a little pompous, but it doesn't sound ungrammatical. According to my folk-beliefs about English grammar, determiners precede adjectives. However, the expression too difficult a task seems to controvert that belief.
Additionally, the expression too difficult of a task seems grammatical too.
- Under what conditions may determiners precede adjectives?
- Are there conditions under which too difficult of a task would be a more grammatical expression than too difficult a task would be?
(This question does not ask what the question “How big of a problem” vs. “how big a problem” asks. That question does not pertain to determiners.)