But the law is not of faith, rather "The one who does them shall live by them." (Gal 3:12)Here Paul quotes from the Old Testament and tells us that the one who does the law will live. Not that the pesron who does them is given life by the law, but that the law is powerless to take the obedient one's life. The problem then with the law is not that it cannot reward, but that it cannot give righteousness. Paul in Romans says again very clearly that there is nothing wrong with the law, but the problem is with our sinful nature's reponse to the law.
The very commandment that promised life proved to be death to me. For sin, seizing an opportunity through the commandment, deceived me and through it killed me. So the law is holy, and the commandment is holy and righteous and good. Did that which is good, then, bring death to me? By no means! It was sin, producing death in me through what is good, in order that sin might be shown to be sin, and through the commandment might become sinful beyond measure. (Rom 7:10-13)The point is this:
Those who deny Christ's active obedience continually level the charge that the law cannot give righteousness. I agree. But it can reward righteousness. Therefore, Christ, who should have been rewarded (blessed) by the law, since He kept it perfectly, became accursed by the law so that we might be found blessed by the law, not in our own righteousness, but in Christ's which He imputes to us.