Index: Source/devtools/scripts/jsdoc-validator/tests/this.js |
diff --git a/Source/devtools/scripts/jsdoc-validator/tests/this.js b/Source/devtools/scripts/jsdoc-validator/tests/this.js |
index 165c165fcdc881c6372bfced0432730d77fb0e83..b769a2858c3a8f6eb438ef75fc07f9b5ab85afec 100644 |
--- a/Source/devtools/scripts/jsdoc-validator/tests/this.js |
+++ b/Source/devtools/scripts/jsdoc-validator/tests/this.js |
@@ -264,6 +264,20 @@ ReceiverTest.prototype = { |
this.foo = 1; |
} |
object.callFunction(func, [], ignoredCallbackWithThis); // OK - ignored. |
+ |
+ function callbackReferencingThisNotAnnotated() |
+ { |
+ this.foo = 2; |
+ } |
+ this.memberTwo(callbackReferencingThisNotAnnotated.bind(this)); // OK - No @this annotation, but references |this|. |
+ |
+ /** |
+ * @this {Object} |
+ */ |
+ function callbackNotReferencingThisAnnotated() |
+ { |
+ } |
+ this.memberTwo(callbackNotReferencingThisAnnotated); // OK - Has @this annotation, but does not reference |this|. |
}, |
memberTwo: function(arg) {} |