
68 Cal.Rptr.3d 518 (2007)
157 Cal.App.4th 324
In re Leonard James McSHERRY, on Habeas Corpus.
No. B199945.
Court of Appeal of California, Second District, Division Three.
November 28, 2007.
*519 Overland Borenstein Scheper & Kim and Mark E. Overland, Los Angeles, for Petitioner.
Edmund G. Brown, Jr., Attorney General, Dane R. Gillette, Chief Assistant Attorney General, Kristofer Jorstad and Chung L. Mar, Deputy Attorneys General, for Respondent.
KLEIN, P.J.
Leonard James McSherry seeks writ review of his conviction of an attempt to annoy or molest a child under the age of 18 years with a prior conviction of lewd act. (Pen.Code, §§ 664/647.6, subd. (c)(2).)[1] McSherry claims he was not timely prosecuted. A violation of the statute of limitations deprives the court of jurisdiction and may be raised at any time. (People v. Williams (1999) 21 Cal.4th 335, 339-340, 87 Cal.Rptr.2d 412, 981 P.2d 42.) We therefore issued an order to show cause to address the merits of McSherry's claim. Upon consideration of issue presented, we conclude McSherry was timely prosecuted and deny the writ petition.

FACTS AND PROCEDURAL BACKGROUND
On March 10, 2003, an elementary school yard supervisor saw McSherry masturbating in an automobile parked near tetherball courts where numerous third-graders were at play. The passenger side window, which was closest to the school-yard, was down and McSherry was looking in the direction of the children. When the school yard supervisor yelled at McSherry, he turned, appeared surprised and drove away. Although the children could have seen McSherry from their location, none actually did.
After a jury convicted McSherry of an attempt to annoy or molest a child under the age of 18 years with a prior conviction of lewd act, the trial court found McSherry had three prior convictions within the meaning of the "Three Strikes law" (§§ 667, subds. (b)-(i), 1170.12) and sentenced *520 him to a term of 25 years to life in state prison.
In People v. McSherry (2006) 143 Cal. App.4th 598, 49 Cal.Rptr.3d 389, we affirmed McSherry's conviction and rejected, inter alia, his argument the conduct underlying the conviction, absent the prior conviction allegation, constituted a misdemeanor. We concluded the prior conviction element of the offense was not an enhancement which had to be disregarded in determining the maximum punishment for the offense within the meaning of section 805, subdivision (a).[2] Thus, McSherry was timely prosecuted, notwithstanding the People's concession the information was not filed within one year of the commission of the charged offense.

CONTENTION
McSherry now raises a different limitations issue. Specifically, McSherry argues his conviction of an attempt to commit child annoyance did not trigger section 647.6, subdivision (c)(2), which he refers to as a "felony enhancement provision." Thus, the misdemeanor statute of limitations applies in this case and, because the prosecution was not commenced within a year of the offense, it was not timely.

DISCUSSION

1. The statutory construction of section 647.6.

Generally, child annoyance is a misdemeanor. Section 647.6, subdivision (a)(1), provides: "Every person who annoys or molests any child under 18 years of age shall be punished by a fine not exceeding five thousand dollars ($5,000), by imprisonment in a county jail not exceeding one year, or by both the fine and imprisonment."
However, where child annoyance is committed in a residential setting, it is an alternate misdemeanor/felony, sometimes referred to as a wobbler. Section 647.6, subdivision (b), provides that if the offense is committed "after having entered, without consent, an inhabited dwelling house, or trailer coach ..., or the inhabited portion of any other building," it is punished by imprisonment in the state prison, or in a county jail not exceeding one year.
Section 647.6, subdivision (c), provides that where the offense is committed by a recidivist offender, it is a felony. Section 647.6, subdivision (c)(1), provides that "upon the second and each subsequent conviction" of child annoyance, the offense is punished "by imprisonment in the state prison."
Section 647.6, subdivision (c)(2), in issue here, applies where the defendant has a prior conviction of various enumerated offenses, including lewd act in violation of section 288. Section 647.6, subdivision (c)(2), provides that, "Every person who violates this section after a previous felony conviction under Section ... 288, ... shall be punished by imprisonment in the state prison for two, four, or six years."

2. McSherry's contention.

McSherry contends section 647.6, subdivision (c)(2), applies only to individuals who are convicted of the completed offense of child annoyance. McSherry relies on the language of section 647.6, subdivision (c)(2), which states: "Every person who *521 violates this section after a previous felony conviction under section ... 288, ... shall be punished by imprisonment in the state prison for two, four or six years." (Italics added.) McSherry claims he did not violate "this section" because he was convicted only of an attempt to violate section 647.6, subdivision (a)(1). McSherry reasons that because only subdivision (a) of section 647.6 defines the elements of child annoyance, an attempt, which is a separate and distinct offense, is not a violation of "this section." (People v. Reed (2005) 129 Cal.App.4th 1281, 1283, 29 Cal.Rptr.3d 215.) McSherry argues section 664, the basic attempt statute, applies only when the defendant attempts to commit a specific crime. (People v. Toledo (2001) 26 Cal.4th 221, 229-230, 109 Cal.Rptr.2d 315, 26 P.3d 1051.) Because section 647.6, subdivision (c)(2) does not define a specific crime and fails to state that it applies to attempts, McSherry concludes the Legislature has made an intentional choice that attempts not be included in its proscription.

3. Resolution.

As demonstrated by the detailed description of section 647.6 set forth above, section 647.6 defines a "hybrid" offense, punished as either a felony or a misdemeanor depending on the presence or absence of enumerated aggravating factors. (See People v. Johnson (2006) 145 Cal. App.4th 895, 904, 51 Cal.Rptr.3d 893 [classifying indecent exposure in violation of § 314, a statute with a similar scheme as § 647.6, as a hybrid offense[3]]; People v. San Nicolas (1986) 185 Cal.App.3d 403, 407, 229 Cal.Rptr. 650 [former § 647a, the precursor of section 647.6, referred to as a hybrid offense].) McSherry's offense, attempted child annoyance with a prior conviction of lewd act, constitutes an attempt to commit a felony, namely, a violation of section 647.6, subdivision (c)(2). The prior conviction requirement of section 647.6, subdivision (c)(2) is the functional equivalent of an element of the offense. Because a violation of section 647.6, subdivision (c)(2), is a felony punishable by imprisonment in the state prison, an attempt to violate that section similarly is a felony. Thus, the applicable statute of limitations is three years. Consequently, we again find McSherry was prosecuted timely.

4. Specific references to attempts in other statutes not determinative.

McSherry notes many statutes make reference to attempts, e.g., sections 69 (deterring an executive officer), 102 (taking property from an officer), 107 (escape by felony inmate from reformatory or county hospital), 167 (recording jury deliberations), 181 (holding a person in involuntary servitude), 375, subdivision (a) (releasing an injurious gas or substance in a public place), 476 (forgery), 4530 (escape from prison) and 4532 (escape from jail). McSherry claims the absence of any reference to attempts in section 647.6 reflects an indication that attempts are not to be included.
This argument is not persuasive. By specifically addressing attempts in the statutes cited by McSherry, the Legislature has declared attempts to commit these offenses to be outside the purview of *522 section 664. Consequently, attempts to violate these statutes are punished as severely as the completed offense. Had attempts been included in the proscription of section 647.6, subdivision (c)(2), for example, by including the phrase, "Every person who violates or attempts to violate this section," the result would have been to punish attempts in the same manner as the completed offense. Nothing indicates the Legislature intended that result.
Rather, it appears the Legislature intended the standard attempt statute would apply. Indeed, the absence of any provision for an attempt in section 647.6 is explained by section 664, which specifically states it applies, "where no provision is made by law for the punishment of those attempts...." (§ 664.) As noted in People v. Medina (2007) 41 Cal.4th 685, 697, 61 Cal.Rptr.3d 677, 161 P.3d 187, "[A]ttempts of most crimes are not defined within a statute, but are governed by the general attempt statute.... [Citation.]" (Id, at p. 697, 61 Cal.Rptr.3d 677, 161 P.3d 187.) Thus, attempts to violate section 647.6, subdivision (c)(2), are punishable under the general attempt statute.
In this case, had McSherry not been punished under the Three Strikes law, his punishment would have been determined under the general attempt statute (§ 664) as one-half of the term generally applicable upon a violation of section 647.6, subdivision (c)(2), namely, two, four or six years in state prison.

5. The enhancement cases cited by McSherry are inapt.

McSherry cites numerous cases involving enhancements or limitations on an otherwise available statutory right. McSherry urges these cases provide support for his argument that, because attempts are not expressly mentioned in section 647.6, subdivision (c)(2), only the completed offense of child annoyance triggers the felony punishment provision.
These cases include People v. Lewis (2006) 146 Cal.App.4th 294, 298, 53 Cal. Rptr.3d 40 [the provision of section 1203.4 excluding persons convicted of violating section 288 from expunging their convictions did not apply to individuals convicted of attempts to violate section 288]; People v. Reed, supra, 129 Cal.App.4th at page 1285, 29 Cal.Rptr.3d 215 [three-year enhancement for prior drug offense under Health and Safety Code section 11370.2 did not arise upon conviction of attempted possession of a controlled substance]; People v. White (1987) 188 Cal.App.3d 1128, 1138, 233 Cal.Rptr. 772 disapproved on other grounds in People v. Wims (1995) 10 Cal.4th 293, 314, footnote 9, 41 Cal.Rptr.2d 241, 895 P.2d 77 [three-year enhancement pursuant to section 667.8 not applicable where defendant convicted of attempted rape because the statute did not expressly include attempts]; People v. Le (1984) 154 Cal.App.3d 1, 10-11, 200 Cal.Rptr. 839 [full, separate and consecutive sentencing provisions of section 667.6 and 1170.1 not triggered by convictions of attempted forced oral copulation]; People v. Ibarra (1982) 134 Cal.App.3d 413, 424-425, 184 Cal.Rptr. 639 [attempted murder, at the time, was not listed as a violent felony for purposes of section 667.5, subdivision (a) ].
However, these cases have no application here. Section 647.6, subdivision (c)(2), is not an enhancement or a limitation on an otherwise available statutory right. Rather, section 647.6, subdivision (c)(2) defines a felony offense and McSherry was convicted of an attempt to violate that section.

6. McSherry's reliance on Whitten is misplaced.

Finally, McSherry contends section 647.6, subdivision (c)(2), does not define a *523 substantive offense, citing People v. Whitten (1994) 22 Cal.App.4th 1761, 1765, 28 Cal.Rptr.2d 123, which held section 647.6, subdivision (c)(2), to be a sentence enhancing factor and not an element of the offense. Whitten found section 647.6 to be "indistinguishable" from section 666, which defines the offense of petty theft with a prior conviction of a theft related offense for which the defendant served time in jail or prison. (People v. Whitten, supra, at p. 1765, 28 Cal.Rptr.2d 123.) Whitten observed that People v. Bouzas (1991) 53 Cal.3d 467, 279 Cal.Rptr. 847, 807 P.2d 1076, held the prior conviction allegation of petty theft with a prior was not an element of the offense but that section 666 was a "sentence-enhancing" statute. (People v. Whitten, supra, at p. 1765, 28 Cal.Rptr.2d 123.) Whitten concluded Bouzas necessarily disapproved People v. San Nicolas, supra, 185 Cal.App.3d 403, 229 Cal.Rptr. 650, which held the prior conviction allegation of section 647.6 (formerly § 647a) to be an element of a felony offense.
However, as noted in People v. Johnson, supra, 145 Cal.App.4th at p. 906, footnote 17, 51 Cal.Rptr.3d 893, section 666 properly may be distinguished from hybrid statutes, such as sections 647.6 and 314, which are self contained statutory schemes. Section 666, on the other hand, is a separate statute that elevates a misdemeanor to a felony. It provides the defendant must be "convicted of petty theft" after suffering a prior conviction of petty theft, grand theft, burglary or robbery and be imprisoned for such prior conviction. Thus, section 666 sets forth a penalty that is not included in the same section that defines the minimum elements of the offense. Because section 647.6 is constructed differently than section 666, Bouzas is inapplicable. Consequently, we disagree with Whitten's criticism of San Nicolas and conclude section 647.6, subdivision (c)(2), defines a felony offense.

DISPOSITION
The order to show cause is discharged. The petition for writ of habeas corpus is denied.
CROSKEY and ALDRICH, JJ., concur.
NOTES
[1]  Subsequent unspecified statutory references are to the Penal Code.
[2]  In determining the applicable statute of limitations, "An offense is deemed punishable by the maximum punishment prescribed by statute for the offense, regardless of the punishment actually sought or imposed. Any enhancement of punishment prescribed by statute shall be disregarded in determining the maximum punishment prescribed by statute for an offense." (§ 805, subd. (a).)
[3]  Section 314 provides, in part, that: "Every person who willfully and lewdly ... [¶] [exposes his person, or the private parts thereof, in any public place, or in any place where there are present other persons to be offended or annoyed thereby ... [¶] ... is guilty of a misdemeanor." (§ 314, subds. 1 & 2.) However, if the offense is committed after unauthorized entry into an inhabited dwelling house, the offense is an alternate felony/misdemeanor. If the offender has one or more prior convictions for violation of section 314, subdivision (1) or under section 288, the offense is punished as a felony.
