
    [S.F. No. 24900.
    July 28, 1988.]
    JENNIFER DAVIS, Petitioner, v. THE MUNICIPAL COURT FOR THE SAN FRANCISCO JUDICIAL DISTRICT OF THE CITY AND COUNTY OF SAN FRANCISCO, Respondent; THE PEOPLE, Real Party in Interest.
    
      Counsel
    Jack Morgan for Petitioner.
    No appearance for Respondent.
    John K. Van de Kamp, Attorney General, Robert R. Granucci, Herbert F. Wilkinson and Blair W. Hoffman, Deputy Attorneys General, Arlo Smith, District Attorney, and Judith M. Garvey, Assistant District Attorney, for Real Party in Interest.
    James K. Hahn, Gary R. Netzer and Ira Reiner, City Attorneys (Los Angeles), Greg Wolff, Jack L. Brown and R. Bruce Copien, Deputy City Attorneys, as Amici Curiae on behalf of Real Party in Interest.
   Opinion

ARGUELLES, J.

In recent years, the Legislature has enacted a number of statutory provisions which recognize the authority of local entities to adopt pretrial diversion programs for persons charged with misdemeanors. (See, e.g., Pen. Code, §§ 1001-1001.9, 1001.50-1001.55.) In this case we must determine the validity of one of the central features of these misdemeanor diversion statutes—a provision granting a local district attorney the authority to approve or disapprove a local diversion program (§§ 1001.2, subd. (b), 1001.50, subd. (b))—as well as the validity of one specific provision of the misdemeanor diversion program adopted in San Francisco. Although the Court of Appeal concluded that both the general statutory provision and the particular local rule at issue here violate the constitutional separation-of-powers doctrine, as we shall explain we find no constitutional or other infirmity in either the challenged statutory provision or the local rule. Accordingly, we reverse the Court of Appeal judgment.

I

This writ proceeding arises out of a criminal prosecution brought in San Francisco. The district attorney filed a complaint in municipal court charging petitioner Jennifer Davis (hereafter defendant) with prostitution (§ 647, subd. (b)), a misdemeanor, and with grand theft. (§ 487, subd. 1.) Under the governing statutes, grand theft is a so-called “wobbler”—i.e., an offense which may be charged and punished as either a felony or a misdemeanor (see § 17, subd. (b))—and here the district attorney charged the grand theft count as a felony. Prior to the preliminary hearing, the municipal court, acting pursuant to its authority under section 17, subdivision (b)(5), reduced the grand theft charge to a misdemeanor.

Thereafter, defendant sought pretrial diversion. At the time, San Francisco had instituted a pretrial misdemeanor diversion program which had been drafted by the district attorney in conjunction with a committee of local judges, attorneys and others involved in the criminal justice system, and which had been finally approved by the district attorney. The diversion program—which, as prescribed by section 1001.1, was limited to persons charged with “an offense filed as a misdemeanor”—set forth detailed criteria for diversion eligibility, prescribing various circumstances under which defendants who were charged with a misdemeanor would either be presumptively or absolutely ineligible for diversion. With respect to defendants charged with a wobbler, the diversion guidelines provided that when the wobbler had originally been filed as a felony, the defendant was absolutely ineligible for diversion; when the wobbler had originally been charged as a misdemeanor, the defendant was presumptively ineligible for diversion but could be found eligible for diversion under some circumstances.

Relying on these governing guidelines, the municipal court denied defendant’s request for diversion, explaining that she was ineligible for diversion because the grand theft count had been charged as a felony.

Defendant then sought a writ of mandate in superior court, contending that the local rule in question, making a defendant’s eligibility for diversion dependent on the prosecutor’s decision to charge a wobbler as a felony or a misdemeanor, conflicted with one portion of the state’s misdemeanor diversion scheme (§ 1001.2, subd. (b)) as well as a separate statutory provision (§ 17, subd. (b)(5)), and also violated the separation-of-powers doctrine and the equal protection clause. The superior court denied the writ.

Defendant then filed the present writ proceeding in the Court of Appeal. The Court of Appeal agreed with defendant’s contentions, finding that the local rule in question was invalid both because it conflicted with section 17, subdivision (b)(5) and because it violated the separation-of-powers doctrine by authorizing an unconstitutional infringement on the judicial power by the executive branch of government. In addition, the Court of Appeal went on to hold that a principal feature of the statewide misdemeanor diversion statute—the section which subjects local diversion programs to the approval of the local district attorney (§ 1001.2, subd. (b))—was itself unconstitutional, embodying an impermissible delegation of legislative power to the executive branch.

The People sought review of the Court of Appeal decision, challenging the court’s conclusions with respect to both the local rule and the state statute and suggesting that the latter holding undermined the validity of all local misdemeanor diversion programs throughout the state. Because of the importance of the issues we granted review.

II

As noted above, the San Francisco misdemeanor diversion program at issue here was adopted pursuant to chapter 2.7. Section 1001.2, subdivision (b), one of the initial provisions of chapter 2.7, provides in relevant part: “The district attorney of each county shall review annually any diversion program established pursuant to this chapter, and no program shall continue without the approval of the district attorney. No person shall be diverted under a program unless it has been approved by the district attorney. . . ,”

The Court of Appeal concluded that this provision, in granting the district attorney the ultimate authority to approve or disapprove a local diversion program without establishing any standards or guidelines to limit the district attorney’s discretion, violated the separation-of-powers doctrine by delegating a standardless legislative authority to the executive branch of government. (Cf. People v. Wright (1982) 30 Cal.3d 705 [180 Cal.Rptr. 196, 639 P.2d 267].) Because this conclusion, if correct, might well invalidate the entire misdemeanor diversion program at issue here—as well as all misdemeanor diversion programs throughout the state—we address this issue first.

As we shall explain, we conclude that the Court of Appeal’s determination that section 1001.2, subdivision (b) represents an unconstitutional delegation of legislative authority to the district attorney rests on a misunderstanding of the history and purpose of the legislation at issue as well as on an inaccurate characterization of the source and nature of the authority which the provision permits the district attorney to exercise.

We begin with the legislative history of chapter 2.7. The current version of chapter 2.7 derives from legislation first enacted in 1977. Five years earlier, in 1972, the Legislature had adopted California’s first statutorily mandated pretrial diversion program, a program limited to those who would benefit from drug education, treatment and rehabilitation. (§§ 1000-1000.4, enacted Stats. 1972, ch. 1255, § 17, p. 2469.) In creating that initial program, the Legislature itself prescribed the eligiblity requirements for diversion, providing (1) that only defendants who had been charged with specifically enumerated drug offenses could be considered for diversion, and (2) that of the defendants so charged, only those who satisfied a series of additional designated prerequisites could qualify for diversion. (§ 1000, subd. (a).)

In the early and mid-1970’s, numerous local police departments and district attorneys throughout California, acting with the encouragement of grants provided by the federal government, began implementing experimental local diversion programs in their own jurisdictions. (See generally Nat. Advisory Com. on Crim. Justice Standards & Goals, Rep. on Corrections (1973) pp. 73-94; ABA Com. on Correctional Facilities & Services, Source Book in Pretrial Crim. Justice Intervention Techniques & Action Programs (1974) pp. 2-3.) Shortly thereafter, serious questions were raised as to the validity of these locally initiated programs when an Attorney General opinion suggested that the Legislature’s 1972 pretrial drug abuse diversion legislation had preempted the field. (See People v. Tapia (1982) 129 Cal.App.3d Supp. 1, 6 [181 Cal.Rptr. 382] [summarizing unpublished Cal. Atty. Gen. opn.].) As a consequence, the funding of some of the local programs was threatened and other district attorneys, who had been considering implementing such programs, became reluctant to go ahead with such plans.

To meet this problem, the Legislature in 1977 adopted as an urgency measure the predecessor of the current chapter 2.7. (Stats. 1977, ch. 574, § 3, p. 1821.) The 1977 legislation did not establish a general, state-mandated diversion program, but rather expressly declared that the Legislature did not intend to preempt the pretrial diversion field. While the 1977 legislation established a number of procedural protections for persons who participated in local diversion programs (see former §§ 1001.3-1001.9), it neither compelled a local jurisdiction to establish a diversion program nor limited a local entity’s discretion in designing or implementing the eligibility requirements of such a program. The legislation did not purport to delegate the power to institute or design a pretrial diversion program to any particular local entity or official and included no provision requiring the district attorney’s approval of such a local program. Local entities which chose to institute experimental pretrial diversion programs were required to provide annual reports to the Legislature disclosing various information regarding “the implementation, administration and operation of such program,” including “the program’s general eligibility criteria for divertees,” “the name of the county or other agency or agencies which established such eligibility criteria,” “other criteria or standards established for the program” and “the offense charged against the divertee.” (Former § 1001.10.) The 1977 enactment provided that it would remain in effect until January 1, 1980; in 1979, the legislation was extended for an additional two-year period. (Stats. 1979, ch. 775, §2, p.2658.)

After evaluating the information generated by the experimental local diversion programs sanctioned by the 1977 legislation, the Legislature in 1982 adopted two separate but related pretrial diversion statutes, the current chapter 2.7 and chapter 2.9. The revised version of chapter 2.7 continued in place the general “local option” structure of the 1977 legislation, retaining the introductory provision clearly stating the Legislature’s intent not to preempt the pretrial diversion field. (§ 1001.) The 1982 revision of chapter 2.7 did, however, make several significant changes from the former scheme. First, the 1982 act limited the reach of the chapter to diversion programs which involved the postponement of prosecution “of an offense filed as a misdemeanor” (§ 1001.1); the 1977 act had contained no such restriction and thus had embraced local programs which authorized both misdemeanor and felony diversion. (See former § 1001.1.) Second, the 1982 revision added the section of chapter 2.7 at issue here (§ 1001.2, subd. (b), quoted in fn. 5, ante), limiting the chapter’s application to local diversion programs that have been approved by the local district attorney.

Chapter 2.9, which is not directly at issue here, was enacted several months after the 1982 revision of chapter 2.7. Like chapter 2.7, chapter 2.9 is a “local option” scheme and applies only to misdemeanor diversion programs. Unlike chapter 2.7, however, chapter 2.9 sets out a “model” misdemeanor diversion program with legislatively prescribed eligibility criteria (§ 1001.51, subds. (a) and (c)) which a county board of supervisors may adopt by ordinance. (§ 1001.50, subd. (a).) Like chapter 2.7, however, chapter 2.9 also conditions the implementation of such a diversion program on the district attorney’s approval. (§ 1001.50, subd. (b).)

A number of points emerge from this review of the legislative history of chapter 2.7. First, contrary to the view of the Court of Appeal, the Legislature in enacting the provision clearly did not intend to mandate a statewide misdemeanor diversion program or to require every locality to adopt such a program; stating emphatically that the existing statewide pretrial diversion programs were not intended to preempt the field, the Legislature made plain its intention to leave to local entities and officials both the decision whether to implement such a program and the authority to fashion a misdemeanor diversion program to meet local needs and resources. (See People v. Padfield (1982) 136 Cal.App.3d 218, 230-231 [185 Cal.Rptr. 903] [discussing 1977 legislation]; People v. Tapia, supra, 129 Cal.App.3d Supp. 1, 7-9 [same].) Second, the Legislature determined that a local misdemeanor diversion program should not be implemented over a district attorney’s objection; as we have seen, unlike its 1977 predecessor, the 1982 legislation expressly conditioned the applicability of chapter 2.7 on the district attorney’s approval of the local diversion program. (§ 1001.2, subd. (b).)

The Court of Appeal concluded that by permitting a local district attorney to veto any misdemeanor diversion program which he or she did not approve, the Legislature unconstitutionally delegated legislative authority to an executive official. But while a district attorney’s approval or disapproval of a diversion program can accurately be described as a “quasi-legislative” policy decision, the quasi-legislative nature of the decisionmaking authority retained by the district attorney does not establish that the authority exercised by the district attorney under this provision should properly be characterized as a “legislative” rather than an “executive” power for purposes of the separation-of-powers doctrine.

As this court explained nearly a half century ago: “The courts have long recognized that [the] primary purpose [of the separation-of-powers doctrine] is to prevent the combination in the hands of a single person or group of the basic or fundamental powers of government. [Citations.] The doctrine has not been interpreted as requiring the rigid classification of all the incidental activities of government, with the result that once a technique or method of procedure is associated with a particular branch of the government, it can never be used thereafter by another. Thus, although the ascertainment of facts based upon evidence taken in the course of a formal hearing is normally associated with an exercise of the judicial power, it may be entirely proper in the exercise of legislative or executive power [citations] .... Similarly, although it is normally the duty of the legislature to make the determinations of fact upon the basis of which legislation is to become effective, that duty may properly be devolved upon members of the executive branch of the government. [Citations.]” (Italics added.) (Parker v. Riley (1941) 18 Cal.2d 83, 89-90 [113 P.2d 873, 134 A.L.R. 1405].) Indeed, as a leading commentator on the separation-of-powers doctrine has noted: “From the beginning, each branch has exercised all three kinds of powers.” (1 Davis, Administrative Law Treatise (2d ed. 1978) § 2:2, p. 63.)

It is commonplace to observe that both executive and judicial officials routinely exercise quasi-legislative authority in establishing general policies and promulgating general rules for the governing of affairs within their respective spheres. (See 1 Davis, supra, § 2:1, pp. 60-61.) The exercise of such quasi-legislative authority, even when the policy decision that is made by the executive or judicial entity or official is one that could have been made by the Legislature, has never been thought to violate the separation-of-powers doctrine. (See, e.g., Wayman v. Southard (1825) 23 U.S. (10 Wheat.) 1, 42-47 [6 L.Ed. 253, 262-264]; United States v. Curtiss-Wright Export Corp. (1936) 299 U.S. 304 [81 L.Ed. 255, 57 S.Ct. 216].)

In the present case, the Legislature, in applying the provisions of chapter 2.7 only to local misdemeanor diversion programs that are approved by the local district attorney, did not unconstitutionally enlarge the district attorney’s quasi-legislative policymaking role beyond the district attorney’s legitimate executive sphere. Instead, the Legislature simply recognized that pretrial diversion is closely and intimately related to the district attorney’s traditional executive authority over the prosecutorial process, and determined, as a matter of policy, not to permit local diversion programs to be implemented over the district attorney’s objection.

It is well established, of course, that a district attorney’s enforcement authority includes the discretion either to prosecute or to decline to prosecute an individual when there is probable cause to believe he has committed a crime. (See, e.g., Bordenkircher v. Hayes (1978) 434 U.S. 357, 364 [54 L.Ed.2d 604, 611, 98 S.Ct. 663]; Daly v. Superior Court (1977) 19 Cal.3d 132, 148 [137 Cal.Rptr. 14, 560 P.2d 1193]; People v. Adams (1974) 43 Cal.App.3d 697, 707 [117 Cal.Rptr. 905]. See generally Prosecutorial Discretion (Cont.Ed.Bar 1979) § 1.2, pp. 6-7.) In exercising such discretion, prosecutors have traditionally considered whether there are alternative programs in the community in which the defendant’s participation would serve the interests of the administration of justice better than prosecution, and have frequently agreed to forgo prosecution on the condition that the defendant participate in such an alternative program. (See generally Note, Pretrial Diversion from the Criminal Process (1974) 83 Yale L.J. 827, 837-839; Annot., Pretrial Diversion (1981) 4 A.L.R 4th 147, 151; Vorenberg & Vorenberg, Early Diversion from the Criminal Justice System, in Prisoners in America (Ohlin ed., 1973) pp. 159-161; 1 ABA Standards for Criminal Justice, Stds. Relating to the Prosecution Function (2d ed.) std. 3-3.8 [Discretion as to Noncriminal Disposition].) Thus, a prosecutor’s decision to decline to prosecute a particular defendant on condition that he participate ■ in an alternative program—i.e., a diversion decision—has traditionally been viewed as a subset of the prosecutor’s broad charging discretion. (See, e.g., People v. Glover (1980) 111 Cal.App.3d 914, 916-918 [169 Cal.Rptr. 12]; Prosecutorial Discretion, supra, §1.43, pp. 44-46; id. (Cont.Ed.Bar Supp. 1983) § 1.43, p. 8.)

Moreover, a prosecutor’s inherent executive authority includes not only the power to authorize diversion on a case-by-case basis, but extends also to the establishment or approval of general eligibility standards to guide the exercise of such discretion by all deputies under his direction. (See generally 1 ABA Standards for Criminal Justice, supra, std. 3-2.5 [Prosecutor’s Handbook; Policy Guidelines and Procedures]; Cal. Dist. Attys. Assn., Uniform Crime-Charging Standards (1974) [proposed crime-charging guidelines for adoption by local district attorneys].) In drafting or approving such general guidelines, a district attorney does not improperly exercise a legislative power adhering solely in the Legislature, but rather performs an executive function of constraining the exercise of preexisting executive discretion. Over the past two decades, district attorneys throughout the country have frequently fashioned eligibility requirements for pretrial diversion programs in the absence of specific legislative authorization. (See, e.g., Note, Pretrial Diversion from the Criminal Process, supra, 83 Yale L.J. 827, 837-839.) In conditioning the application of chapter 2.7 on the district attorney’s approval of a local diversion program, the Legislature simply chose to retain the district attorney’s executive control over the establishment and design of such programs.

We do not, of course, suggest that the Constitution required the Legislature to proceed in this manner. In a number of other contexts, the Legislature has established the eligibility criteria for diversion itself and has not left the policy questions of the design of the program to the district attorney. (See, e.g., §§ 1000 et seq. [drug abuse diversion]; 1000.6 et seq. [domestic violence diversion]; 1001.20 [diversion of mentally retarded defendants].) In other states, diversion programs have been implemented by the judiciary without a prosecutorial veto. (See, e.g., State v. Leonardis (1976) 71 N.J. 85 [363 A.2d 321], reaffd. on rehg. (1977) 73 N.J. 360 [375 A.2d 607].) But the fact that the Legislature was not constitutionally obligated to give a local district attorney the right to approve or disapprove a local diversion program does not in any way support the Court of Appeal’s conclusion that the constitutional separation-of-powers doctrine precludes the Legislature from accommodating a district attorney’s traditional executive authority by permitting him to retain control over the policy questions involved in the establishment and design of a diversion program. (See generally Nixon v. Administrator of General Services (1977) 433 U.S. 425, 443 [53 L.Ed.2d 867, 891, 97 S.Ct. 2777] [rejecting “ ‘archaic view of the separation-of-powers as requiring three airtight departments of government’ ”].)

Accordingly, we conclude that section 1001.2, subdivision (b) does not constitute an unconstitutional delegation of legislative authority to the district attorney.

III

Defendant additionally contends that even if the district attorney may properly approve or disapprove general eligibility criteria for local diversion programs, the particular local rule at issue in this case— under which a defendant’s elibility for diversion is dependent on whether a prosecutor charges a wobbler as a felony or as a misdemeanor—is nonetheless invalid. Defendant maintains that the local rule is incompatible with two distinct statutory provisions and, in any event, is unconstitutional as a violation of both the separation-of-powers and equal protection doctrines. We begin with the statutory argument.

A

Defendant relies on two statutory provisions to support her claim that the Legislature did not intend to authorize a local entity to adopt the “wobbler” rule in question here. First, she contends that the rule conflicts with a portion of chapter 2.7 itself, the concluding sentence of section 1001.2, subdivision (b) which provides that “[n]othing in this subdivision shall authorize the prosecutor to determine whether a particular defendant shall be diverted.” (See fn. 5, ante, p. 73.) The People respond that this sentence was simply intended to make it clear that a prosecutor has no authority to overrule a trial court’s decision to divert a particular defendant when the defendant is eligible for diversion under the locality's established guidelines (see, e.g., People v. Superior Court (On Tai Ho) (1974) 11 Cal.3d 59, 65-68 [113 Cal.Rptr. 21, 520 P.2d 405]), and cannot reasonably be interpreted to preclude the adoption of guidelines under which a defendant’s eligibility for diversion depends on the offense that the prosecutor determines should be appropriately charged. As the People point out, because section 1001.1 itself provides that the only persons eligible for diversion under chapter 2.7 programs are those who are charged with an offense “'filed as a misdemeanor” (italics added), and because prosecutors in innumerable situations outside of the wobbler context retain discretion to charge a defendant with either a felony or a misdemeanor, in a large proportion of cases a defendant’s eligibility for misdemeanor diversion will inevitably depend on the offense that the prosecutor determines should be filed. The People maintain that the quoted sentence cannot sensibly be construed to prohibit the adoption of any eligibility requirement that renders a class of defendants ineligible for diversion on the basis of the offense with which they are charged.

Alternatively, defendant contends that the local rule conflicts with section 17, subdivision (b)(5) which declares that a wobbler filed as a felony “is a misdemeanor for all purposes” when a magistrate “determines that the offense is a misdemeanor, in which event the case shall proceed as if the defendant had been arraigned on a misdemeanor complaint.” Focusing on the phrase “for all purposes,” defendant argues the local rule at issue here violates section 17, subdivision (b)(5) by preventing a court from treating a “reduced wobbler” as a misdemeanor for diversion purposes. The People suggest, in response, that the “for all purposes” phrase must be read in relation to the portion of subdivision (b)(5) which stipulates that the case shall proceed “as if the defendant had been arraigned on a misdemeanor complaint,” arguing that, when construed as a whole, the subdivision should not be read to render a defendant, who was initially charged with a felony, eligible for diversion as if the offense had been “filed as a misdemeanor.”

In our view, there is no need to attempt to parse the language of either section 1001.2, subdivision (b) or section 17, subdivision (b)(5) as the parties invite us to do, because another statutory provision—section 1001.51, subdivision (c)(3)—demonstrates quite clearly that the Legislature did not intend to preclude a local entity from adopting the wobbler rule at issue here. Section 1001.51, subdivision (c)(3) is a provision of the chapter 2.9 misdemeanor diversion legislation, which—as noted above—was enacted just a few months after chapter 2.7. As we have explained, while chapter 2.7 contemplates that the local jurisdiction will design its own misdemeanor diversion program, chapter 2.9 embodies a legislatively designed “model” misdemeanor diversion program which a county board of supervisors may adopt by ordinance if it chooses. That model misdemeanor diversion program contains both a section with the same language as section 1001.2, subdivision (b)—i.e., “[n]othing in this subdivision shall authorize the prosecutor to determine whether a particular defendant shall be diverted” (§ 1001.50, subd. (b))—and also a provision which is identical in effect to the local wobbler rule in dispute here, rendering defendants charged with reduced wobblers absolutely ineligible for diversion. (See § 1001.51 subd. (c)(3).) Having incorporated this very wobbler provision in its own model misdemeanor diversion program, the Legislature cannot reasonably have intended to bar localities from voluntarily including a comparable rule in a chapter 2.7 diversion program.

Thus, as a matter of statutory interpretation, we conclude that the challenged local rule does not violate the legislative design.

B

Defendant alternatively contends that even if the Legislature intended to permit a locality to adopt the wobbler rule in question, San Francisco was nonetheless constitutionally precluded from adopting or applying such a rule by virtue of the separation-of-powers doctrine. With regard to this issue, defendant does not argue that the local rule involves an invalid delegation of legislative authority to the district attorney, but instead relies on an entirely separate facet of the separation-of-powers doctrine. Because under the San Francisco diversion program the trial court has the power to make the ultimate decision whether an eligible defendant shall actually be diverted or not, defendant asserts that the rule at issue here, which makes a defendant’s eligibility for diversion dependent on the prosecutor’s decision to charge a wobbler as a felony or misdemeanor, permits the executive branch to improperly infringe on the judicial power. The Court of Appeal agreed with defendant’s position, concluding that this separation-of-powers claim was supported by a number of California decisions—beginning with People v. Tenorio (1970) 3 Cal.3d 89 [89 Cal.Rptr. 249, 473 P.2d 993]—which, in a variety of settings, struck down statutes which purported to give a prosecutor the right to veto judicial determinations.

We cannot agree with the Court of Appeal’s analysis of our prior cases or with its conclusion. The wobbler rule at issue here represents no greater an infringement on the judicial power than any other provision of a diversion program which defines the class of defendants who are eligible or ineligible for diversion by reference to the offense with which a defendant is charged, provisions that are routinely embodied in virtually all diversion programs. Indeed, because the rule in question simply excludes from the diversion program defendants against whom felony charges are filed, the rule does no more than carry out the directive of section 1001.1 which limits diversion programs adopted under chapter 2.7 to defendants charged with “an offense filed as a misdemeanor.” As anyone familiar with the criminal justice system knows, a district attorney’s discretion to charge either a felony or misdemeanor is by no means confined to the wobbler context. District attorneys are continually faced with factual situations outside the wobbler context which would legally support the filing of either felony or misdemeanor charges. (See generally Prosecutorial Discretion, supra, §§ 1.16-1.26, pp. 20-32.) The fact that in many, if not most, felony cases there will be at least some misdemeanor which the prosecutor could have chosen to charge if he determined that such lesser charge was appropriate has, of course, never been thought to invalidate all misdemeanor diversion programs. Like other defendants who are ineligible for misdemeanor diversion because they have been charged with a felony, a defendant who is charged with a felony wobbler is ineligible for such diversion primarily because the district attorney has cause to believe that he or she has committed misconduct which is punishable as a felony, the fact that the prosecutor may have had discretion to charge the defendant with a misdemeanor rather than a felony does not give such a defendant the constitutional right to be treated as if he had been charged with the lesser offense.

It is true, of course, that a prosecutor’s exercise of discretion to charge a defendant with a felony rather than a misdemeanor when the facts of the case would support either charge will frequently have a variety of effects on the ultimate judicial disposition of the matter. A prosecutor’s charging decision may, for example, determine whether a defendant is convicted of an offense for which probation may not be granted, or for which a specific punishment is mandated. Those familiar consequences of the charging decision have, however, never been viewed as converting a prosecutor’s exercise of his traditional charging discretion into a violation of the separation-of-powers doctrine.

The line of separation-of-powers decisions on which the Court of Appeal relied is concerned with an entirely different kind of interference by the executive with a court’s exercise of the judicial function. As we shall see, in all of those cases the challenged statutory provisions purported to give a prosecutor the right to veto a decision made by a court after criminal charges had already been filed. None of the cases suggests that the exercise of prosecutorial discretion prior to the filing of such charges improperly subordinates the judicial branch to the executive in violation of the Constitution, even though the prosecutor’s exercise of such charging discretion inevitably affects the sentencing or other dispositional options available to the court.

We begin with the seminal decision in Tenorio, supra, 3 Cal.3d 89. In Tenorio, the court addressed a statutory provision which gave the district attorney the power to preclude a trial court from exercising its long established discretion, under Penal Code section 1385, to strike a prior offense for the purposes of sentencing. (See, e.g., People v. Burke (1956) 47 Cal.2d 45, 50-51 [301 P.2d 241].) In that setting, in which the district attorney’s “veto” power was exercised at the sentencing phase of the criminal proceeding, well after the filing of the charges, the Tenorio court concluded that the district attorney’s exercise of such a veto improperly compromised the judicial function and violated the separation-of-powers doctrine. The court explained: “The judicial power is compromised when a judge, who believes that a charge should be dimissed in the interests of justice, wishes to exercise the power to dismiss but finds that before he may do so he must bargain with the prosecutor. The judicial power must be independent, and a judge should never be required to pay for its exercise.” (3 Cal.3d at p. 94.)

In Esteybar v. Municipal Court (1971) 5 Cal.3d 119 [95 Cal.Rptr. 524, 485 P.2d 1140], the next case in the series, this court applied Tenorio to a legislative scheme which granted a magistrate the authority to reduce a wobbler to a misdemeanor but conditioned the magistrate’s exercise of such authority on the approval of the district attorney. The Esteybar court concluded that, as in Tenorio, the district attorney’s exercise of such a veto power at that stage of the proceeding would violate the separation-of-powers doctrine. In response to the People’s argument that the application of Tenorio to a decision which reduced a charge from a felony to a misdemean- or would “constitute[ ] an invasion of the charging process, an area traditionally reserved to the prosecutor, because [it would] abridge[ ] his discretion in deciding ‘what crime is to be charged or if any crime is to be charged’ [citation]” (5 Cal.3d at p. 127), the Esteybar court explained: “This argument overlooks the fact that the magistrate’s determination follows the district attorney’s decision to prosecute. As stated in Tenorio: ‘When the decision to prosecute has been made, the process which leads to acquittal or sentencing is fundamentally judicial in nature.’ ” (Original italics.) (Ibid.) Thus, Esteybar expressly emphasized the timing of the exercise of prosecutorial discretion as a crucial factor in the Tenorio analysis. All of the subsequent cases applying Tenorio to invalidate legislative provisions have similarly involved statutes which authorized the exercise of a prosecutorial veto after the filing of criminal charges, when the criminal proceeding has already come within the aegis of the judicial branch. (See, e.g., People v. Clay (1971) 18 Cal.App.3d 964 [96 Cal.Rptr. 213] [district attorney’s veto over judicial decision to grant probation]; People v. Navarro (1972) 7 Cal.3d 248 [102 Cal.Rptr. 137, 497 P.2d 481] [district attorney’s veto over judicial decision to commit convicted defendant to drug treatment program in lieu of prison sentence].)

The Court of Appeal, in finding the local wobbler rule unconstitutional, relied heavily on this court’s decisions in People v. Superior Court (On Tai Ho), supra, 11 Cal.3d 59 and Sledge v. Superior Court (1974) 11 Cal.3d 70 [113 Cal.Rptr. 28, 520 P.2d 412]—our only previous decisions to address a Tenorio challenge in the pretrial diversion setting—but those decisions in fact follow the same pattern as the earlier Tenorio decisions. On Tai Ho and Sledge both dealt with the statutory drug abuse diversion program, discussed briefly above, which was enacted by the Legislature in 1972. (See §§ 1000-1000.4.) Under that statutory scheme, when a defendant was charged with one of six specified drug offenses, the district attorney reviewed the defendant’s file to determine whether he met certain minimum standards of eligibility for diversion established by the Legislature. If the defendant met the minimum criteria, the case was referred to the probation department for an investigation and report, and then the trial court, after a hearing on the matter, determined whether diversion was appropriate in the particular case. Even if the court found diversion appropriate, however, the statute gave the district attorney the power to veto the ultimate diversion decision.

On Tai Ho and Sledge each involved a constitutional challenge to a separate aspect of the district attorney’s role in that diversion scheme. In On Tai Ho, the defendant challenged the district attorney’s role in the last stage of the diversion process, where he was given the power to disapprove a trial court’s decision, after a hearing, to grant diversion. In defense of the statutory scheme, the People argued that “the decision to divert is merely an extension of the charging process, and hence remains within the traditional zone of the district attorney’s discretion.” (11 Cal.3d at p. 65.) In rejecting that argument in the context of the procedure at issue in that case, the On Tai Ho court stated: “As we explained in Esteybar, however, ‘This argument overlooks the fact that the magistrate’s determination follows the district attorney’s decision to prosecute.’ ... By the time the case goes through the probation investigation and report prescribed in section 1000.1, and reaches the hearing mandated by section 1000.2, the prosecutorial die has long since been cast. The case is ‘before the court’ for disposition, and disposition is a function of the judicial power no matter what the outcome.” (First italics in original; additional italics added.) (Ibid.) Thus, as in all of the earlier Tenorio cases, the constitutional defect in the statute was that it interposed a prosecutorial veto at the “judicial” stage of a criminal proceeding, when the case was already “before the court” for disposition.

In Sledge, a companion case to On Tai Ho, the defendant’s constitutional challenge was directed at the role which the statute assigned to the district attorney at an earlier stage in the process to review the file of a defendant charged with a divertible offense to determine whether any of the legislatively prescribed disqualifying factors was present and rendered the defendant ineligible for diversion. Although the district attorney’s role was to be performed after charges were filed, and thus while the case was already “before the court,” the Sledge court concluded that the statute nonetheless did not violate the separation-of-powers doctrine because the district attorney’s function under the statute did not involve the exercise of broad discretion but was limited to the largely nondiscretionary task of applying specific, legislatively prescribed eligibility criteria. Under these circumstances, the Sledge court reasoned that the district attorney’s exercise of such a limited role did not “constitute an exercise of judicial authority.” (11 Cal.3d at p. 76.)

Taken together, On Tai Ho and Sledge establish that when a district attorney is given a role during the “judicial phase” of a criminal proceeding, such role will violate the separation-of-powers doctrine if it accords the district attorney broad, discretionary decisionmaking authority to countermand a judicial determination, but not if it only assigns the district attorney a more limited, quasi-ministerial function. Neither case, however, contains any suggestion whatsoever that a district attorney improperly exercises “judicial authority” in violation of the separation-of-powers doctrine when he exercises his traditional broad discretion, before charges are filed, to decide what charges ought to be prosecuted, even when that charging decision affects the defendant’s eligibility for diversion.

Indeed, although neither On Tai Ho nor Sledge referred to the point, the pretrial diversion scheme at issue in those cases did in fact afford the district attorney just such authority. As noted above, under the relevant statute diversion was available only when a defendant was charged with one of six specifically enumerated drug offenses. (See § 1000, subd. (a).) In many instances, of course, the evidence before the district attorney would inevitably require him to decide whether to charge the defendant with one of the enumerated offenses or with a different or greater offense. Nothing in On Tai Ho or Sledge suggests that the existence of such discretionary charging authority in the district attorney violated the separation-of-powers doctrine or rendered the diversion program constitutionally infirm.

Although the rationale of On Tai Ho and Sledge makes it quite plain that those decisions’ concern over the potential improper interposition of prosecutorial discretion into the judicial realm does not extend to a prosecutor’s exercise of discretion at the charging stage of a criminal proceeding, neither of those decisions spoke specifically to this point. In People v. Adams, supra, 43 Cal.App.3d 697, 706-707, however, the Court of Appeal did directly address a separation-of-powers claim which focused on the prosecutor’s charging discretion in a case involving a wobbler. In Adams, the defendant challenged the constitutionality of section 496 (receiving stolen property), contending that the statute improperly conferred judicial authority on the executive branch by permitting the district attorney—when the value of the property did not exceed $200—to determine whether a violation should be prosecuted as a misdemeanor or a felony. In support of his argument, defendant specifically relied on Tenorio, supra, 3 Cal.3d 89, and its progeny.

In emphatically rejecting the defendant’s claim, the Adams court explained: “Defendant’s attempted analogy between the instant case and [the Tenorio line of cases] ignores the fundamental diiference between the type of statute there involved and section 496. All the statutes involved in the cases above cited purported to impose a limitation on a purely judicial determination which in no event could be taken until after a charge had been filed in court and a prosecution had commenced in the judicial system. In the case before us the statute deals with the initial determination of the charge to be filed, a decision which, in its nature, occurs before an accusatory pleading is filed and thus before the jurisdiction of a court is invoked and a judicial proceeding initiated. It involves a purely prosecutorial function and does not condition judicial power in any way. The function thereby conferred relates only to what is clearly the province historically of the public prosecutor, i.e., the discretion whether or not to prosecute. [Citations.] The action of a district attorney in filing an information is not in any way an exercise of a judicial power or function. [Citation.]” (43 Cal.App.3d at p. 707.)

Thus, Adams makes clear that the only exercise of prosecutorial discretion at issue in this case—the discretion to charge a wobbler as a felony rather than as a misdemeanor—does not usurp judicial power or unconstitutionally infringe the judicial function. As explained earlier, the fact that the prosecutor’s charging decision may alfect a trial court’s power to order diversion does not alter that conclusion, any more than would the fact that a prosecutor’s charging decision may have the effect of limiting a court’s sentencing options.

. In concluding that the local wobbler rule at issue here does not violate the separation-of-powers doctrine simply because it makes a defendant’s eligibility for diversion dependent, in part, on the offense which the prosecutor charges, we in no way imply that a prosecutor has untrammeled discretion to overcharge a case in order to render a defendant ineligible for diversion. If a prosecutor charges a defendant with a felony and, after the preliminary hearing, it is found that the facts do not establish probable cause to hold the defendant to answer for the charged felony but only for a divertible misdemeanor, the fact that the prosecutor had initially charged a felony would not, in itself, necessarily preclude diversion. (Cf. People v. Hudson (1983) 149 Cal.App.3d 661, 665-666 [197 Cal.Rptr. 36].) But when the evidence does establish probable cause to believe that the defendant has committed conduct which is punishable as a felony—as will be the case whenever a defendant is held to answer on a wobbler charge—the fact that the magistrate or other judicial officer concludes, in the exercise of his discretion under section 17, subdivision (b)(5), that only a misdemeanor charge is warranted-—or that a jury, after trial, convicts the defendant only of a misdemeanor (see People v. Hudson, supra, 149 Cal.App.3d 661)—does not demonstrate the impropriety of the prosecutor’s charge so as to render the defendant eligible for diversion.

Accordingly, we conclude that the challenged wobbler rule does not violate the separation-of-powers doctrine.

C

Finally, we also reject defendant’s claim that the local wobbler rule violates equal protection principles. As we have explained at some length above, the rule at issue here—which treats defendants differently depending on whether the prosecutor decides to charge them with a felony or with a misdemeanor—is no different than any other legislative rule which accords differential treatment to an individual depending on whether a prosecutor believes a greater or lesser charge is appropriate. So long as there are sufficient facts to demonstrate probable cause that the defendant has committed the elements of a crime which may be charged as a felony, the defendant can claim no denial of equal protection from the fact that the prosecutor may in other cases exercise his discretion to charge only a misdemeanor when he believes more lenient treatment is warranted. The equal protection clause, of course, has never been thought to abrogate a prosecutor’s authority to exercise leniency in the charging process. (See, e.g., Oyler v. Boles (1962) 368 U.S. 448, 456 [7 L.Ed.2d 446, 452-453, 82 S.Ct. 501]; Murgia v. Municipal Court (1975) 15 Cal.3d 286, 296-297 [124 Cal.Rptr. 204, 540 P.2d 44].)

Indeed, in United States v. Batchelder (1979) 442 U.S. 114 [60 L.Ed.2d 755, 99 S.Ct. 2198], the United States Supreme Court, in a unanimous decison by Justice Marshall, specifically rejected a very similar constitutional claim. In Batchelder, the defendant’s conduct was proscribed by two separate provisions of the federal Omnibus Crime Control and Safe Streets Act of 1968, each of which carried a different maximum penalty, and the defendant was prosecuted and sentenced under the section carrying the higher penalty. On appeal, the Seventh Circuit reduced the defendant’s sentence to the lesser penalty, concluding that the prosecutor’s “unfettered” discretion to decide under which of the two provisions the defendant should be prosecuted could produce “unequal justice” and raised serious constitutional questions.

The United States Supreme Court granted certiorari and reversed the circuit court’s decision, concluding that in the absence of any showing that the prosecution’s exercise of discretion had been “ ‘based upon an unjustifiable standard such as race, religion or other arbitrary classification’ ” (442 U.S. at p. 125, fn. 9 [60 L.Ed.2d at p. 765]), the existence of such prosecutorial discretion did not violate either equal protection or due process principles. As the Batchelder decision explained: “[T]here is no appreciable difference between the discretion a prosecutor exercises when deciding whether to charge under one of two statutes with different elements and the discretion he exercises when choosing one of two statutes with identical elements. In the former situation, once he determines that the proof will support conviction under either statute, his decision is indistinguishable from the one he faces in the latter context. The prosecutor may be influenced by the penalties available upon conviction, but this fact, standing alone, does not give rise to a violation of the Equal Protection or Due Process Clause. [Citations.] Just as a defendant has no constitutional right to elect which of two applicable federal statutes shall be the basis of his indictment and prosecution, neither is he entitled to choose the penalty scheme under which he will be sentenced.” (442 U.S. at p. 125 [60 L.Ed.2d at pp. 765-766].)

Furthermore, the Batchelder decision also puts to rest any suggestion that the local rule at issue—in making the defendant’s eligibility for diversion dependent on the prosecutor’s charging discretion—constitutes an unconstitutional delegation of legislative authority to the district attorney. After rejecting the defendant’s equal protection and due process claims, the Batchelder court went on to address such an unconstitutional delegation theory, noting that the Seventh Circuit, “[a]pproaching the problem of prosecutorial discretion from a slightly different perspective, [had] postulated that the statutes might impermissibly delegate to the Executive Branch the Legislature’s responsibility to fix criminal penalties. [Citations.]” (442 U.S. at pp. 125-126 [60 L.Ed.2d at p. 766].) The Supreme Court disposed of that impermissible delegation-of-legislative-authority claim in short order, explaining: “The provisions at issue plainly demarcate the range of penalties that prosecutors and judges may seek and impose. In light of that specificity, the power that Congress has delegated to those officials is no broader than the authority they routinely exercise in enforcing the criminal laws. Having informed the courts, prosecutors and defendants of the permissible punishment alternatives available under each Title, Congress has fulfilled its duty.” (442 U.S. at p. 126 [60 L.Ed.2d at p. 766].)

This reasoning fully applies both to wobblers and to all other circumstances in which a defendant’s conduct may potentially subject him to either a felony or misdemeanor charge. In such cases, so long as the criminal statutes “plainly demarcate the range of penalties that prosecutors . . . may seek,” Batchelder establishes that the fact that the prosecutor retains the discretion to seek either the greater or the lesser penalty does not constitute an impermissible delegation of legislative authority to an executive official.

IV

In sum, we conclude there is no basis—constitutional or statutory—for invalidating either the district attorney’s general authority to approve a local misdemeanor diversion program under section 1001.2, subdivision (b) or the specific eligibility requirement that was applied in this case.

The judgment of the Court of Appeal is reversed and the case is remanded to the Court of Appeal with directions to deny the peremptory writ.

Lucas, C. J., Broussard, J., and Eagleson, J., concurred.

MOSK, J., Concurring and Dissenting

I concur in the majority’s conclusion that Penal Code section 1001.2, subdivision (b), does not unconstitutionally delegate legislative authority to the district attorney. I also agree that the Legislature’s inclusion of Penal Code section 1001.51, subdivision (c)(3), in its model misdemeanor program dispels any notion that it intended to bar similar provisions in programs adopted locally.

I disagree, however, with the conclusion that San Francisco’s wobbler rule does not improperly infringe on the judicial power. In my view, the rule violates the separation of powers doctrine by giving the prosecutor discretionary authority to determine whether the court can declare a person charged with a wobbler eligible for diversion. In short, the test should be not whether the district attorney charged defendant with a potential felony, but whether the court found the offense to be a misdemeanor.

The decision to divert “constitutes an exercise of judicial authority within the meaning of the constitutional doctrine of separation of powers” (People v. Superior Court (On Tai Ho) (1974) 11 Cal.3d 59, 68 [113 Cal.Rptr. 21, 520 P.2d 405]); accordingly, it “cannot constitutionally be subordinated to a veto of the prosecutor” (id. at p. 65; see Sledge v. Superior Court (1974) 11 Cal.3d 70, 72 [113 Cal.Rptr. 28, 520 P.2d 412]). The Legislature, recognizing this principle, expressly prohibited prosecutors from having such control when it passed Penal Code section 1001.2, subdivision (b). San Francisco’s program, however, violates the principle by allowing the prosecutor’s discretionary charging decision to control the court’s ultimate diversion determination.

The majority’s reliance on On Tai Ho and Sledge as authority for a contrary conclusion is misplaced. As will appear, those cases turn not on a simple chronological distinction between the “charging stage” of a case and the point at which the case is “before the court,” but rather on the character and consequence of the decision placed in the hands of the district attorney.

On Tai Ho and Sledge addressed questions raised by chapter 2.5, the pretrial diversion program for first-time drug offenders enacted by the Legislature in 1972. As initially adopted, that chapter authorized the district attorney to make the preliminary determination of a defendant’s eligibility for diversion. If the district attorney concluded the defendant was eligible, the probation department made a factual investigation for the court’s use at a subsequent suitability hearing. If the court then found the defendant suitable—and if the district attorney concurred—the court granted diversion. The court, however, was not authorized to grant diversion without the district attorney’s approval.

In On Tai Ho we held that the provision conditioning the court’s diversion determination on the district attorney’s concurrence violated the separation-of-powers doctrine. (11 Cal.3d at pp. 65-68.) In Sledge we concluded that the provision authorizing the prosecutor to make the preliminary eligibility determination did not violate that doctrine. (11 Cal.3d at pp. 73-74.)

From these cases the majority deduce that as long as prosecutorial discretion is exercised before charges are filed, that discretion does not impinge on judicial authority—even if it affects the defendant’s eligibility for diversion. (Majority opn., ante, at p. 85.) Although superficially appealing, the majority’s conclusion fails to take account of the essential differences between the earlier cases and the present case.

The diversion program we addressed in On Tai Ho contained no provision conditioning a defendant’s eligibility on a purely discretionary determination by the district attorney. The eligibility determination there, though made by the district attorney, was statutorily required to be based on specific objective factors relating to the type of offense charged and the defendant’s prior criminal record. (11 Cal.3d at p. 62.)Here, in sharp contrast, the disputed rule makes eligibility depend solely on the prosecutor’s discretionary charging decision.

Thus the prosecutor’s charging decision and the court’s diversion determination in On Tai Ho were independent, and our emphasis on chronology in that case served to underscore the judicial character of the latter. (See 11 Cal.3d at p. 65.) Under the San Francisco scheme, however, the two decisions are no longer independent: the local rules condition the court’s postfiling diversion determination on the district attorney’s discretionary prefiling charging decision. On Tai Ho's emphasis on chronology is therefore irrelevant to the question at hand.

Similarly, our approval in Sledge of a statute authorizing prosecutorial determination of eligibility for diversion rested not on mere chronology but on the character of the eligibility decision itself. First, our conclusion that the eligibility determination was a ministerial function rather than a judicial act was “predicated on” the objective nature of the information required for such a determination under Penal Code section 1000. (11 Cal.3d at pp. 73-74.) The act was not judicial, we observed, because “in discharging his duties under section 1000 the district attorney need not decide what facts are material and relevant to eligibility, as the Legislature has specified them in the statute.” {Id. at p. 74.) Second, we emphasized in Sledge that the district attorney’s decision was subject to judicial review. {Id. at pp. 75-76.)

Obviously neither condition applies here: the San Francisco rule allows an individual’s eligibility for diversion to be controlled by a prosecutorial decision that is neither guided by objective statutory criteria nor subject to judicial review. Consequently, our reasoning in Sledge does not compel a similar conclusion in the present case.

That chronology is not controlling is clear from our statement in On Tai Ho that “whether a power is judicial in nature depends not on the procedural posture of the case but on the substance of the power and the effect of its exercise. ... At whatever stage [diversion] occurs . . . it is an integral step in the process leading to the disposition of the case before the court, and therefore constitutes an exercise of judicial authority within the meaning of the constitutional doctrine of separation of powers.” (11 Cal.3d at p. 68.) Here the substance and effect of the district attorney’s discretionary decision is to determine in the first instance whether the court may even consider declaring the defendant eligible for diversion. Such a discretionary veto of the court’s diversion decision, whether invoked contemporaneously or prospectively, infringes on the authority of the court and thereby violates the separation of powers doctrine.

KAUFMAN, J., Concurring and Dissenting

I concur in the majority opinion to the extent it holds a local diversion program is not unlawful because the district attorney is given the authority to approve or disapprove the program as a whole. I dissent, however, from the majority’s determination that the district attorney may determine a particular individual is not eligible for diversion by a standardless decision to charge a wobbler as a felony.

In my view, that portion of the diversion program is invalid for two reasons; first, it contravenes the express provision in the enabling legislation which prohibits the district attorney from determining whether any particular defendant shall be diverted (Pen. Code, § 1001.2, subd. (b)); second, it constitutes a standardless delegation of legislative power to the executive branch of government, in violation of the constitutionally mandated separation of powers. (Cal. Const., art. Ill, § 3.)

The enabling statute authorizes local jurisdictions to adopt diversion programs for any offense “filed as a misdemeanor.” (Pen. Code, § 1001.1.) As I shall explain, that provision in the statute is perfectly valid except as applied to wobbler offenses, as to which prosecutors have unfettered discretion to “file” either as a misdemeanor or as a felony. The specific San Francisco diversion program here at issue is also valid in my view except as to those provisions which make a person accused of a wobbler either conditionally or absolutely ineligible for participation in the program, depending upon whether the offense is filed by the district attorney as a misdemeanor or a felony.

The decision to divert, that is the determination as to whether or not an accused meets the eligibility criteria for diversion and otherwise should be diverted is, as Justice Mosk’s opinion points out, a judicial function. However under the diversion program here in question, there is no diversion decision to be made if a wobbler is charged as a felony. The local guidelines clearly and unambiguously establish as an indispensable criterion of eligibility in the case of a person charged with a wobbler that the district attorney has not charged the offense as a felony. Thus the question we confront is not whether the district attorney may interfere with the court’s diversion decision, but whether the legislatively prescribed criteria as applied to wobblers are adequate in the first instance.

Manifestly, the establishment of eligibility criteria for diversion, like the establishment of eligibility criteria for probation or the specification of conduct constituting a crime, is a legislative function. (See Sledge v. Superior Court (1974) 11 Cal.3d 70, 74 [113 Cal.Rptr. 28, 520 P.2d 412]; People v. Lim (1941) 18 Cal.2d 872, 879 [118 P.2d 472].) Under the enabling legislation in question, the Legislature has, quite properly, established one basic criterion for diversion eligibility—the offense must have been filed as a misdemeanor. (Pen. Code, § 1001.1.)

With respect to the vast majority of offenses, the district attorney has no discretion whether to file a specific criminal charge as a misdemeanor or as a felony. The crime to be charged is statutorily defined as one or the other. (Pen. Code, § 17.) That is not the case, however, with respect to one class of offenses—wobblers. In such cases, the district attorney has plenary authority to determine whether to charge the crime as a misdemeanor or as a felony, in essence to define the crime as a misdemeanor or a felony for charging purposes.

Such latitude in the charging decision does not—absent patent discrimination—violate the equal protection clause. (Murgia v. Municipal Court (1975) 15 Cal.3d 286, 296-297 [124 Cal.Rptr. 204, 540 P.2d 44].) It does, however, clearly inject a new, discretionary element of executive decision-making into the otherwise nondiscretionary diversion eligibility criterion formulated by the Legislature.

The Legislature, in enacting the diversion statutes (Pen. Code, §§ 1001-1001.9), and the San Francisco Pretrial Diversion Management Committee, in adopting the diversion rules at issue, have made diversion eligibility for persons charged with wobblers turn on the discretionary charging decision of an executive officer, the district attorney. They have, in effect, delegated to the district attorney the power to determine eligibility in this one class of cases. Two questions are thus presented: 1) whether the delegation of this authority to the district attorney contravenes the express provision in the enabling legislation which prohibits the district attorney from determining whether any particular defendant shall be diverted (Pen. Code, § 1001.2, subd. (b)), and 2) whether such a delegation is lawful in the absence of standards to safeguard against arbitrary or capricious differential treatment of similarly situated persons. Because resolution of the second question may affect the answer to the first, I shall address these questions in reverse order.

It is well settled, of course, that the “doctrine prohibiting delegations of legislative power does not invalidate reasonable grants of power to an administrative agency, when suitable safeguards are established to guide the power’s use and to protect against misuse.” (People v. Wright (1982) 30 Cal.3d 705, 712 [180 Cal.Rptr. 196, 639 P.2d 267], italics added.) The legislative body must declare a policy and, at a minimum, fix primary standards for the implementation of that policy. (Birkenfeld v. City of Berkeley (1976) 17 Cal.3d 129, 167 [130 Cal.Rptr. 465, 550 P.2d 1001].) As we explained in Birkenfeld, however, even “legislative guidance by way of policy and primary standards is not enough if the Legislature ‘fail[s] to establish an effective mechanism to assure the proper implementation of its policy decisions.’ [Citation.] ‘The need is usually not for standards but for safeguards .... When statutes delegate power with inadequate protection against unfairness or favoritism, and when such protection can easily be provided, the reviewing courts may well either insist upon such protection or invalidate the legislation.’ [Citations.]” (17 Cal.3d at p. 169, italics omitted.)

As previously stated, the establishment of eligibility guidelines for diversion is preeminently a legislative function. In Sledge v. Superior Court, supra, 11 Cal. 3d 70, for example, we upheld a drug diversion procedure in which the district attorney conducted a preliminary screening for eligibility under specific criteria prescribed by statute. The diversion statutes at issue (Pen. Code, §§ 1000-1000.4) applied to a limited number of drug offenses, and set forth the following eligibility criteria: no prior narcotics convictions; no probation or parole violations; no evidence of the commission of a narcotics offense other than those listed in the statute; and the offense charged must not involve actual or threatened violence. (11 Cal.3d at p. 73.) Thus, we explained that “in discharging his duties under [Penal Code] section 1000 the district attorney need not decide what facts are material and relevant to eligibility, as the Legislature has specified them in the statute.” (11 Cal.3d at p. 74, italics added.)

By contrast, in the case before us no statutory criteria informed the district attorney’s decision to charge the wobbler as a felony rather than as a misdemeanor. The legislative branch in this case did not, and indeed could not, prescribe standards to govern the district attorney’s charging decision. For, as the majority points out, the charging function lies within the exclusive province of the executive branch and cannot be interfered with by the legislative branch of government. (See Daly v. Superior Court (1977) 19 Cal.3d 132, 148 [137 Cal.Rptr. 14, 560 P.2d 1193].) Moreover, so far as the record discloses, the district attorney has not himself promulgated such standards.

Thus, by tying diversion eligibility to the district attorney’s charging function, the diversion program effectively grants the district attorney unbridled discretion to determine who among those committing wobblers shall be conditionally eligible for diversion and who shall be absolutely ineligible. The result is that there is nothing to prevent various deputies in the district attorney’s office from disparately charging two individuals who commit the same offense and who are otherwise equally situated—one with a misdemeanor and the other with a felony—thereby rendering one conditionally eligible and the other absolutely ineligible for diversion.

It is quite true that the equal protection clause does not abrogate the prosecutor’s discretion to charge only a misdemeanor when he or she believes lenient treatment is warranted. (Murgia v. Municipal Court, supra, 15 Cal.3d at pp. 296-297.) However, when the executive’s exercise of the charging function also constitutes the exercise of delegated legislative power, as it does in this case, that power must be circumscribed by “suitable safeguards . . . to guide the power’s use and to protect against misuse” (People v. Wright, supra, 30 Cal.3d at p. 712), or it cannot be upheld. (Birkenfeld v. City of Berkeley, supra, 17 Cal.3d at p. 169.)

It is true that such standards, while not “expressed,” may nevertheless be “implied” in appropriate circumstance from the legislative purpose. Here for example, because the purpose of the statute is to “preserve scarce resources for the more serious offenders,” an implied standard might be found that eligibility for diversion should generally vary inversely with the seriousness of the offense. I am not persuaded, however, that such a broad “implied” standard is legally sufficient or practically adequate to protect against the sort of indiscriminate and capricious charging decisions with which I am concerned. As noted earlier, the need is not so much for general standards, much less “implied” standards, but specific safeguards. (Birkenfeld v. City of Berkeley, supra, 17 Cal.3d at p. 169.) Therefore, in the absence of standards in the program itself or standards established by the district attorney which might be said to have been approved by the legislative agencies, I conclude that the Legislature and the San Francisco Pretrial Diversion Management Committee violated the separation of powers doctrine by delegating legislative power to the district attorney to determine the diversion eligibility of persons charged with wobblers, without establishing requisite guidelines for the exercise of that power.

It is equally clear from the foregoing discussion that, as applied to wobblers, the San Francisco diversion program violates the express provision in the enabling legislation which prohibits the district attorney from determining the diversion eligibility of any particular individual. Penal Code section 1001.2, subdivision (b), in part provides: “Nothing in this subdivision shall authorize the prosecutor to determine whether a particular defendant shall be diverted.” As established by the Legislature, the basic criterion of diversion eligibility is that the charged offense be “filed as a misdemeanor.” (Pen. Code, § 1001.1.) In the case of wobblers, however, the district attorney rather than the Legislature decides whether a specified offense will be filed as a misdemeanor or a felony. Thus, in direct contravention of Penal Code section 1001.2, subdivision (b), the district attorney effectively “determines” whether a defendant who commits a wobbler “shall be diverted.”

I conclude, therefore, that as applied to wobblers the diversion program at issue impermissibly delegates legislative authority to the district attorney, in violation of article III, section 3 of the California Constitution, and improperly permits the district attorney to determine whether a particular defendant shall be diverted, in violation of Penal Code section 1001.2, subdivision (b).

Accordingly, I would affirm the judgment of the Court of Appeal insofar as it invalidated the program as it relates to wobblers.

Panelli, J., concurred.

Petitioners’ application for a rehearing was denied October 13, 1988. Mosk, J., and Kaufman, J., were of the opinion that the petition should be granted. 
      
       As explained more fully below (post, p. 75), in 1982 the Legislature enacted two separate statutory schemes authorizing local entities to adopt pretrial misdemeanor diversion programs. Both statutory schemes are codified in title 6, part 2 of the Penal Code. One scheme— sections 1001 to 1001.9—appears as chapter 2.7 of title 6 (hereafter chapter 2.7); the other— sections 1001.50-1001.55—as chapter 2.9 of title 6 (hereafter chapter 2.9). Although the two chapters differ in some respects, a number of the provisions of the two schemes are identical. The local diversion program at issue in this case was adopted pursuant to the chapter 2.7 scheme. Unless otherwise noted, all statutory references are to the Penal Code.
     
      
       The applicable local diversion eligibility requirements provided in full:
      “A. Offense
      
        "All persons who are charged with an offense filed as a misdemeanor are eligible for the diversion program except under the following circumstances where they are not eligible-.
      
      “1. Persons with a prior felony conviction and persons who have been committed to the California Youth Authority.
      “2. Persons with two or more prior misdemeanor convictions; persons with one prior misdemeanor conviction within 5 years of the commission of offenses currently charged, or persons with one similar prior misdemeanor conviction at any time.
      “3. Persons charged with infractions.
      
        
        “4. Persons initially charged by the District Attorney’s office with misdemeanor violations of a section chargeable as either a felony or a misdemeanor (so called ‘wobblers’).
      
      
        “5. Persons charged with drug offenses included in Penal Code Section 1000. Persons charged with violations of Section 4143(a) of the Business and Professions Code are eligible for diversion as long as the period of diversion is no less than six months.
      
        “6. Persons charged with offenses listed in Title 2, Chapters 1 through 6 inclusive, known as ‘Control of Dangerous Weapons,’ beginning at Penal Code Section 12000 and continuing though Section 12601.
      “7. Persons charged in cases wherein a dangerous or deadly weapon was used, including all 417 P.C. violations.
      “8. Persons charged in cases involving the use or the attempted use of violence against the person of another. In no instance shall an offense involving injury to a victim (as defined in Section D3 herein) be diverted.
      “9. Persons charged with offenses wherein restitution or damage exceeds $1,000.00.
      “10. Persons who have been previously granted diversion, either under this program or any other; persons who have previously failed to complete diversion successfully, under this program or any other; persons who are currently on diversion, under this program or any other; and persons who have previously completed diversion, under this program or any other. Persons who are currently awaiting approval of an eligibility report for diversion are not eligible.
      “11. Persons charged with more than one offense arising out of more than one act, event or transaction.
      “12. Persons charged with auto tampering offenses (10852-10853 VC) are eligible. Persons charged with any other Vehicle Code violations, including driving under the influence of intoxicants are not eligible.
      “13. Persons charged with annoying or molesting children (647a and 314.1 PC).
      “14. Persons charged with offenses involving public corruption, perjury, threatening or intimidating witnesses, failure to appear on a promise to appear (PC 1320), violations of the California Unemployment Insurance Code where the amount exceeds $400.00, violations of the Revenue and Taxation Code, Welfare and Institutions Code, or food stamp fraud.
      “B. Variance From the Above Provisions
      “1. The above eligibility provisions are the sole and exclusive provisions by which diversion may be granted. In every case where the person, based upon the foregoing, is not eligible, the program shall so report to the court in the eligibility report and shall at no time take any further action, monitor the person, nor allow the person to participate in the program.
      “2. No exceptions to the above eligibility criteria may be made in the following cases:
      
      “1. Offenses which were originally filed as felony charges and thereafter reduced by the court or District Attorney pursuant to Penal Code Sections 17(b)(4) end 17(b)(5);
      
      “2. Offenses involving firearms or other deadly or dangerous weapons;
      “3. Offenses involving injury to a victim. Injury means any significant or substantial physical injury which requires professional medical treatment, whether sought or not.
      “3 .In the remaining misdemeanor cases, including offenses which could have been charged as felonies but which were charged initially by the District Attorney’s office as misdemeanor violations of the same sections (see Section A4 above), the court may permit a defendant to be diverted if it finds good cause to make an exception to the above exclusionary criteria and finds that it is in the interest of justice to do so. However, no such exception shall be made and diversion allowed unless and until the court in open session on the record states its reasons for determining that good cause and the interests ofjustice justify making an exception to the criteria set out above. ” (Italics added.)
     
      
       Although the superior court filed no written opinion, its oral comments suggest that its ruling may have rested on a mistaken belief that the guidelines provided identical treatment to wobblers filed as felonies and wobblers filed as misdemeanors. Because, as we explain hereafter, we conclude that the superior court reached the proper decision, it is of no consequence that the theory on which the court reached its conclusion may have been flawed. (See generally 9 Witkin, Cal. Procedure (3d ed. 1985) Appeal, § 259, p. 266 and cases cited.)
     
      
       Defendant properly sought review of the superior court ruling by filing a petition for an extraordinary writ in the Court of Appeal (Code Civ. Proc., § 904.1, subd. (a)(4)), but the municipal court was not the appropriate respondent. Because the petition sought review of the action of the superior court, the superior court, rather than the municipal court, was the proper respondent. (See Serna v. Superior Court (1985) 40 Cal.3d 239, 245-246 [219 Cal.Rptr. 420, 707 P.2d 793].) The People, real party in interest in any event, have not questioned the procedural posture of this matter, and because the error does not affect the jurisdiction of the Court of Appeal or of this court, the merits of the Court of Appeal decision are properly before us.
     
      
       Section 1001.2, subdivision (b) reads in full: “The district attorney of each county shall review annually any diversion program established pursuant to this Chapter, and no program shall continue without the approval of the district attorney. No person shall be diverted under a program unless it has been approved by the district attorney. Nothing in this subdivision shall authorize the prosecutor to determine whether a particular defendant shall be diverted.”
      As discussed below, defendant also contends that the particular local wobbler rule at issue here conflicts with the concluding sentence of section 1001.2, subdivision (b). We consider that matter in a subsequent part of our opinion. (See post, pp. 78-81.)
     
      
       Former section 1001, the initial section of the 1977 version of chapter 2.7, provided in this regard: “It is the intent of the Legislature that neither this chapter, Chapter 2.5 (commencing with Section 1000) of this title [i.e., the drug diversion provisions enacted in 1972], nor any other provision of law be construed to preempt other current or future pretrial or precomplaint diversion programs. . . .”
     
      
       Section 17, subdivision (b)(5) reads in full: “When a crime is punishable, in the discretion of the court, by imprisonment in the state prison or by fine or imprisonment in the county jail, it is a misdemeanor for all purposes under the following circumstances:... (5) When, at or before the preliminary examination or prior to filing an order pursuant to Section 872, the magistrate determines that the offense is a misdemeanor, in which event the case shall proceed as if the defendant has been arraigned on a misdemeanor complaint.”
     
      
       Section 1001.51, subdivision (c) provides in full: “This chapter shall not apply whenever the accusatory pleading charges the commission of a misdemeanor : [H] (1) For which incarceration would be mandatory upon conviction of the defendant, [fl] (2) For which registration would be required pursuant to Section 290 upon conviction of the defendant. []|] (3) Which the magistrate determines shall be prosecuted as a misdemeanor pursuant to paragraph (5) of subdivision (b) of section 17. [H] (4) Which involves the use of force or violence against a person, unless the charge is a violation of Section 241 or 243. [fl] (5) For which the granting of probation is prohibited, [fi] (6) Which is a driving offense punishable as a misdemeanor pursuant to the Vehicle Code.” (Italics added.)
     
      
       The criteria which a prosecutor uses to determine whether to charge a wobbler as a felony or a misdemeanor are generally the same criteria that are considered in determining whether felony or misdemeanor charges should be filed outside of the wobbler context when the defendant’s conduct may be punished under either a felony or misdemeanor provision: e.g., the severity of the present crime, the accused’s prior record, and the probability of the defendant’s continued criminal conduct. (See generally Cal. Dist. Attys. Assn., Uniform Crime Charging Standards, supra, std. II.D., pp. 33-40; 1 ABA Standards for Criminal Justice, supra, std. 3-3.9.)
     
      
       That section provides that “Nothing in this subdivision [which grants the district attorney veto power over a chapter 2.7 program] shall authorize the prosecutor to determine whether a particular defendant shall be diverted."
     
      
       Penal Code section 1000 provided, in relevant part, that a defendant was eligible for diversion if the district attorney determined that all of the following applied: “(1) The defendant has no prior conviction for any offense involving narcotics or restricted dangerous drugs, [fl] (2) The offense charged did not involve a crime of violence or threatened violence, [t!] (3) There is no evidence of a violation relating to narcotics or retricted dangerous drugs other than a violation of the sections listed in this subdivision. []]] (4) The defendant has no record of probation or parole violations.”
     
      
       At oral argument counsel for real party in interest was asked whether there existed in the office of the district attorney any charging guidelines or standards that would serve to prevent different charging decisions being made by different deputies on the same facts and circumstances. The initial reply was that it must be presumed the district attorney will “conscientiously do his duty” and that the Constitution prohibits “discriminatory prosecution.” Upon further inquiry, the response was: “There would be the local. . ., whatever the district attorney’s office’s standards are . . . [pause] .... No. There are none in the guidelines . . . .” (Italics supplied.)
     