
416 N.W.2d 253 (1987)
227 Neb. 165
Sandy Patrick KERNS, Sr., Appellant,
v.
Gary GRAMMER, Warden, Nebraska Penal and Correctional Complex, Appellee.
No. 87-191.
Supreme Court of Nebraska.
December 11, 1987.
*254 Dennis R. Keefe, Lancaster County Public Defender, and Richard L. Goos, Sp. Deputy Lancaster County Public Defender, for appellant.
Robert M. Spire, Atty. Gen., and Steven J. Moeller, for appellee.
HASTINGS, C.J., BOSLAUGH, WHITE, CAPORALE, SHANAHAN and GRANT, JJ., and COLWELL, District Judge, Retired.
CAPORALE, Justice.
The court below sustained the demurrer of appellee, Gary Grammer, warden at the Nebraska Penal and Correctional Complex, denied the motion of appellant, Sandy Patrick Kerns, Sr., to amend his petition "to present action as both habeas corpus and post conviction," and dismissed Kerns' petition, which sought a writ of habeas corpus. Kerns' 10 assignments of error merge to question the (1) denial of his motion to amend, (2) determination that the rule enunciated in State v. Ellis, 214 Neb. 172, 333 N.W.2d 391 (1983), was not applicable to him, and (3) failure to hold the Nebraska habitual criminal statute, Neb.Rev.Stat. § 29-2221 (Reissue 1985), unconstitutional as applied to him. We affirm.
According to the petition Kerns was sentenced in 1975 to concurrent prison terms of 10 years on a rape conviction and 5 to 10 years on a robbery conviction. The convictions resulted from one continuing criminal episode taking place during a single day and were the subject of a single arrest and information. Later, in 1978, and while serving the aforesaid sentences, Kerns was treated as a habitual criminal under the provisions of § 29-2221 and sentenced to imprisonment for a period of 12 to 15 years for a first degree sexual assault on his cellmate.
The relevant portion of § 29-2221 then provided, as it does now:
(1) Whoever has been twice convicted of crime, sentenced and committed to prison, in this or any other state, or by the United States, or once in this state and once at least in any other state, or by the United States, for terms of not less than one year each, shall, upon conviction of a felony committed in this state, be deemed to be an habitual criminal, and shall be punished by imprisonment in the Department of Correctional Services adult correctional facility for a term of not less than ten nor more than sixty years; Provided, that no greater punishment is otherwise provided by statute, in which case the law creating the greater punishment shall govern.
We determine first whether the Ellis rule, discussed later in this opinion, applies to Kerns, and if not, whether § 29-2221 is unconstitutional as applied to him, for if the Ellis rule does not apply and § 29-2221 is constitutional as applied to Kerns, it matters not whether the trial court erred in failing to permit Kerns to amend his petition.
*255 In considering the applicability of the Ellis rule to the situation presented in this case, it is useful to bear in mind the chronology of related opinions of this court and of the U.S. Eighth Circuit Court of Appeals. The first of these is State v. Kerns, 201 Neb. 617, 271 N.W.2d 48 (1978) (Kerns I), in which Kerns appealed his 1978 sentence and unsuccessfully argued that the loss of "good time" in an administrative proceeding and the subsequent criminal conviction constituted double jeopardy in violation of provisions of the U.S. Constitution and that his sentence of 12 to 15 years under § 29-2221 was excessive. This court next considered State v. Pierce, 204 Neb. 433, 283 N.W.2d 6 (1979) (Pierce I), and held that two prior offenses which were committed on the same date, prosecuted in the same information, and resulted in concurrent sentences could be treated as two separate convictions for the purpose of enhancing a sentence under § 29-2221.
Some years later, the eighth circuit court considered Kerns v. Parratt, 672 F.2d 690 (8th Cir.1982) (Kerns II), which challenged § 29-2221 on constitutional separation of powers, due process, and eighth amendment grounds. The federal court rejected all of Kerns' constitutional challenges.
The following year we, in State v. Ellis, 214 Neb. 172, 333 N.W.2d 391 (1983), rejected the rule announced in Pierce I and reinterpreted § 29-2221(1) by holding that "in order to warrant the enhancement of the penalty under ... § 29-2221, the prior convictions, except the first conviction, must be for offenses committed after each preceding conviction, and all such prior convictions must precede the commission of the principal offense." 214 Neb. at 176, 333 N.W.2d at 394. We explained that
the purpose of enacting the habitual criminal statute is to serve as a warning to previous offenders that if they do not reform their ways they may be imprisoned for a considerable period of time, regardless of the penalty for the specific crime charged.... "`Recidivist statutes are enacted in an effort to deter and punish incorrigible offenders. * * * They are intended to apply to persistent violators who have not responded to the restraining influence of conviction and punishment.' ..."
Id. at 175, 333 N.W.2d at 394. We did not at that time consider whether the Ellis rule and rationale would be applied retroactively to persons whose sentences had been enhanced under the rule applied in Pierce I.
Pierce himself invited us to consider that question in State v. Pierce, 216 Neb. 792, 345 N.W.2d 835 (1984) (Pierce II). Contrary to Kerns' apparent misunderstanding of Pierce II, we declined that invitation. Although we noted that "it has been stated in federal law that there is no constitutional objection to overruling a case purely prospectively as we did in Ellis," 216 Neb. at 795, 345 N.W.2d at 836-37, we said, "While many courts, including the U.S. Supreme Court, have struggled with the question of retroactivity, this court does not have to tackle such a matter of judicial policy and past precedents, because the statutory requirements for relief under the Post Conviction Act have not been met." Id. at 795, 345 N.W.2d at 837. Under the apparent erroneous assumption that Pierce II specifically refused to grant retroactive application to the Ellis rule, Kerns devotes a considerable portion of his brief in an attempt to distinguish the situation presented by this appeal from that presented by Pierce II. Kerns argues that
applying the Ellis ruling to the facts of his case would not be a retroactive application of Ellis. Plaintiff is still serving the time imposed upon him under the terms of the habitual criminal law. If the Court were to grant him relief at this time, that would not be a "retroactive" application of the rule in Ellis. Quite clearly, it would be a prospective application. All the Court need do is reverse this case and return it to the trial court for a determination of whether or not defendant qualified under the statute, as interpreted in Ellis, to be classified as an habitual criminal. And if he should not have been found to be an habitual criminal, relieving him from serving his penal term or the balance thereof in the future is very simply a prospective application of Ellis.

*256 (Emphasis in original.) Brief for Appellant at 9-10. This is an interesting use of words, but an utterly meaningless argument. In asking this court to apply the 1983 Ellis decision to declare his 1978 sentence void, Kerns is obviously asking this court to give Ellis retroactive effect.
Kerns also argues that
[w]hen the Court interpreted the statute in Ellis, the ruling of the Court and that interpretation became a part of the statute just the same as if the legislature had put the ruling into the statute in the first place. The Court was simply saying what the intent of the legislature was when it passed the habitual criminal statute.
. . . . .
Plaintiff submits that his case is one in which the trial court lacked the authority to punish him in the manner of an habitual criminal....
Brief for Appellant at 10-11. That argument seems to suggest that § 29-2221 sets out punishment for the status of habitual criminal; this, however, is not the case. Consistent with principles long recognized in this state, Kerns was punished in 1978 for the crime of sexually assaulting his cellmate, and his sentence for that crime was determined through application of § 29-2221 to the facts of his criminal history. State v. Luna, 211 Neb. 630, 319 N.W. 2d 737 (1982); State v. Losieau, 184 Neb. 178, 166 N.W.2d 406 (1969). Later, in Ellis, this court laid down a rule for application of § 29-2221 which, had it existed when Kerns was sentenced, would have precluded application of the statute to his case. However, under the rule which existed at the time, Kerns was properly sentenced.
As this court noted in Pierce II, "retroactive operation of an overruling decision is neither required nor prohibited by constitutional provisions." Pierce II, supra 216 Neb. at 795, 345 N.W.2d at 836. Retroactive application of a new rule of law is appropriate when it is aimed at enhancing the accuracy of criminal trials, when there has not been justifiable reliance on a prior rule of law, and when retroactive application will not have a disruptive effect on the administration of justice. State v. Clark, 217 Neb. 417, 350 N.W.2d 521 (1984). In Clark, this court reasoned that the rule requiring that a defendant pleading guilty be informed of certain rights and that a voluntary and intelligent waiver of those rights affirmatively appear on the record was not aimed at the evil of mistaken determinations of guilt, but at the uninformed relinquishment of constitutional rights, and consequently would not be applied retroactively. Similarly, the retroactive application of Ellis which Kerns seeks is not aimed at correcting any deficiency in the trial which determined him guilty of first degree sexual assault, but would go only to the manner in which his sentence was calculated. We therefore conclude that the Ellis rule is not to be applied retroactively and is not to be applied to Kerns.
Kerns' argument that § 29-2221 is, in any event, constitutionally infirm as denying him of fundamental fairness, equal protection, and federal due process of law is equally without merit. Section 29-2221 has repeatedly been held not to conflict with provisions of either the Nebraska or the U.S. Constitution in decisions both of this court (e.g., State v. White, 209 Neb. 218, 306 N.W.2d 906 (1981) (due process challenge); State v. Goodloe, 197 Neb. 632, 250 N.W.2d 606 (1977) (cruel and unusual punishment and double jeopardy challenges), overruled on other grounds State v. Clifford, 204 Neb. 41, 281 N.W.2d 223 (1979); State v. Graham, 192 Neb. 196, 219 N.W.2d 723 (1974) (cruel and unusual punishment challenge); State v. Martin, 190 Neb. 212, 206 N.W.2d 856 (1973) (due process challenge); State v. Losieau, supra (due process and equal protection challenges)), and of the U.S. Eighth Circuit Court of Appeals (e.g., Fowler v. Parratt, 682 F.2d 746 (8th Cir.1982) (U.S. Const. amend. VIII cruel and unusual punishment challenge); Pierce v. Parratt, 666 F.2d 1205 (8th Cir.1981) (separation of powers, due process, equal protection, U.S. Const. amend. VIII challenges); Goodloe v. Parratt, 605 F.2d 1041 (8th Cir.1979) (U.S. *257 Const. amend. VIII challenge); Brown v. Parratt, 560 F.2d 303 (8th Cir.1977) (U.S. Const. amend. VIII challenge); Martin v. Parratt, 549 F.2d 50 (8th Cir.1977) (due process, equal protection, and U.S. Const. amend. VIII challenges)).
Habeas corpus is available as a remedy to a person held pursuant to a judgment of conviction only upon a showing that the judgment, sentence, and commitment are void; persons lawfully convicted of crime are excepted from the benefits of the statutory right to the writ. Anderson and Hochstein v. Gunter, 226 Neb. 724, 414 N.W.2d 281 (1987). Similarly, postconviction relief is available only when a constitutional right has been infringed or violated. State v. Jackson, 226 Neb. 857, 415 N.W.2d 465 (1987); State v. Lytle, 224 Neb. 486, 398 N.W.2d 705 (1987); Neb.Rev.Stat. § 29-3001 (Reissue 1985). Since the 1978 judgment, sentence, and conviction are not void and suffer from no constitutional infirmity, the petition did not, and could not, state a cause of action for either a writ of habeas corpus or for postconviction relief. Therefore, whether the trial court erred in failing to permit the amendment Kerns sought becomes immaterial, and we do not concern ourselves with that issue.
AFFIRMED.
