mirror of
https://github.com/apple/pkl.git
synced 2026-05-28 01:29:15 +02:00
Ensure owner and receiver are reset after executing alias (#373)
This fixes an issue where the frame's owner/receiver are not reset if a type test on a typealias fails.
This commit is contained in:
@@ -35,3 +35,10 @@ typealias Bar = Foo
|
||||
class Baz extends Bar {}
|
||||
|
||||
res7 = (new Baz {}).value
|
||||
|
||||
typealias MappingOrListing = Mapping|Listing
|
||||
|
||||
res8 = new {
|
||||
foo = 5
|
||||
bar = if (foo is MappingOrListing) "bar" else foo
|
||||
}
|
||||
|
||||
@@ -11,3 +11,7 @@ res6 {
|
||||
name = "Other"
|
||||
}
|
||||
res7 = 42
|
||||
res8 {
|
||||
foo = 5
|
||||
bar = 5
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user