
12 Cal.Rptr.3d 478 (2004)
117 Cal.App.4th 1065
The PEOPLE, Plaintiff and Respondent,
v.
Lonnie GIPSON, Defendant and Appellant.
In re Lonnie Gipson, on Habeas Corpus.
Nos. H025783, H027155.
Court of Appeal, Sixth District.
April 20, 2004.
Review Denied July 21, 2004.
*479 Sixth District Appellate Program, In association with Walter K. Pyle, for Defendant/Appellant.
Bill Lockyer, Attorney General, Robert R. Anderson, Chief Assistant Attorney General, Gerald A. Engler, Senior Assistant Attorney General, René A. Chacón, Supervising Deputy Attorney General, Jeremy Friedlander, Deputy Attorney General, for Plaintiff/Respondent.
PREMO, J.
Defendant Lonnie Gipson was found guilty at jury trial of one count of assault with a deadly weapon. In a court trial, two of the alleged Three Strikes priors were found true, two prior prison terms were found true, and two of defendant's three prior serious felony convictions were *480 found true. After a Marsden motion[1] to replace his attorney was denied, and a Romero motion[2] to strike the Three Strikes priors was granted to the extent that one strike was stricken, the court sentenced defendant to 17 years in state prison. On appeal, defendant claims that the Three Strikes provisions under which he was sentenced violate the contract clauses of both the federal and state constitutions. In a petition for a writ of habeas corpus which we have ordered considered with the appeal, defendant claims both trial and appellate counsel were incompetent for failing to raise the issue of the mental competency and what he asserts was the false testimony at trial of his brother and prosecution witness Wallace Gipson.

FACTS
Since defendant does not challenge the sufficiency of the evidence, we state the facts briefly. On December 8, 2001, at about 6:51 a.m., defendant's brother, Wallace Gipson (Wallace),[3] awoke to hear defendant arguing with Ijuana Tucker in the hall of their home. Tucker was yelling, "stop, stop." Wallace left his room to see defendant hitting Tucker with a beer bottle while she was trying to leave the residence. Wallace intervened. Defendant hit Wallace over the head with the beer bottle, which broke. Defendant advised Wallace to "mind your own business" while following him into his room and attempting to stab him with the broken end of the beer bottle. Wallace felt blood, looked in a mirror, and saw cuts and bumps on his face. He called the police. Wallace's injuries included lacerations to the head and face, a bump near the top center of his forehead, and a fracture in the first knuckle of his ring finger.

ISSUE ON APPEAL
Defendant claims the doubling of his base sentence from three years to six years under the Three Strikes law violates the federal and state contract clauses which prohibit states from passing laws impairing the obligation of contracts. (U.S. Const., art. I, § 10, cl. 1; Cal. Const., art. I, § 9.) According to defendant, his 1992 plea bargain was a contract between the State and him which the Legislature could not impair by subsequent enactments. (See Hall v. Wisconsin (1880) 103 U.S. 5, 26 L.Ed. 302.) The prior plea agreement "incorporated by reference Penal Code section 667 [as it existed then], which provided a recidivist penalty of 5 years for each prior serious felony and a one year enhancement for each prior prison term served. These incorporated terms were limited to these penalties which would occur upon the happening of a future event. This was the scope of the agreement [insofar] as it dealt with sentencing enhancements for possible future convictions." Defendant adds, "[t]he plea agreement was executed between [defendant] and the executive branch of the government (the prosecution) and [it was] judicially sanctioned. A third party (the legislature [sic]), which was not a party to the original contract, cannot at a future date make those agreements burdensome by retroactively applying new terms to a consummated deal."
*481 "Plea bargains are `"contractual in nature and must be measured by contract law standards."' ... The application of contract law to plea agreements is premised on `the notion that the negotiated guilty plea represents a bargained-for quid pro quo.'" (United States v. Escamilla (9th Cir.1992) 975 F.2d 568, 571.) "[I]mplicit in all of this is a process of `bargaining' between the adverse parties to the case-the People represented by the prosecutor on one side, the defendant represented by his counsel on the other-which bargaining results in an agreement between them." (People v. Orin (1975) 13 Cal.3d 937, 943, 120 Cal.Rptr. 65, 533 P.2d 193.) "The government must fulfill any promise that it expressly or impliedly makes in exchange for a defendant's guilty plea." (United States v. Ingram (7th Cir.1992) 979 F.2d 1179, 1184.)
It is well settled the existing applicable law is part of every contract, the same as if expressly referred to or incorporated in its terms. (Farmers Bank v. Fed. Reserve Bank (1923) 262 U.S. 649, 660, 43 S.Ct. 651, 67 L.Ed. 1157.) Defendant concludes the relevant Penal Code sections were an intrinsic part of his plea agreement, creating an enforceable obligation. "The obligation of a contract is the duty of performance according to its terms, the remedy or means of enforcement being a part of the obligation, which the States cannot by legislation impair." Defendant states "it is doubtful that [he] would have entered into a contract that could lead to the imposition of a future sentence of 25 years to life, or to a doubling of the base term."
"Both the United States and California Constitutions contain clauses prohibiting the Legislature from passing laws which impair the obligations in contracts. [Citations.] Although the language of both contracts clauses is facially absolute, it has been determined that their `prohibition[s] must be accommodated to the inherent police power of the State "to safeguard the vital interests of its people."' [Citation.] Thus, impairment of an existing contract is not necessarily unconstitutional." (20th Century Ins. Co. v. Superior Court (2001) 90 Cal.App.4th 1247, 1268, 109 Cal.Rptr.2d 611.) "`"`The constitutional prohibition against contract impairment does not exact a rigidly literal fulfillment; rather, it demands that contracts be enforced according to their "just and reasonable purport;" not only is the existing law read into contracts in order to fix their obligations, but the reservation of the essential attributes of continuing governmental power is also read into contracts as a postulate of the legal order. [Citations.] The contract clause and the principle of continuing governmental power are construed in harmony; although not permitting a construction which permits contract repudiation or destruction, the impairment provision does not prevent laws which restrict a party to the gains "reasonably to be expected from the contract." [Citation.]'"' [Citation.]" (Board of Administration v. Wilson (1997) 52 Cal.App.4th 1109, 1130-1131, 61 Cal.Rptr.2d 207.) Consequently, contracts are "deemed to incorporate and contemplate not only the existing law but the reserve power of the state to amend the law or enact additional laws for the public good and in pursuance of public policy, ..." (In re Marriage of Walton (1972) 28 Cal.App.3d 108, 112, 104 Cal.Rptr. 472.)
In 1982, by initiative measure, the people added Penal Code section 667 (hereafter section 667) increasing penalties for habitual criminals. (Initiative Measure, approved by the people, Jun. 8, 1982.)[4]*482 The section was amended three times, the most recently in 1994. (Stats.1994, ch. 12, § 1, eff. Mar. 7, 1994.) The provision of the amended statute to which defendant takes exception doubles the punishment for the current felony conviction because of the existence of a prior felony conviction. (§ 667, subd. (e)(1).)
The purpose of the Three Strikes law is to promote the state's compelling interest in the protection of public safety and in punishing recidivism. (People v. Castello (1998) 65 Cal.App.4th 1242, 1251, 77 Cal.Rptr.2d 314.) It accomplishes this by lengthening the sentences of recidivists, thus promoting public safety by removing recidivists from society for a longer period of time. It is clear the statute and its amendments were enacted for the public good and in pursuance of public policy.
Therefore, defendant's contract clause challenge fails. His plea bargain is "deemed to incorporate and contemplate not only the existing law but the reserve power of the state to amend the law or enact additional laws for the public good and in pursuance of public policy, ..." (In re Marriage of Walton, supra, 28 Cal.App.3d at p. 108, 104 Cal.Rptr. 472.) The plea bargain "vest[ed] no rights other than those which relate[d] to the immediate disposition of the case." (Way v. Superior Court (1977) 74 Cal.App.3d 165, 180, 141 Cal.Rptr. 383.) The 1994 amendment to section 667 did not affect the 1992 plea bargain; it did not create or destroy any substantive rights defendant had in the plea bargain. Subsequent to the plea bargain, the Legislature amended the law; defendant committed another crime; defendant became subject to the penalty described in the amended statute. The increased penalty in the current case had nothing to do with the previous case except that the existence of the previous case brought defendant within the description of persons eligible for a five-year enhancement for his prior conviction on charges brought and tried separately. There was no error.

WRIT PETITION
In his petition for a writ of habeas corpus filed in propria persona, defendant attacks trial counsel's failure to block the prosecution's use of the testimony of his drug-using, mentally disturbed brother Wallace to convict him and appellate counsel's failure to "disclose to the court of appeal's [sic] the false testimony used by the prosecution while coercing a mental patient to give false testimony to procure an indictment ... as well as to obtain a conviction."
Neither counsel failed in his or her duty to diligently represent defendant. Wallace's mental state was adequately disclosed to the jury via the testimony of defense witnesses (1) Johnny Gipson (Wallace's and Lonnie's brother) who advised Wallace to call the police when Wallace called twice around 2:00 a.m. on the morning of the incident to claim he and his niece Lynne Ramblin had been hurt by Lynne's boyfriend; Johnny testified that Wallace was "a nice guy but unstable"; (2) investigating Officer Michael Soqui who determined from Lynne and her boyfriend that no battery had occurred and who arrested Wallace for being under the influence of heroin and later noticed the smell of alcohol; (3) Lynne, who lived with Wallace, testified to his daily drug use and his temper tantrum that night because she refused to give him back $50 she had borrowed from him; (4) defendant's and Wallace's sister Rebecca Ramblin, who testified to Wallace's mental problems, his *483 seeing things including bats flying through the house, his hearing voices, his drug use, tantrums, stealing, and lying; and (5) Rensley Anthonymuthu who worked at the local Safeway where he saw Wallace panhandling at least twice a day and yelling at customers who failed to donate and getting agitated and angry.
A person is disqualified to be a witness if he or she is incapable of expressing himself concerning the matter so as to be understood or is incapable of understanding the duty of a witness to tell the truth. (Evid.Code, § 701.) As a general rule, every person, irrespective of age, is qualified to be a witness and no person is disqualified to testify to any matter. A person may be disqualified as a witness for one of two reasons: (1) the witness is incapable of expressing himself or herself so as to be understood, or (2) the witness is incapable of understanding the duty to tell the truth. The party challenging a witness bears the burden of proving a reason for disqualification, and a trial court's determination will be upheld in the absence of a clear abuse of discretion. (People v. Dennis (1998) 17 Cal.4th 468, 525, 71 Cal.Rptr.2d 680, 950 P.2d 1035.) The fact that a witness may have suffered from mental disorders does not by itself support the claim that he is incapable of communicating so as to be understood. If there is evidence that the witness has the capacities to perceive, recall, and narrate, the determination whether he in fact perceived and does recall is left to the trier of fact. (People v. Lewis (2001) 26 Cal.4th 334, 356, 110 Cal.Rptr.2d 272, 28 P.3d 34.)
In the instant case, testimony about factors affecting Wallace's competency including his drug and alcohol use, past mental hospitalizations and delusions, and his mental state at the time of the incident were adequately disclosed to the jury so as to allow it to judge Wallace's credibility. Defendant was not deprived of competent representation by counsel.

DISPOSITION
The judgment is affirmed. The petition for a writ of habeas corpus is denied.
WE CONCUR: RUSHING, P.J., and ELIA, J.
NOTES
[1]  People v. Marsden (1970) 2 Cal.3d 118, 84 Cal.Rptr. 156, 465 P.2d 44.
[2]  People v. Superior Court (Romero) (1996) 13 Cal.4th 497, 53 Cal.Rptr.2d 789, 917 P.2d 628.
[3]  Convenience, not disrespect, is intended by use of the parties' first names. (In re Marriage of Cheriton (2001) 92 Cal.App.4th 269, 280, 111 Cal.Rptr.2d 755.)
[4]  A substantially similar measure, Penal Code section 1170.12, was added by initiative measure in 1994. (Prop. 184, § 1, approved Nov. 8, 1994.)
