blob: ba70263ac5419d608c99adaa6d43222f48297d25 [file] [log] [blame]
library;
//
// Problems in library:
//
// pkg/front_end/testcases/macros/library_members_lib.dart:8:6: Error: Member 'existingMethod' conflicts with an existing member of the same name in the augmented library.
// Try changing the name of the member or adding an 'augment' modifier.
// void existingMethod() {
// ^^^^^^^^^^^^^^
// pkg/front_end/testcases/macros/library_members.dart:7:6: Context: This is the existing member.
// void existingMethod() {
// ^^^^^^^^^^^^^^
//
// pkg/front_end/testcases/macros/library_members_lib.dart:11:6: Error: Declaration 'existingMethod2' conflicts with an existing declaration of the same name in the augmented library.
// Try changing the name of the declaration.
// void existingMethod2() {
// ^^^^^^^^^^^^^^^
// pkg/front_end/testcases/macros/library_members.dart:22:7: Context: This is the existing member.
// class existingMethod2 {}
// ^^^^^^^^^^^^^^^
//
// pkg/front_end/testcases/macros/library_members_lib.dart:17:14: Error: Augmentation member 'orphanedMethod' doesn't match a member in the augmented library.
// Try changing the name to an existing member or removing the 'augment' modifier.
// augment void orphanedMethod() {
// ^^^^^^^^^^^^^^
//
// pkg/front_end/testcases/macros/library_members_lib.dart:33:7: Error: Class 'ExistingClass' conflicts with an existing class of the same name in the augmented library.
// Try changing the name of the class or adding an 'augment' modifier.
// class ExistingClass {}
// ^^^^^^^^^^^^^
// pkg/front_end/testcases/macros/library_members.dart:19:7: Context: This is the existing class.
// class ExistingClass {}
// ^^^^^^^^^^^^^
//
// pkg/front_end/testcases/macros/library_members_lib.dart:34:7: Error: Declaration 'ExistingClass2' conflicts with an existing declaration of the same name in the augmented library.
// Try changing the name of the declaration.
// class ExistingClass2 {}
// ^^^^^^^^^^^^^^
// pkg/front_end/testcases/macros/library_members.dart:23:6: Context: This is the existing member.
// void ExistingClass2() {}
// ^^^^^^^^^^^^^^
//
// pkg/front_end/testcases/macros/library_members_lib.dart:37:15: Error: Augmentation class 'OrphanedClass' doesn't match a class in the augmented library.
// Try changing the name to an existing class or removing the 'augment' modifier.
// augment class OrphanedClass {}
// ^^^^^^^^^^^^^
//
// pkg/front_end/testcases/macros/library_members_lib.dart:23:10: Error: Member 'existingSetter' conflicts with an existing member of the same name in the augmented library.
// Try changing the name of the member or adding an 'augment' modifier.
// void set existingSetter(_) {
// ^^^^^^^^^^^^^^
// pkg/front_end/testcases/macros/library_members.dart:13:10: Context: This is the existing member.
// void set existingSetter(_) {
// ^^^^^^^^^^^^^^
//
// pkg/front_end/testcases/macros/library_members_lib.dart:29:18: Error: Augmentation member 'orphanedSetter' doesn't match a member in the augmented library.
// Try changing the name to an existing member or removing the 'augment' modifier.
// augment void set orphanedSetter(_) {
// ^^^^^^^^^^^^^^
//
// pkg/front_end/testcases/macros/library_members.dart:26:3: Error: Method not found: 'orphanedMethod'.
// orphanedMethod();
// ^^^^^^^^^^^^^^
//
// pkg/front_end/testcases/macros/library_members.dart:27:3: Error: Setter not found: 'orphanedSetter'.
// orphanedSetter = 0;
// ^^^^^^^^^^^^^^
//
// pkg/front_end/testcases/macros/library_members.dart:28:7: Error: Couldn't find constructor 'OrphanedClass'.
// new OrphanedClass();
// ^^^^^^^^^^^^^
//
import self as self;
import "dart:core" as core;
import "org-dartlang-testcase:///library_members.dart";
class ExistingClass#0#1 extends core::Object { // from org-dartlang-testcase:///library_members_lib.dart
synthetic constructor •() self::ExistingClass#0#1
: super core::Object::•()
;
}
class ExistingClass2#0#1 extends core::Object { // from org-dartlang-testcase:///library_members_lib.dart
synthetic constructor •() self::ExistingClass2#0#1
: super core::Object::•()
;
}
class InjectedClass extends core::Object { // from org-dartlang-testcase:///library_members_lib.dart
synthetic constructor •() self::InjectedClass
: super core::Object::•()
;
}
class _#OrphanedClass#augmentationWithoutOrigin0 extends core::Object { // from org-dartlang-testcase:///library_members_lib.dart
synthetic constructor •() self::_#OrphanedClass#augmentationWithoutOrigin0
: super core::Object::•()
;
}
class ExistingClass extends core::Object {
synthetic constructor •() self::ExistingClass
: super core::Object::•()
;
}
class AugmentedClass extends core::Object {
synthetic constructor •() self::AugmentedClass
: super core::Object::•()
;
}
class existingMethod2 extends core::Object {
synthetic constructor •() self::existingMethod2
: super core::Object::•()
;
}
static method existingMethod() void {
core::print("existingMethod-origin");
}
static method /* from org-dartlang-testcase:///library_members_lib.dart */ augmentedMethod() void {
core::print("augmentedMethod");
}
static set existingSetter(dynamic _) void {
core::print("existingSetter-origin");
}
static set /* from org-dartlang-testcase:///library_members_lib.dart */ augmentedSetter(dynamic _) void {
core::print("augmentedSetter");
}
static method ExistingClass2() void {}
static method test() dynamic {
invalid-expression "pkg/front_end/testcases/macros/library_members.dart:26:3: Error: Method not found: 'orphanedMethod'.
orphanedMethod();
^^^^^^^^^^^^^^";
invalid-expression "pkg/front_end/testcases/macros/library_members.dart:27:3: Error: Setter not found: 'orphanedSetter'.
orphanedSetter = 0;
^^^^^^^^^^^^^^";
invalid-expression "pkg/front_end/testcases/macros/library_members.dart:28:7: Error: Couldn't find constructor 'OrphanedClass'.
new OrphanedClass();
^^^^^^^^^^^^^";
}
static method main() dynamic {
self::augmentedMethod();
self::injectedMethod();
self::existingMethod();
self::ExistingClass2();
self::augmentedSetter = 0;
self::injectedSetter = 0;
self::existingSetter = 0;
new self::ExistingClass::•();
new self::AugmentedClass::•();
new self::InjectedClass::•();
new self::existingMethod2::•();
self::augmentMain();
}
static method /* from org-dartlang-testcase:///library_members_lib.dart */ existingMethod#1() → void {
core::print("existingMethod-duplicate");
}
static method /* from org-dartlang-testcase:///library_members_lib.dart */ existingMethod2#1() → void {
core::print("existingMethod2-duplicate");
}
static method /* from org-dartlang-testcase:///library_members_lib.dart */ injectedMethod() void {
core::print("injectedMethod");
}
static method /* from org-dartlang-testcase:///library_members_lib.dart */ orphanedMethod() void {
core::print("orphanedMethod");
}
static set /* from org-dartlang-testcase:///library_members_lib.dart */ existingSetter#1(dynamic _) → void {
core::print("existingSetter-duplicate");
}
static set /* from org-dartlang-testcase:///library_members_lib.dart */ injectedSetter(dynamic _) void {
core::print("injectedSetter");
}
static set /* from org-dartlang-testcase:///library_members_lib.dart */ orphanedSetter(dynamic _) void {
core::print("orphanedSetter");
}
static method /* from org-dartlang-testcase:///library_members_lib.dart */ augmentTest() void {
self::orphanedMethod();
self::orphanedMethod();
self::orphanedSetter = 0;
new self::_#OrphanedClass#augmentationWithoutOrigin0::•();
}
static method /* from org-dartlang-testcase:///library_members_lib.dart */ augmentMain() void {
self::augmentedMethod();
self::injectedMethod();
self::existingMethod#1();
self::augmentedSetter = 0;
self::injectedSetter = 0;
self::existingSetter#1 = 0;
new self::ExistingClass#0#1::•();
new self::AugmentedClass::•();
new self::InjectedClass::•();
}