Changeset 243204 in webkit
- Timestamp:
- Mar 20, 2019 9:13:30 AM (5 years ago)
- Location:
- trunk/Source
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r243200 r243204 1 2019-03-20 Michael Catanzaro <mcatanzaro@igalia.com> 2 3 Remove copyRef() calls added in r243163 4 https://bugs.webkit.org/show_bug.cgi?id=195962 5 6 Reviewed by Chris Dumez. 7 8 As best I can tell, may be a GCC 9 bug. It shouldn't warn about this case because the return 9 value is noncopyable and the WTFMove() is absolutely required. We can avoid the warning 10 without refcount churn by introducing an intermediate variable. 11 12 * inspector/scripts/codegen/cpp_generator_templates.py: 13 1 14 2019-03-20 Carlos Garcia Campos <cgarcia@igalia.com> 2 15 -
trunk/Source/JavaScriptCore/inspector/scripts/codegen/cpp_generator_templates.py
r243163 r243204 231 231 COMPILE_ASSERT(sizeof(${objectType}) == sizeof(JSON::Object), cannot_cast); 232 232 233 Ref<JSON::Object> result = m_result.releaseNonNull(); 234 return reinterpret_cast<Ref<${objectType}>*>(&result)->copyRef(); 233 Ref<JSON::Object> jsonResult = m_result.releaseNonNull(); 234 auto result = WTFMove(*reinterpret_cast<Ref<${objectType}>*>(&jsonResult)); 235 return result; 235 236 } 236 237 }; -
trunk/Source/WebCore/ChangeLog
r243199 r243204 1 2019-03-20 Michael Catanzaro <mcatanzaro@igalia.com> 2 3 Remove copyRef() calls added in r243163 4 https://bugs.webkit.org/show_bug.cgi?id=195962 5 6 Reviewed by Chris Dumez. 7 8 The first two cases here can just directly return the RefPtr. 9 10 In the third case, we have to work around a GCC 6 bug because GCC 6 is unable to pick the 11 right constructor to use, unlike modern compilers. 12 13 * Modules/fetch/FetchBody.cpp: 14 (WebCore::FetchBody::bodyAsFormData const): 15 (WebCore::FetchBody::take): 16 1 17 2019-03-20 Alicia Boya García <aboya@igalia.com> 2 18 -
trunk/Source/WebCore/Modules/fetch/FetchBody.cpp
r243163 r243204 244 244 auto body = FormData::create(); 245 245 body->appendBlob(blobBody().url()); 246 return body .copyRef();246 return body; 247 247 } 248 248 if (isArrayBuffer()) … … 254 254 auto body = makeRef(const_cast<FormData&>(formDataBody())); 255 255 body->generateFiles(&downcast<Document>(context)); 256 return body .copyRef();256 return body; 257 257 } 258 258 if (auto* data = m_consumer.data()) … … 275 275 auto body = FormData::create(); 276 276 body->appendBlob(blobBody().url()); 277 return body.copyRef();277 return TakenData { WTFMove(body) }; 278 278 } 279 279
Note: See TracChangeset
for help on using the changeset viewer.