delivered the opinion of the court.
The plaintiff in error, hereinafter referred to as defendant, was charged with statutory rape. A verdict of guilty was returned by the jury, and defendant was sentenced to the state reformatory. To review that judgment he prosecutes this writ of error.
The information alleges that the crime was. committed on February 20, 1921, and against a female person, therein named, under the age of eighteen years. At the trial, the prosecuting witness was permitted to testify, over the objection of defendant, that on November 13, 1921, she gave birth to a child. This was evidence that the prosecuting witness had sexual intercourse with some man. Laycock v. People, 66 Colo. 441, 182 Pac. 880; 33 Cyc. 1476. The prosecutrix also testified that the defendant was the father of the child. The defendant had the right to adduce evidence showing that the sexual intercourse, proved by the evidence above mentioned, was not had with him, and‘that the child was begotten by another man. The defendant’s right, under such circumstances, is stated in Fuller v. State, 23 Ariz. 489, 205 Pac. 324, as follows:
“Stated shortly and simply, he had a right to account for the result, i. e., the child, by showing that it was due to another cause, i. e., the sexual intercourse of another. His right to do this was coequal with the right of the state to support the allegation of rape by showing the outcome of the act. If appellant could show that he was not the father of the child directly charged to be his, it was most material to his defense, and he should be allowed to prove *194it by all relevant evidence. There is no dissent in the authorities from these propositions.”
The defendant sought to prove by the witness Sarno that the latter had sexual intercourse with the prosecutrix on a certain occasion which the witness had described as having occurred “in January or February, 1921.”
After being advised by the court that he is privileged to refuse to answer questions if the answers would tend to incriminate him, the witness nevertheless testified that he was riding in an automobile with the prosecutrix and three other boys; that one of them suggested sexual intercourse and that “she said all right and the rest of us boys stepped out of the machine.” Counsel for the defendant then proposed to ask the witness whether on that occasion he had sexual intercourse with the prosecuting witness. The court refused to permit the asking of this question in the presence of the jury. The jury was sent out of the room, and while the jury was out the question was then asked. Before an answer was given the court again advised the witness as to his privilege against self-incrimination, and the witness stated that he would refuse to answer. Counsel for defendant then proposed to ask the question in the presence of the jury. The court denied that request, and sustained the objection of the deputy district attorney to it. This ruling is assigned as error.
From what has been stated in an earlier part of this opinion, it clearly appears that the proposed question was competent, and also that a responsive answer would be competent evidence. The mere fact that the answer to a question might criminate the witness does not render the question improper, because it is the privilege of the witness to refuse to answer it. 28 R. C. L. 428, sec. 13. This court has held that the privilege can only be claimed by the witness himself. Lothrop v. Roberts, 16 Colo. 250, 27 Pac. 698; Barr v. People, 30 Colo. 522, 71 Pac. 392. The district attorney could not indirectly claim the privilege for the witness by objecting to the question. It was error to sustain the objection to the question.
*195It was also error to refuse to permit the question to be asked in the presence of the jury. The defendant had the right to a trial by jury, and to compel the attendance of witnesses in his behalf. The right to a trial by jury includes the right to have the jury present when competent questions are propounded to a witness. While a witness may refuse to answer if the answer would tend to incriminate him, yet the privilege does not bar the asking of the question. In 40 Cyc. 2541, it is said:
“The privilege is not violated by merely asking the witness a question which he refuses to answer.”
The privilege is “an option of refusal and not a prohibition of inquiry.” Wigmore on Evidence, section 2268. The time for claiming the privilege is “upon the asking of the question which the witness fears he may incriminate himself by answering.” 40 Cyc. 2549.
The prosecuting witness testified on cross examination that defendant was in her room every night, except one, in February, 1921. Counsel for defendant then asked the witness whether or not anyone else was “up there” within that time, and the witness answered that one other person was there, on one occasion, with the defendant. The trial court refused to permit defendant to ask questions laying the foundation for impeachment of the witness on the point whether still other men were ever in her room in February, 1921 and also on the point whether the defendant was present every night, as she had testified. The prosecution itself, by showing the birth of a child in November, 1921, made it material whether another than defendant was the father of the child, and who was in the room of the prosecutrix in February, 1921, and when defendant was there, were relevant matters. A witness may be impeached as to credibility by showing conduct on his part inconsistent with his testimony. 40 Cyc. 2581. So the witness, in the instant case, could be impeached by showing either that the defendant was not present or that other persons were present in her room, facts which, if shown, would be inconsistent with her testimony that *196no one was there except the defendant. In order to warrant the introduction of evidence as to the conduct of a witness tending to discredit him or her, a foundation must be laid by interrogation as to matters which it is proposed to show. 40 Cyc. 2582. The defendant was entitled to lay the foundation for impeachment by interrogating the witness with reference to persons who would be shown, by the contradicting evidence of defendant, to have been present in the room of prosecutrix, and with reference to facts which would show that defendant was not present. The rules that relate to impeachment by variant statements are applicable to impeachment by variant acts so far as in their nature applicable to acts. 7 Enc. of Evidence, 149. A witness’ acts variant from his testimony on the stand may ordinarily be shown to impeach him. Id. Occurrences at which the witness was present may be treated under the same rules as apply to acts. It is, of course, fundamental that the impeachment of a witness must be upon a matter material to the issue on trial. King v. People, 64 Colo. 398, 172 Pac. 8. The materiality of the impeaching evidence is not questioned in the instant case. For the reasons above indicated it was error to refuse to permit the defendant to lay the foundation for impeachment.
The Attorney General does not, in the brief, contend against this conclusion, but argues, in effect, that the error was harmless because, it is said, the impeaching evidence would have been only cumulative to other evidence. Impeaching evidence is not strictly speaking, evidence cumulative to evidence on material issues, but is a means used to exercise the right, which every party has, to impeach or discredit a witness. Where, as in the instant case, the evidence of the parties is directly conflicting, it is prejudicial error to exclude impeaching evidence, or to prevent the impeachment of a witness. 4 C. J. 961, note 25.
The judgment is reversed, and the cause remanded for new trial.