-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[stable] [vm/aot] Disable graph intrinsics for implicit getters with …
…unboxed record return values Unboxing of records involves a more complex code, and such intrinsics would be similar to the normal code of the implicit getters. TEST=runtime/tests/vm/dart/regress_52449_test.dart Bug: #52449 Change-Id: Ic6b4ca21609921f0215275be6578f6bbc1fe3eeb Cherry-pick: https://dart-review.googlesource.com/c/sdk/+/304282 Fixes: #52467 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/304760 Commit-Queue: Alexander Markov <alexmarkov@google.com> Reviewed-by: Siva Annamalai <asiva@google.com>
- Loading branch information
1 parent
063c854
commit 4e7afbb
Showing
3 changed files
with
35 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
// Copyright (c) 2023, the Dart project authors. Please see the AUTHORS file | ||
// for details. All rights reserved. Use of this source code is governed by a | ||
// BSD-style license that can be found in the LICENSE file. | ||
|
||
// Verifies that compiler doesn't crash when compiling | ||
// implicit getter with unboxed return value. | ||
// Regression test for https://github.com/dart-lang/sdk/issues/52449. | ||
|
||
abstract class A { | ||
(int, int) get foo; | ||
} | ||
|
||
class B implements A { | ||
(int, int) get foo => (1, 2); | ||
} | ||
|
||
class C implements A { | ||
final (int, int) foo; | ||
C(this.foo); | ||
} | ||
|
||
void main() { | ||
final list = [B(), C((3, 4))]; | ||
for (var e in list) { | ||
print(e.foo); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters