See, to Luther it was not just a matter of what the Law said (content). It was a matter of what the Law is for. He was concerned with the use of the Law, it's function. Likewise, the Gospel had a function. To Luther, the words of the Law or the Gospel were not merely content. They did something. They produced something, or at least they were intended to. There was an end that they were intended to effect.
The Law, Luther said, had its main function in convicting man of sin. It is true that Luther also saw it having a civil component to restrain evil in human society. But the main function of the Law was to drive a man to silence, to drive him to despair in his own good works, self-styled living, and pseudo-pious spiritual aspirations. It was intended to make a man realize that there is no hope of heaven, of right-ness with God, whatsoever within himself, thereby pressing him to look outside of himself for an Answer, a Savior.
The Gospel is that Answer -or more precisely, the Gospel presents Jesus as that answer. The function of the Gospel is to lift the spiritually lost and hopeless out of death and give him life and assurance and peace and hope and freedom and joy and... God.
The understanding of the "uses" of Law and Gospel has profoundly practical and pastoral implications. For example, if a man comes to you despairing of all hope, like the Philippian jailer, saying "What must I do to be saved?" you would not give this man Law. The Law, the voice which speaks condemnation and curse, which shows the man that his delusion of a spiritual ladder to heaven is a deadly fantasy, that exposes his helplessness before Almighty YHWH, has already done its work. However, if a man, like the rich young ruler, comes saying, "What must I do to inherit eternal life?" one can discern a difference -not in the words (which are almost identical)- but in the "place" the man is at. To this man, Jesus' provoking answer was essentially Law. It cut the man down, and it needed to. It did not assure or promise, it exposed.
For a man to really see Jesus as a Savior (and not a teacher or divine assistant to give us a better life), he must really see that he needs to be saved.
In Luther's own words (from his Declaration in his commentary on Paul's epistle to the Galatians):
A wise and faithful disposer of the Word of God must so moderate the law that it may be kept within its bounds. He that teaches that men are justified before God by the observation of the law, passes the bounds of the law, and confounds these two kinds of righteousness, active and passive. Contrariwise, he that sets forth the law and works to the old man, and the promise and forgiveness of sins and God’s mercy to the new man, divides the Word well. For the flesh or the old man must be coupled with the law and works; the spirit or the new man must be joined with the promise of God and His mercy.
When I see a man oppressed with the law, terrified with sin, and thirsting for comfort, it is time that I remove out of his sight the law and active righteousness, and set before him, by the gospel, the Christian or passive righteousness, which offers the promise made in Christ, who came for the afflicted and sinners.
But I do not believe this concept of "function" is limited only to Law and Gospel. Take the following two examples:
1. The passages which console and promise versus the passages that warn and admonish. If I think of the New Testament, for example, there are passages that encourage and promise hope and give assurance and security. There are passages that tell us, "the one who comes to Me I will never cast out," and "no one is able to pluck [my sheep] out of my hand," and "nothing is able to separate us from the love of God that is in Christ Jesus." But there are also passages in those same gospels and epistles which warn us solemnly to not walk away from Jesus. There are passages, such as in Hebrews, which can terrify. How can both be reconciled? Should I be assured or not? Should I be constantly worried? How assured can I be, or does God hope to keep us in suspense?
I believe this is a matter of function, again. There is a use, a purpose to these statements. Perhaps the assuring passages are intended to comfort and lift up the sore, discouraged, struggling, frightened, and afflicted while the warning passages are intended to bump the straying sheep back to Jesus while leaving the goats without excuse. It is something of that nature.
2. The passages which speak of God's complete sovereignty in salvation, God's election, versus the passages which speak of man's choice and responsibility and open opportunity to trust in Jesus, to be saved. Some passages are so strong in their statements about God's sovereign choice and authorship over salvation that it seems like one should either try to find out if they are elect or not or just give up and realize it is out of your hands. Other passages are so strong in their statements about the openness and universality of the Gospel that one can scarcely reconcile how God sovereignly chooses.
But again, I think it is a matter of function. In John 6, I believe Jesus' statements, though both of these allegedly opposing ideas were intertwined, were meant to be a sort of rebuke or denunciation of his listeners. To tell them to their face that they are unable to come to Him was to unflinchingly shatter their spiritual pride and point out their blindness in one swoop. Yet there are other times, such as in Romans 8, where the doctrine of election is intended to comfort the suffering and encourage them to hang in there through the dark night.
I didn't spend a lot of time trying to spell out the various uses and where they correspond. I simply want to point out that function is important -just as important as content. Lots of times I see people torturing themselves over particular passages, condemning and terrifying themselves that they are not "good enough" Christians to be saved, and I believe the key is not merely to show them the context of the said passage in light of the immediate context and the broader context of the Gospel; I believe the key is also in showing them that there is a use for the passage, and it has already done it's work in them. Misusing the content of Scripture will lead to misguided and disastrous effects.