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

Side by Side Diff: Source/bindings/tests/results/V8TestCustomAccessors.cpp

Issue 34273002: Remove UnusedParam.h (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Remove unnecessary ALLOW_UNUSED from the binding generator Created 7 years 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 24 matching lines...) Expand all
35 35
36 #include "RuntimeEnabledFeatures.h" 36 #include "RuntimeEnabledFeatures.h"
37 #include "bindings/v8/ExceptionMessages.h" 37 #include "bindings/v8/ExceptionMessages.h"
38 #include "bindings/v8/ExceptionState.h" 38 #include "bindings/v8/ExceptionState.h"
39 #include "bindings/v8/V8Binding.h" 39 #include "bindings/v8/V8Binding.h"
40 #include "bindings/v8/V8DOMConfiguration.h" 40 #include "bindings/v8/V8DOMConfiguration.h"
41 #include "bindings/v8/V8DOMWrapper.h" 41 #include "bindings/v8/V8DOMWrapper.h"
42 #include "core/dom/ContextFeatures.h" 42 #include "core/dom/ContextFeatures.h"
43 #include "core/dom/Document.h" 43 #include "core/dom/Document.h"
44 #include "platform/TraceEvent.h" 44 #include "platform/TraceEvent.h"
45 #include "wtf/UnusedParam.h"
46 45
47 namespace WebCore { 46 namespace WebCore {
48 47
49 static void initializeScriptWrappableForInterface(TestCustomAccessors* object) 48 static void initializeScriptWrappableForInterface(TestCustomAccessors* object)
50 { 49 {
51 if (ScriptWrappable::wrapperCanBeStoredInObject(object)) 50 if (ScriptWrappable::wrapperCanBeStoredInObject(object))
52 ScriptWrappable::setTypeInfoInObject(object, &V8TestCustomAccessors::wra pperTypeInfo); 51 ScriptWrappable::setTypeInfoInObject(object, &V8TestCustomAccessors::wra pperTypeInfo);
53 else 52 else
54 ASSERT_NOT_REACHED(); 53 ASSERT_NOT_REACHED();
55 } 54 }
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
155 static v8::Handle<v8::FunctionTemplate> ConfigureV8TestCustomAccessorsTemplate(v 8::Handle<v8::FunctionTemplate> functionTemplate, v8::Isolate* isolate, WrapperW orldType currentWorldType) 154 static v8::Handle<v8::FunctionTemplate> ConfigureV8TestCustomAccessorsTemplate(v 8::Handle<v8::FunctionTemplate> functionTemplate, v8::Isolate* isolate, WrapperW orldType currentWorldType)
156 { 155 {
157 functionTemplate->ReadOnlyPrototype(); 156 functionTemplate->ReadOnlyPrototype();
158 157
159 v8::Local<v8::Signature> defaultSignature; 158 v8::Local<v8::Signature> defaultSignature;
160 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(functionTempl ate, "TestCustomAccessors", v8::Local<v8::FunctionTemplate>(), V8TestCustomAcces sors::internalFieldCount, 159 defaultSignature = V8DOMConfiguration::installDOMClassTemplate(functionTempl ate, "TestCustomAccessors", v8::Local<v8::FunctionTemplate>(), V8TestCustomAcces sors::internalFieldCount,
161 0, 0, 160 0, 0,
162 0, 0, 161 0, 0,
163 V8TestCustomAccessorsMethods, WTF_ARRAY_LENGTH(V8TestCustomAccessorsMeth ods), 162 V8TestCustomAccessorsMethods, WTF_ARRAY_LENGTH(V8TestCustomAccessorsMeth ods),
164 isolate, currentWorldType); 163 isolate, currentWorldType);
165 UNUSED_PARAM(defaultSignature); 164 v8::Local<v8::ObjectTemplate> ALLOW_UNUSED instanceTemplate = functionTempla te->InstanceTemplate();
166 v8::Local<v8::ObjectTemplate> instanceTemplate = functionTemplate->InstanceT emplate(); 165 v8::Local<v8::ObjectTemplate> ALLOW_UNUSED prototypeTemplate = functionTempl ate->PrototypeTemplate();
167 v8::Local<v8::ObjectTemplate> prototypeTemplate = functionTemplate->Prototyp eTemplate();
168 UNUSED_PARAM(instanceTemplate);
169 UNUSED_PARAM(prototypeTemplate);
170 functionTemplate->InstanceTemplate()->SetIndexedPropertyHandler(TestCustomAc cessorsV8Internal::indexedPropertyGetterCallback, TestCustomAccessorsV8Internal: :indexedPropertySetterCallback, 0, TestCustomAccessorsV8Internal::indexedPropert yDeleterCallback, 0); 166 functionTemplate->InstanceTemplate()->SetIndexedPropertyHandler(TestCustomAc cessorsV8Internal::indexedPropertyGetterCallback, TestCustomAccessorsV8Internal: :indexedPropertySetterCallback, 0, TestCustomAccessorsV8Internal::indexedPropert yDeleterCallback, 0);
171 functionTemplate->InstanceTemplate()->SetNamedPropertyHandler(TestCustomAcce ssorsV8Internal::namedPropertyGetterCallback, TestCustomAccessorsV8Internal::nam edPropertySetterCallback, TestCustomAccessorsV8Internal::namedPropertyQueryCallb ack, TestCustomAccessorsV8Internal::namedPropertyDeleterCallback, TestCustomAcce ssorsV8Internal::namedPropertyEnumeratorCallback); 167 functionTemplate->InstanceTemplate()->SetNamedPropertyHandler(TestCustomAcce ssorsV8Internal::namedPropertyGetterCallback, TestCustomAccessorsV8Internal::nam edPropertySetterCallback, TestCustomAccessorsV8Internal::namedPropertyQueryCallb ack, TestCustomAccessorsV8Internal::namedPropertyDeleterCallback, TestCustomAcce ssorsV8Internal::namedPropertyEnumeratorCallback);
172 168
173 // Custom toString template 169 // Custom toString template
174 functionTemplate->Set(v8::String::NewFromUtf8(isolate, "toString", v8::Strin g::kInternalizedString), V8PerIsolateData::current()->toStringTemplate()); 170 functionTemplate->Set(v8::String::NewFromUtf8(isolate, "toString", v8::Strin g::kInternalizedString), V8PerIsolateData::current()->toStringTemplate());
175 return functionTemplate; 171 return functionTemplate;
176 } 172 }
177 173
178 v8::Handle<v8::FunctionTemplate> V8TestCustomAccessors::GetTemplate(v8::Isolate* isolate, WrapperWorldType currentWorldType) 174 v8::Handle<v8::FunctionTemplate> V8TestCustomAccessors::GetTemplate(v8::Isolate* isolate, WrapperWorldType currentWorldType)
179 { 175 {
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 fromInternalPointer(object)->deref(); 223 fromInternalPointer(object)->deref();
228 } 224 }
229 225
230 template<> 226 template<>
231 v8::Handle<v8::Value> toV8NoInline(TestCustomAccessors* impl, v8::Handle<v8::Obj ect> creationContext, v8::Isolate* isolate) 227 v8::Handle<v8::Value> toV8NoInline(TestCustomAccessors* impl, v8::Handle<v8::Obj ect> creationContext, v8::Isolate* isolate)
232 { 228 {
233 return toV8(impl, creationContext, isolate); 229 return toV8(impl, creationContext, isolate);
234 } 230 }
235 231
236 } // namespace WebCore 232 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698