
    488 P.2d 1001
    Frankie ATKINS, Appellant, v. STATE of Arizona, ex rel. Frank A. EYMAN, Warden, Arizona State Prison, Appellee.
    No. 2 CA-CIV 1006.
    
      Court of Appeals of Arizona, Division 2.
    Sept. 28, 1971.
    
      Frankie Atkins, in pro. per.
    Gary K. Nelson, Atty. Gen. by Jerry C. Schmidt, Asst. Atty. Gen., Phoenix, for appellee.
   KRUCKER, Chief Judge.

This appeal is from the trial court’s dismissal, without a hearing, of a petition for a writ of habeas corpus, which attacked a detainer warrant filed with the Arizona State Prison by the State of Illinois. The ground of dismissal was that, as stated in the minute entry order, “[t]he court having been advised that the detainer mentioned in said Petition has been dropped * * No hearing was held and it appears from an examination of the record on appeal that no evidence of any kind was received by the trial court. Although mootness would appear to be a basis for dismissal of the petition, in that the imprisonment or restraint complained of no longer was being applied to the petitioner, Hunt v. Eyman, 405 F.2d 384 (9th Cir. 1968) , the trial court cannot take proof of this fact extrajudicially. Such a procedure is pregnant with all the evils of hearsay evidence and is further not subject to objection. Proof thereof would appear to be a simple and short matter. Such a state of the record would require reversal save for the conclusions we reach below. _

If a trial court reaches the correct result, but for the wrong reason, an appellate court is bound to affirm. City of Tucson v. Morgan, 13 Ariz.App. 193, 475 P.2d 285 (1970). Such is the case here in that, first, the detainer under attack here was not the cause of the imprisonment or restraint of the petitioner, with the result that it could not be the object of an attack by habeas corpus under A.R.S. § 13— 2001. Petitioner is imprisoned or restrained by reason of his Maricopa County-sentence here.

Secondly, the attack on the detain-er raises the question of the petitioner’s constitutional right to a speedy trial under Dickey v. Florida, 398 U.S. 30, 90 S.Ct. 1564, 26 L.Ed.2d 26 (1970) and Smith v. Hooey, infra. Such a question should be determined in the demanding state (Illinois) under United States ex rel. Tucker v. Donovan, 321 F.2d 114 (2d Cir. 1963) ; see, Rogers v. Boies, 106 Ariz. 468, 478 P.2d 92 (1970). The reasoning here is that proof of the performance vel non of Illinois’ “constitutional duty to make a diligent, good-faith 'effort to bring [the accused] before the * * • * court for trial,” under Smith v. Hooey, supra, is more easily and economically had in Illinois. The procedure used in Smith was a mandamus action, which sought an order to show cause why the pending charge should not be dismissed. Such a procedure was well chosen.

Where a petitioner for habeas corpus relief is not entitled to relief, a hearing is not required, Landers v. State ex rel. Eyman, 7 Ariz.App. 197, 437 P.2d 681 (1968). The trial court reached the correct result, but for the wrong reason. Of course, proper proof of the withdrawal of the detainer here would also have been a valid ground for dismissal, if the jurisdictional problems were solved.

Affirmed.

HATHAWAY and HOWARD, JJ, concur. 
      
      . We do not decide here that a detainer can he attacked by habeas corpus. See, infra.
      
     
      
      . We are not unmindful of the effect detainers have administratively upon prisoners against whom they are lodged, see. Smith v. Hooey, 393 U.S. 374, 89 S.Ct. 575, 577, n. 8, 21 L.Ed.2d 607 (1969). but do not feel constrained to hold that such effects amount to a restraint, in view of the fact that the better practice in attacking detainers is by action in the demanding state (Illinois here), as in Smith. See discussion, infra. The most enlightened approach to the problem of detainers is use of the Agreement on Detainers, enacted in Arizona as A.R.S. § 31 — 481, as amended. Unfortunately, Hlinois has not enacted this legislation and the Illinois detainer cannot be processed thereunder; some 18 other jurisdictions have enacted the agreement.
     