Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(196)

Unified Diff: third_party/WebKit/Source/bindings/IDLExtendedAttributes.md

Issue 2008823002: bindings: Supports [SaveSameObject] extended attribute. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed the documentation. Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/bindings/IDLExtendedAttributes.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/bindings/IDLExtendedAttributes.md
diff --git a/third_party/WebKit/Source/bindings/IDLExtendedAttributes.md b/third_party/WebKit/Source/bindings/IDLExtendedAttributes.md
index 5ddc2d92df221d85a97d147938923355b4c8f85d..eae6d4fec93a0dc8766e95fcd6fb1e47bcd9832b 100644
--- a/third_party/WebKit/Source/bindings/IDLExtendedAttributes.md
+++ b/third_party/WebKit/Source/bindings/IDLExtendedAttributes.md
@@ -412,13 +412,13 @@ window.screenX; // Evaluates to 0. 0 remains.
Whether `[Replaceable]` should be specified or not depends on the spec of each attribute.
-### [SameObject] _(m)_
+### [SameObject] _(a)_
Standard: [SameObject](http://heycam.github.io/webidl/#SameObject)
Summary: Signals that a `readonly` attribute that returns an object type always returns the same object.
-The resulting object is cached in the binding layer and re-used in later calls in order to guarantee that the attribute always returns the same object.
+This attribute has no effect on code generation and should simply be used in Blink IDL files if the specification uses it. If you want the binding layer to cache the resulting object, use `[SaveSameObject]`.
### [TreatNullAs] _(a,p)_, [TreatUndefinedAs] _(a,p)_
@@ -1247,6 +1247,12 @@ foo(long x);
For more information, see [RuntimeEnabledFeatures](https://code.google.com/p/chromium/codesearch#chromium/src/third_party/WebKit/Source/platform/RuntimeEnabledFeatures.in).
+### [SaveSameObject] _(a)_
+
+Summary: Caches the resulting object and always returns the same object.
+
+When specified, caches the resulting object and returns it in later calls so that the attribute always returns the same object. Must be accompanied with `[SameObject]`.
+
### [SetWrapperReferenceFrom=xxx] _(i)_
### [SetWrapperReferenceTo=xxx] _(i)_
« no previous file with comments | « no previous file | third_party/WebKit/Source/bindings/IDLExtendedAttributes.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698