This is a fascinating scene presented long before the greater revelations of Judgment that would be given to First Century believers. Although it wasn’t very clear to the psalmist, the Judge being referred to here would be the Messiah of Israel. Jesus said as much in John 5. (cf. John 5:22-29; also Matthew 25:31-32). This fact was later endorsed both by Peter (Acts 10:42) and Paul (Acts 17:31).
However, this particular judgment scene doesn’t seem to encompass all of mankind, but is apparently a judicial proceeding confined to those who had claimed to enjoy the benefits of being in covenant with God. This probably refers to Old and New Testament “believers;” but whatever the case may be, it is clear that the reality of their claimed relationship with God would be evidenced by the way they lived their lives. The Lord is quoted again later in this psalm: “But to the wicked God says, ‘What right have you to tell of My statutes and to take My covenant in your mouth? For you hate discipline, and you cast My words behind you.’” (Psalm 50:16-17)
Clearly there were those who claimed to be God’s people who had proven to be unfaithful. Charles Spurgeon held out no false hope for such unfaithful people. Of these two verses he writes the following:
“Do you dare to teach my law to others, and profane it yourselves? What impudence, what blasphemy is this! …You talk of being in covenant with me, and yet trample my holiness beneath your feet as swine trample upon pearls…
In these last days there are pickers and choosers of God’s words who cannot endure the practical part of Scripture; they are disgusted at duty, they abhor responsibility, they disembowel texts of their plain meanings, they wrest the Scriptures to their own destruction. It is an ill sign when a man dares not look a Scripture in the face, and an evidence of brazen impudence when he tries to make it mean something less condemnatory of his sins, and endeavors to prove it to be less sweeping in its demands. How powerful is the argument that such men have no right to take the covenant of God into their mouths, seeing that its spirit does not regulate their lives!”