EXCLUSIVE

Charlie Sheen will not go to trial in his legal battle with the National Enquirer -- it appears both sides have reached a settlement in the defamation case.

Charlie sued the Enquirer late last year over a story it published, claiming he raped a then 13-year-old Corey Haim on the set of the 1980s movie, "Lucas." Charlie denied the story, and Corey's mother also said it was BS.

According to docs filed in L.A. late last week ... Charlie's lawyers are asking for the suit to be dismissed with prejudice -- meaning it can't be refiled. That's typically a sign that they've struck a deal. Sources familiar with the situation tell us no money changed hands -- but both sides were fully satisfied with the terms.