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

Side by Side Diff: Source/bindings/core/v8/V8Binding.cpp

Issue 638813002: Replace FINAL and OVERRIDE with their C++11 counterparts in Source/bindings (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 2 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 2009 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 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 { 87 {
88 return V8ThrowException::createTypeError(ExceptionMessages::failedToConstruc t(type, ExceptionMessages::notEnoughArguments(expected, provided)), isolate); 88 return V8ThrowException::createTypeError(ExceptionMessages::failedToConstruc t(type, ExceptionMessages::notEnoughArguments(expected, provided)), isolate);
89 } 89 }
90 90
91 void setMinimumArityTypeError(ExceptionState& exceptionState, unsigned expected, unsigned provided) 91 void setMinimumArityTypeError(ExceptionState& exceptionState, unsigned expected, unsigned provided)
92 { 92 {
93 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(expected , provided)); 93 exceptionState.throwTypeError(ExceptionMessages::notEnoughArguments(expected , provided));
94 } 94 }
95 95
96 class ArrayBufferAllocator : public v8::ArrayBuffer::Allocator { 96 class ArrayBufferAllocator : public v8::ArrayBuffer::Allocator {
97 virtual void* Allocate(size_t size) OVERRIDE 97 virtual void* Allocate(size_t size) override
98 { 98 {
99 void* data; 99 void* data;
100 WTF::ArrayBufferContents::allocateMemory(size, WTF::ArrayBufferContents: :ZeroInitialize, data); 100 WTF::ArrayBufferContents::allocateMemory(size, WTF::ArrayBufferContents: :ZeroInitialize, data);
101 return data; 101 return data;
102 } 102 }
103 103
104 virtual void* AllocateUninitialized(size_t size) OVERRIDE 104 virtual void* AllocateUninitialized(size_t size) override
105 { 105 {
106 void* data; 106 void* data;
107 WTF::ArrayBufferContents::allocateMemory(size, WTF::ArrayBufferContents: :DontInitialize, data); 107 WTF::ArrayBufferContents::allocateMemory(size, WTF::ArrayBufferContents: :DontInitialize, data);
108 return data; 108 return data;
109 } 109 }
110 110
111 virtual void Free(void* data, size_t size) OVERRIDE 111 virtual void Free(void* data, size_t size) override
112 { 112 {
113 WTF::ArrayBufferContents::freeMemory(data, size); 113 WTF::ArrayBufferContents::freeMemory(data, size);
114 } 114 }
115 }; 115 };
116 116
117 v8::ArrayBuffer::Allocator* v8ArrayBufferAllocator() 117 v8::ArrayBuffer::Allocator* v8ArrayBufferAllocator()
118 { 118 {
119 DEFINE_STATIC_LOCAL(ArrayBufferAllocator, arrayBufferAllocator, ()); 119 DEFINE_STATIC_LOCAL(ArrayBufferAllocator, arrayBufferAllocator, ());
120 return &arrayBufferAllocator; 120 return &arrayBufferAllocator;
121 } 121 }
(...skipping 872 matching lines...) Expand 10 before | Expand all | Expand 10 after
994 994
995 v8::Local<v8::Value> v8IteratorResult(v8::Isolate* isolate, v8::Handle<v8::Value > value) 995 v8::Local<v8::Value> v8IteratorResult(v8::Isolate* isolate, v8::Handle<v8::Value > value)
996 { 996 {
997 v8::Local<v8::Object> result = v8::Object::New(isolate); 997 v8::Local<v8::Object> result = v8::Object::New(isolate);
998 result->Set(v8String(isolate, "value"), value); 998 result->Set(v8String(isolate, "value"), value);
999 result->Set(v8String(isolate, "done"), v8Boolean(false, isolate)); 999 result->Set(v8String(isolate, "done"), v8Boolean(false, isolate));
1000 return result; 1000 return result;
1001 } 1001 }
1002 1002
1003 } // namespace blink 1003 } // namespace blink
OLDNEW
« no previous file with comments | « Source/bindings/core/v8/V8Binding.h ('k') | Source/bindings/core/v8/V8CustomElementLifecycleCallbacks.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698