Nothing contained in this chapter shall be construed to restrain the power of any court to issue a writ of habeas corpus when necessary to bring before them any prisoner for trial, in any criminal case lawfully pending in the same court, or to bring any prisoner to be examined as a witness in any action or proceeding, civil or criminal, pending in such court, when they think the personal attendance and examination of the witness necessary for the attainment of justice.

Terms Used In New Mexico Statutes 44-1-36

  • Habeas corpus: A writ that is usually used to bring a prisoner before the court to determine the legality of his imprisonment. It may also be used to bring a person in custody before the court to give testimony, or to be prosecuted.
  • Trial: A hearing that takes place when the defendant pleads "not guilty" and witnesses are required to come to court to give evidence.
  • Writ: A formal written command, issued from the court, requiring the performance of a specific act.