Section 521(3) in Bharatiya Nagarik Suraksha Sanhita, 2023
(3)A High Court may, if it thinks fit, direct that a prisoner detained in any jail situate within the State be brought before a Court-martial for trial or to be examined touching any matter pending before the Court-martial.[Similar to Section 475 from Old CrPC-Also Refer]