Closed Bug 1686227 Opened 4 years ago Closed 4 years ago

Misleading error handling code in emitPrivateMethodInitializer

Categories

(Core :: JavaScript Engine, task)

task

Tracking

()

RESOLVED FIXED
86 Branch
Tracking Status
firefox86 --- fixed

People

(Reporter: mgaudet, Assigned: mgaudet)

Details

Attachments

(1 file)

In emitPrivateMethodInitializer there's a check:

  FunctionNode* funNode = prop->as<ClassMethod>().initializerIfPrivate();
  if (!funNode) {
    return false;
  }

This is misleading, as !funNode doesn't indicate an exception condition, but rather would indicate that you have no initializer. Yet, at this point, we should always have an initializer, either real or synthesized.

Assignee: nobody → mgaudet
Status: NEW → ASSIGNED
Pushed by mgaudet@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/2b7aede3b3c3 Misleading error handling code in emitPrivateMethodInitializer r=tcampbell
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 86 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: