Skip to content

COMPILE_TIME_ERROR.MISSING_OBJECT_PATTERN_GETTER_NAME in a few tests #1637

@scheglov

Description

@scheglov

The code is like

class A {
  final int foo;
  const A(this.foo);
}

void f(x) {
  if (x case {0: A(1)}) {}
}

Here A(1) is a pattern, and we have to say A(foo: 1) to make it a valid object pattern. Alternatively we can use const A(1). I'm not sure what was your intention in this test though.

co19/LanguageFeatures/Patterns/map_A01_t01
co19/LanguageFeatures/Patterns/map_A01_t02
co19/LanguageFeatures/Patterns/map_A01_t03

Metadata

Metadata

Assignees

Labels

bad-testReport tests in need of updates. When closed, the tests should be considered good

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions