( node: ThisExpression | NewExpression, module: SourceModule, kindOfKey: KindOfKey )
| 3951 | |
| 3952 | // `this`, or what `new` creates: the object or class that owns it |
| 3953 | private thisKindOf( |
| 3954 | node: ThisExpression | NewExpression, |
| 3955 | module: SourceModule, |
| 3956 | kindOfKey: KindOfKey |
| 3957 | ): KindBits { |
| 3958 | const owner = node.type === "ThisExpression" && ownerOf(node) |
| 3959 | if (owner && owner.type === "ObjectExpression") |
| 3960 | return this.transfer(owner, module, kindOfKey) |
| 3961 | // e.g. `static self = this`, which holds nothing until it holds something else |
| 3962 | const statics = node.type === "ThisExpression" && staticOwnerOf(node) |
| 3963 | if (statics) |
| 3964 | return this.holderKindOf(node, { node: statics, module, kindOfKey }) |
| 3965 | const cls = this.classOf(node, module, kindOfKey) |
| 3966 | return ( |
| 3967 | cls ? this.instanceKindOf(cls, kindOfKey) |
| 3968 | : node.type === "NewExpression" ? |
| 3969 | this.builtinPassedOf(node, module, kindOfKey) |
| 3970 | : kinds.data |
| 3971 | ) |
| 3972 | } |
| 3973 | |
| 3974 | // what `node` reads off `object`, where its name decides the read as the |
| 3975 | // member's own kind: e.g. a method's declared return, off whichever of |
no test coverage detected