Chromium Code Reviews| Index: components/dom_distiller/ios/distiller_page_ios.mm |
| diff --git a/components/dom_distiller/ios/distiller_page_ios.mm b/components/dom_distiller/ios/distiller_page_ios.mm |
| index 1b19a6fde56ef03b386c00a630ba826fabe2e687..e13dbd26e2b96cecf7b977788c50d4a8f9047256 100644 |
| --- a/components/dom_distiller/ios/distiller_page_ios.mm |
| +++ b/components/dom_distiller/ios/distiller_page_ios.mm |
| @@ -23,6 +23,10 @@ |
| #import "ios/web/public/web_state/web_state.h" |
| #include "ios/web/public/web_state/web_state_observer.h" |
| +#if !defined(__has_feature) || !__has_feature(objc_arc) |
| +#error "This file requires ARC support." |
| +#endif |
| + |
| namespace { |
| // This is duplicated here from ios/web/web_state/ui/web_view_js_utils.mm in |
| @@ -48,7 +52,7 @@ std::unique_ptr<base::Value> ValueResultFromScriptResult(id wk_result, |
| return result; |
| } |
| - CFTypeID result_type = CFGetTypeID(wk_result); |
| + CFTypeID result_type = CFGetTypeID(reinterpret_cast<const void*>(wk_result)); |
|
noyau (Ping after 24h)
2017/06/13 08:40:44
reinterpret_cast<CFTypeRef> maybe?
marq (ping after 24h)
2017/06/13 13:10:47
Good call, done.
|
| if (result_type == CFStringGetTypeID()) { |
| result.reset(new base::Value(base::SysNSStringToUTF16(wk_result))); |
| DCHECK(result->IsType(base::Value::Type::STRING)); |