No judge shall be competent to testify in any criminal or civil proceeding as to any matter which came before him in the course of his official duties. Except as otherwise provided in this section, no clerk of any court, magistrate, or other person having the power to issue warrants, shall be competent to testify in any criminal or civil proceeding as to any matter which came before him in the course of his official duties. Such person shall be competent to testify in any criminal proceeding wherein the defendant is charged with perjury or pursuant to the provisions of § 18.2-460 or in any proceeding authorized pursuant to § 18.2-460 . Notwithstanding any other provision of this section, any judge, clerk of any court, magistrate, or other person having the power to issue warrants, who is the victim of a crime, shall not be incompetent solely because of his office to testify in any criminal or civil proceeding arising out of the crime. Code 1950, §§ 19.1-267, 19.1-268; 1960, c. 366; 1975, c. 495; 1976, c. 269; 1989, c. 738; 1990, c. 602; 2015, c. 18.2-460 .
|