
213 Cal.App.2d 238 (1963)
WENDELL D. TATE et al., Petitioners,
v.
THE SUPERIOR COURT OF LOS ANGELES COUNTY, Respondent; NICHOLAS T. LEVATO, Real Party in Interest.
Civ. No. 26836. 
California Court of Appeals. Second Dist., Div. Three.  
Feb. 20, 1963.
 Jarrett & Morgan, Frank W. Woodhead, Chase, Rotchford, Downen & Drukker, Richard L. Berger and Henry F. Walker for Petitioners.
 Harold W. Kennedy, County Counsel, Donald K. Byrne and John J. Collins, Deputy County Counsel, for Respondent.
 Arthur Garrett, T. Groezinger, Loton Wells, Edwin J. Dubiel, Arthur Hershenson and Arthur Katz for Real Party in Interest.
 FILES, J.
 This proceeding involves the application of the principle of Witt v. Jackson, 57 Cal.2d 57 [17 Cal.Rptr. 369, *242 366 P.2d 641], to a personal injury action which was at issue before that case was decided. A plaintiff, who has received compensation from his employer, has brought a common-law negligence action against three other parties. These defendants now desire to plead that the employer was also negligent, attempting thereby to bar such portion of the plaintiff's recovery as would be applied to the benefit of the employer.
 The facts before this court, as set forth in the petition and the return of the real party in interest, are not in substantial dispute.
 On January 12, 1959, Nicholas T. Levato (plaintiff) brought an action in the superior court (respondent) against Wendell D. Tate (defendant Tate), Jack H. MacDonald Company and Jack H. MacDonald (collectively called defendants MacDonald). That action is to recover damages for bodily injuries sustained by plaintiff on January 13, 1958, while working for a contractor named Ekins. Plaintiff's job was to place insulation above a suspended ceiling in a building which was under construction. Plaintiff's contention is that the portion of the ceiling on which he was working fell, injuring him, due to the negligence of the defendants. Defendant Tate and defendants MacDonald appeared by separate counsel and answered the complaint, denying their own negligence and pleading as affirmative defenses contributory negligence and assumption of risk. On April 12, 1960, the pretrial conference order was made, setting the action for trial on August 3, 1960. On plaintiff's motion the trial was continued to December 8, and again to March 29, 1961. There was a continuance to July 17, 1961, at the joint request of plaintiff and the MacDonalds, and then at the request of defendant Tate, to July 26 and November 29, 1961. It was continued to April 10, 1962, on motion of the MacDonalds, and to August 3, 1962, on motion of plaintiff.
 On June 20, 1962, the court granted the motion of Tate for leave to amend his answer to include a fourth defense. By this new answer Tate alleged that the accident described in the complaint was proximately caused by the contributory negligence of plaintiff's employer, Ekins; that Ekins was insured under the Workmen's Compensation Laws with the California State Compensation Insurance Fund; that said fund has paid money for plaintiff's medical care and disability compensation as a result of this accident, and that any award of damages in favor of plaintiff against defendant Tate should be *243 reduced by the amounts paid or to be paid in the future by the fund to and for plaintiff by reason of said accident and injuries.
 Plaintiff demurred to this amendment to the answer on the grounds (1) that it failed to state a defense and (2) that it was barred by section 338, subdivision 1, of the Code of Civil Procedure (i.e., the three-year statute of limitations for an action upon a liability created by statute). On July 31, 1962, this demurrer was argued and submitted. On October 18, 1962, the respondent court made its order sustaining the demurrer. The grounds of the ruling are not disclosed in the record here.
 On July 31, 1962, defendants MacDonald brought on for hearing their motion for leave to file an amended answer to raise the defense of the employer's negligence. This motion was also denied by the court on October 18, 1962.
 On October 2 and 3, 1962, while the respondent court had the demurrer to Tate's answer and the MacDonalds' motion under submission, the defendants filed separate motions for leave to file cross-complaints. These proposed cross-complaints named the plaintiff's employer, Ekins, and his compensation carrier, the California State Compensation Insurance Fund, as cross- defendants. The allegations of the cross-complaints were substantially the same as the proposed affirmative defenses. The prayer of the cross- complaints was that the court reduce the amount of damages to which the plaintiff would otherwise be entitled by the amounts which have been and will be paid to plaintiff by cross-defendants under the Workmen's Compensation Act.
 The two motions for leave to file cross-complaints were also denied on October 18, 1962.
 On October 20, 1962, Tate and the MacDonalds petitioned this court for a writ of mandate to compel the trial court to set aside its rulings of October 18 and to allow the affirmative defenses and cross-complaints. Meanwhile, the trial date has again been postponed, first to await the ruling of the respondent court on the submitted motions, and now to await the disposition of this mandamus proceeding.
 Under the Workmen's Compensation Act, although compensation is the employee's exclusive remedy against his employer (Lab. Code,  3601), this does not affect the injured workman's right of action for damages against any person other than his employer. Labor Code, section 3852, confirms the right of the employee to recover damages against a third *244 person, and also provides that any employer who pays compensation may likewise bring an action against such third person. Either the employer or the employee may join in such an action brought by the other, and if each sues independently the actions are required to be consolidated (Lab. Code,  3853). If the employee alone prosecutes the action against the third party, the employer may nevertheless recover what he has paid out by applying for a lien on the employee's judgment (Lab. Code,  3856, subd. (b)).
 [1] Insurance Code, section 11662, provides that when an insurance carrier pays any compensation for which the employer is liable, the carrier is subrogated to the rights of the employer and may enforce such subrogated rights in its own name. The chapter of the Labor Code which provides for the employer's remedies against the third party tortfeasor defines "employer" to include the insurer. ( 3850, subd. (b).) Thus it appears that the remedies open to the employer under this chapter of the Labor Code are likewise available to the insurance carrier acting in its own name.
 [2] The result is that the employer or the insurance carrier who has paid compensation to an injured employee may benefit from the action brought by the employee against the negligent third party whether the employer or carrier joins in the action or not. But the Labor Code gives no indication as to whether the employer's right of reimbursement is defeated when the injuries are caused by the concurring negligence of the employer and a third party.
 [3] Witt v. Jackson, 57 Cal.2d 57 [17 Cal.Rptr. 369, 366 P.2d 641] (decided December 4, 1961), was an action brought by two Los Angeles police officers, Witt and Grossman, for bodily injuries sustained when their police car was struck by a vehicle owned and operated by defendant Jackson. The City of Los Angeles intervened in the action to recover for damages to its automobile and for workmen's compensation benefits and medical expenses paid to the plaintiffs. The jury returned a verdict in favor of defendants. On appeal the Supreme Court concluded that the judgment against Grossman should be reversed because of error in instructions, but the judgment against Witt should be affirmed, there being evidence that he was contributively negligent. Since the negligence of Witt was imputed to his employer, the city could not recover either for damage to its car or for compensation paid to Witt. The Supreme Court also concluded that the negligence *245 of the employer barred any recovery of the amount which it had paid as compensation to Grossman.
 The opinion called attention to the three ways in which an employer who pays compensation may recover the amount so expended against a negligent third party: by an independent action, by joining in the employee's action, or by claiming a lien on the employee's judgment. After a review of authorities, the opinion of the court declared (at p. 72):
 "Thus, whether an action is brought by the employer or the employee, the third party tortfeasor should be able to invoke the concurrent negligence of the employer to defeat its right of reimbursement, since, in either event, the action is brought for the benefit of the employer to the extent that compensation benefits have been paid to the employee." (57 Cal.2d at p. 72.)
 Two appellate courts have since been required to consider the applicability of the Witt doctrine to pending cases. City of Sacramento v. Superior Court, 205 Cal.App.2d 398 [23 Cal.Rptr. 43], decided July 2, 1962, grew out of an action brought by Gerald Smith against the city for personal injuries allegedly sustained by reason of the negligence of a city employee on December 21, 1960. The action was filed February 21, 1961, and pretried in January 1962. On April 5, 1962, after the Witt decision had come down, defendants made a motion for leave to file a cross-complaint to join, as cross- defendants, Smith's employer and the employer's compensation carrier who had paid benefits to Smith. The theory of the motion was that Smith's employer had been guilty of negligence contributing to the accident and that this fact would necessitate a reduction of the defendant city's liability by the amount of the compensation benefits. The trial court denied the motion. The appellate court then granted a writ of mandamus to compel the court to grant the motion.
 Chick v. Superior Court, 209 Cal.App.2d 201 [25 Cal.Rptr. 725], decided November 2, 1962, arose out of an injury which occurred in 1954 in the construction of a building. Plaintiff, an employee of a subcontractor, sued the general contractor for negligence. After the Witt case was decided defendants moved to amend their answer to allege that the negligence of the employer barred recovery to the extent of the compensation benefits paid. Defendants also moved to compel joinder of the employer and his compensation carrier "as necessary parties plaintiff." The trial court denied the motion to amend upon the ground that the Witt rule could not apply *246 where the injury occurred before the effective date of the contribution statute of 1957 (Code Civ. Proc.,  875-880), and denied the motion to join parties because the motion to amend had been denied. The appellate court granted a writ of mandamus requiring the trial court to allow the amendment to the answer, and to act upon the motion to compel joinder of additional parties plaintiff "in the event the court deems their presence necessary to raise the proposed defense."
 [4] In the case at bench respondent and real party in interest contend that the pro tanto defense of the employer's contributory negligence should not apply unless the employer has brought his own action or joined in the employee's action to recover compensation benefits paid. This point has been decided against respondent in both the Sacramento and Chick cases. We agree with what was said in the Sacramento case: the Supreme Court in Witt could not have been more explicit in declaring that the rule applies "whether an action is brought by the employer or the employee." Furthermore, it would be incongruous to hold that the amount recoverable from the third party tortfeasor should depend upon whether the employer seeks his recovery by intervening in the employee's action before trial or asserting a lien on the employee's recovery after trial.
 The fact that the employer and his compensation carrier are not parties is not a ground for denying to defendants the opportunity to plead an applicable defense. When it appears that an indispensable or necessary party has not been joined, it is the court's duty, under Code of Civil Procedure, section 389, to order him brought in.
 [5] We do not believe, however, that the assertion of this pro tanto defense thereupon makes the employer or the carrier necessary or indispensable parties. Labor Code, section 3853, requires that when the employee brings his action he must give written notice to the employer. If the latter elects not to join as a party, the employee, in effect, represents the common interest in seeking a recovery which the employer may share under Labor Code, section 3856, subdivision (b).
 Code of Civil Procedure, section 369, states the general principle that a trustee of an express trust or a person expressly authorized by statute may sue without joining the persons for whose benefit the action is prosecuted. Whenever more than one person is beneficially interested in a single cause of action, a conflict of interest may arise between them if the defendant should plead a defense or offset which will defeat *247 one but not all of those beneficially interested in the plaintiff's case. Yet the possibility that this could occur does not result in any requirement that the persons beneficially interested be joined in every case. Code of Civil Procedure, section 369, makes it unnecessary.
 The clearly expressed policy of the Workmen's Compensation Act is to give the employer and the carrier the option of pursuing their subrogation rights in their own names, or in permitting the action to be prosecuted for their benefit in the employee's name.
 Labor Code, section 3853, requires that when the employee brings his action against the third party tortfeasor he must give to the employer written notice by personal service or registered mail. The employer and the carrier then have the absolute right to intervene at any time before trial.
 Doubtless, employers and carriers sometimes see advantages to themselves in permitting the action to go to trial in the employee's name alone. Otherwise they would always exercise their right to intervene. In every case the absence of the employer as a party of record is a result of his own preference. Those who enjoy these rights of subrogation are, in most cases, sophisticated litigants: qualified insurance companies and permissibly self- insured employers. Now that Witt v. Jackson is in the books, anyone who pays compensation is likely to be aware of the contributory negligence problem and will weigh accordingly the privilege of intervening. [6] In view of the statutory policy of giving the employer the option of remaining off the record, and the opportunity given to the employer to participate as he chooses, we cannot say that the employer is a person whose "interest would be inequitably affected or jeopardized" so as to make his joinder indispensable under Code of Civil Procedure, section 389.
 It is noteworthy also that Lovette v. Lloyd, 236 N.C. 663 [73 S.E.2d 886], which was cited in the Witt opinion for its persuasive reasoning (57 Cal.2d at pp. 71-72), held that it was error for the trial court to order the joinder of the employer and the compensation carrier against their will.
 [7] It is not necessary for the defendant to cross-complain in order to assert his pro tanto defense that the employer was contributively negligent. In the Sacramento case the defendant proposed to file a cross-complaint (apparently for declaratory relief) and the appellate court held he was entitled to do *248 so. However, as the Chick opinion points out, the Sacramento opinion does not say that this is the only way to do it.
 The issue of the employer's contributory negligence is a matter of defense, and was so described in the Witt case. Code of Civil Procedure, section 437, requires that new matter constituting a defense be stated in the answer. Code of Civil Procedure, section 442, authorizes a cross-complaint when "the defendant seeks affirmative relief against any person. ..." The proposed cross-complaints in the case at bench do not seek any affirmative relief, not even a declaration of rights. They are no more than repetitions of the averments of the answer which counsel cast in a different form, doubtless in an excess of caution.
 [8a] Respondent has asserted in its return that the action bought by Levato against Tato and the MacDonalds does not attempt to recover anything for the benefit of the employer and that the pretrial order "makes this abundantly clear." The full pretrial order is not before this court and we cannot assess the factual basis for that assertion. The conclusion is erroneous, however, as a matter of law.
 [9] In Levato's action against Tate and the MacDonalds he is entitled to plead and prove "all damages proximately resulting from" the alleged injury, undiminished by any compensation benefits which he has received or will receive. (Lab. Code,  3852.) Some of his provable damages--such as the reasonable value of medical services--will doubtless duplicate what the compensation carrier has already paid, while other elements of damage--notably pain and suffering--are not the subject of compensation under the Workmen's Compensation Act. However, unless the employer's recovery is barred by his contributory negligence, he will be entitled to a first lien on the entire amount the employee recovers after litigation expenses, regardless of what elements of damage the employee proves. (Heaton v. Kerlan, 27 Cal.2d 716 [166 P.2d 857].) [10] If, as respondent seems to suggest, Levato does not intend in this action to recover any elements of damage which duplicate his compensation benefits, that fact will not prevent the employer from asserting the lien which sections 3856 and 3857 give him for benefits paid, and offsetting the balance of the employee's net recovery against any future benefits payable by him or his carrier, as provided in section 3858. [8b] This action is necessarily, as a matter of law, one brought on behalf of the employer, if the employer has made payments which can be recouped under sections 3856- 3858. *249
 Another ground upon which respondent court denied leave to amend the answer was that the case should be decided upon the basis of the law applicable at the date of the injury, i.e., as though Witt v. Jackson had not been decided. This point was decided against respondent's contention in the Chick case. The decision in Witt v. Jackson did not purport to change the law, but to declare it as the court then saw it. Earlier decisions which had reached a contrary result were said to have been based upon obsolete reasoning. (57 Cal.2d at p. 70.) Neither the employee nor the employer here acted in reliance upon the earlier decisions (cf. Aced v. Hobbs-Sesack Plumbing Co., 55 Cal.2d 573, 580 [12 Cal.Rptr. 257, 360 P.2d 897]) and they can claim no vested right in the continued application of a theory which has now been rejected as out of harmony with present policies and concepts of justice.
 [11] The decision of a court, unlike the act of a Legislature, necessarily speaks retrospectively. The Supreme Court, in deciding Witt v. Jackson, supra, announced on December 4, 1961, the legal consequences of an automobile collision which had occurred on March 3, 1958. That opinion of the Supreme Court is now being looked to as a precedent in determining the legal relationships which arose out of Levato's accident of January 13, 1958. In following the Witt decision this court is applying the law applicable at the date of the injury.
 Both the demurrer to the Tate answer, which was sustained, and the return of the respondent court raise the statute of limitations as a ground for refusing leave to plead the Witt defense at this time. The theory appears to be that the defendants, Tate and the MacDonalds, are in effect attempting to state a cause of action for indemnification or contribution against the employer, and that the cause of action arose at the date of the injury in 1958. We do not so construe the Witt opinion or the principles on which it rests. [12] Where the employer is guilty of contributory negligence, he should not be permitted to "take advantage of his own wrong," and hence the employee should not be allowed to recover money which will ultimately pass into the guilty employer's hands. (See 57 Cal.2d at p. 72.) [13] Such a defense is no more cut off by limitations than is the defense that the employee can recover nothing because of his negligence.
 The motions for leave to amend were supported by an ample showing of good cause. Tate's motion for leave to amend his *250 answer was granted on June 20, 1962. This was a decision by the trial court that the motion was supported by an adequate showing of diligence and good faith. The denial of the MacDonalds' motions, heard on July 31, 1962, would indicate that the court, in the exercise of its discretion, found the opposite. It is perfectly clear, however, that if Tate is entitled to plead this defense, the MacDonalds are no less entitled to it, and it would be absurd to allow the issue to be litigated and not give the MacDonalds the benefit of it.
 [14] In support of defendants' position there was before the respondent court an affidavit incorporating the testimony given by plaintiff on his deposition. Plaintiff testified that his employer had directed him to work on top of a suspended ceiling, where his weight rested on 2-inch by 3- inch strips of wood which were attached to 2-by-4 runners; and that one of these 2-by-3 strips pulled away from its supports, causing plaintiff to fall. The record also contained the affidavit of defendant Tate to the following effect: that he is in the business of installing acoustical tile and the ceilings to support such tile; that he installed the ceiling in the building where plaintiff allegedly was injured; that this installation was in accordance with the specifications and was the standard method; that the 2- by-3 strips are not intended to support the weight of a man, and that when it is necessary for a workman to go in the ceiling area, custom and practice require that he put his weight on planks placed over the 2-by-4 runners as catwalks.
 On this evidentiary showing there can be no doubt that the defendants have some bona fide reason for contending, as they propose to do by their amended answers, that the plaintiff's employer was negligent in failing to provide a safe place to work. (See Lab. Code,  6400-6404.)
 The history of this litigation negates any inference that any party considers that a short delay would be prejudicial. There is no reason to believe that allowing the amendments will either add to the complexity of the trial or delay it significantly. We have no doubt that the causes of this accident will be thoroughly canvassed at the trial, whether the employer's negligence is pleaded in the answer or not.
 It is most unlikely that there will be any controversy in this case over the fact that compensation was paid, or the amount. In most cases, it would seem that this issue could be eliminated at pretrial.
 [15] The rules of pleading today are no less liberal than *251 they were in 1892 when the Supreme Court said: "It can very rarely happen that a court will be justified in refusing a party leave to amend his pleading so that he may properly present his case, and obviate any objection that the facts which constitute his cause of action or his defense are not embraced within the issues, or properly presented by his pleading." (Guidery v. Green, 95 Cal. 630, 633 [30 P.786].) [16] Where it appears that the trial court has made a ruling which deprives a party of the opportunity to plead his cause of action or defense, relief by mandamus may be appropriate to prevent a needless and expensive trial and reversal. (Souza & McCue Constr. Co. v. Superior Court, 57 Cal.2d 508 [20 Cal.Rptr. 634, 370 P.2d 338]; Carter v. Superior Court, 142 Cal.App.2d 350, 359 [298 P.2d 598].)
 Let a peremptory writ of mandamus issue requiring the respondent court to set aside its order sustaining the demurrer to Tate's amended answer and to overrule said demurrer, and to set aside its order denying the MacDonalds' motion for leave to amend their answer, and to grant leave to amend. Petitioners' prayer for relief with respect to their cross-complaints is denied.
 Shinn, P. J., and Ford, J., concurred.
