I consulted the Encyclopedia of Theology, a Concise Sacramentum Mundi edited by Karl Rahner, and found a section headed ‘The Law in Paul’. Herein is found the answer to your question, and I now simply quote the relevant parts (with all emphases mine):
“Paul and Judaism see the law as an independent theological entity:
according to the claim of those who submit to it, it is an independent
way of salvation, in competition with faith in Jesus Christ.
While Paul leaves untouched the social conception of the law upheld in
Judaism, the salvific function of the law becomes a problem for his
theology… the law as a way of salvation must be excluded. Salvation
consists in the justice of God, i.e., in the fulfilment of the
promises made to the patriarchs. Whereas in Judaism justice is
achieved by the fulfilment of the law, Paul goes back to the close
connection of justice with faith in Gen 15:6 (Abraham) and, with the
help of scriptural proofs, is able to show that the promises, and
therefore their fulfilment also, are linked to this justification by
faith. The law, therefore, as a way of salvation is excluded because
those who observe it hope thereby to achieve righteousness, whereas
Scripture demonstrates that righteousness is linked with faith. Law
and faith (in Jesus Christ) are made exclusive alternatives. Paul goes
on to demonstrate that man could never have obtained righteousness by
the way of the law, for no one (as Paul postulates) can fulfil it
completely (Rom 3:20-30; Gal 3:10; 5:3; cf. 6:13). Hence all men come
under the curse which is the penalty threatened in Deut 27:26. But
Jesus alone can free man from this curse, for in him is promised the
opposite of the curse, the blessing for all peoples already promised
to Abraham…
From the time of Adam until Christ the power if sin prevailed,
activating the sphere of the sarx, and bringing the sinful works of
the flesh to light (von Dulmen), so that the power of sin signified
both the sinful act itself and also the state of bondage to sin, while
law assisted sin to gain power and life (1 Cor 15:56). For with the
advent of the law all became guilty of transgression. In contrast to
sin, however, law is only destructive in its effects and function, not
by nature. Sin avails of the law in order to kill. The law is the
catalyst which reveals the ruinous and hopeless state of man. But when
the curse of the law is concentrated upon Jesus he endures the penalty
of death, and thereby sets aside the demand of the law. For this
reason, and also because the law is no longer used to demonstrate the
presence of sin, Christ is the end of the law…
At present the law only has a part to play in bringing out the
obstinacy of the unbelieving section of Israel, which opens the way
for the Gentiles to be taken into the community (Rom 9:11).” Klaus
Berger, pp 828-829 (1981 edition)
That is why Paul did not boast in his Jewish heritage, but boasted in Christ and how faith in this risen saviour had set Paul free from bondage to the law, to be free in Christ. Paul exquisitely shows from the Hebrew scriptures how the law was a shadow pointing to Christ, the reality, so that both Jews and Gentiles putting faith in the finished work of Christ on the cross could have the chains of bondage (to sin and death – sarx ) smashed ( Col 2:13-232). That is why Paul said that he would preach nothing but Christ crucified, as the end of the law (1 Cor 1:23 & 2:2). His point was that all things must lead to the risen Christ, and the law served that purpose for those who did not see the preaching of the cross as ‘foolishness’ but as the power of God unto salvation (1 Cor 1:18, Eph 3:8).
This does not mean that Paul was lawless, or even that he took a light view of law-breaking. On the contrary, he shows in Romans 8:4 that "the righteousness of the law might be fulfilled in us" [Christians who walk after the Spirit.] He exposed as false those who accused him of despising the law (Antinomianism). See Romans 3:31 & 7:7-25.