RESOLVED FIXED 182873
[MSVC] Unknown a type definition error in WebResourceLoadStatisticsStore on wincairo webkit
https://bugs.webkit.org/show_bug.cgi?id=182873
Summary [MSVC] Unknown a type definition error in WebResourceLoadStatisticsStore on w...
Yousuke Kimoto
Reported 2018-02-16 06:55:36 PST
In WebResourceLoadStatisticsStore.h, MSVC doesn't seem to treat a type name which is specified by "using WTF::Vector". Its Intellisense understands the "using" definition, but the compiler doesn't. Currently there are two methods: 1) Add a new declaration to avoid this issue for MSVC. 2) Use WTF::Vector in a lambda definition
Attachments
Test Patch (Work In Progress) (2.88 KB, patch)
2018-02-16 06:57 PST, Yousuke Kimoto
no flags
bz182873-1.patch (3.28 KB, patch)
2018-02-17 05:42 PST, Yousuke Kimoto
no flags
Yousuke Kimoto
Comment 1 2018-02-16 06:57:01 PST
Created attachment 334039 [details] Test Patch (Work In Progress)
Yousuke Kimoto
Comment 2 2018-02-17 05:42:05 PST
Created attachment 334106 [details] bz182873-1.patch
Don Olmstead
Comment 3 2018-02-20 12:02:24 PST
The webkitpy bot seems to have not applied this patch.
Alexey Proskuryakov
Comment 4 2018-02-20 12:58:37 PST
> The webkitpy bot seems to have not applied this patch. Timed out talking to Bugzilla.
Don Olmstead
Comment 5 2018-02-21 11:29:40 PST
Its kinda unclear on why this is needed here as its including <wtf/Vector.h> and other definitions in the file refer to Vector directly. There are a few places in that file that are using WTF::Function as well so its a bit unclear on what is going on.
Yusuke Suzuki
Comment 6 2018-02-22 19:01:43 PST
Comment on attachment 334106 [details] bz182873-1.patch r=me for this workaround. Maybe this `using` does not work if we use it for lambda parameter, which lambda is defined for default parameter. I believe it is MSVC's bug.
Yusuke Suzuki
Comment 7 2018-02-22 19:03:07 PST
JF, do you have any insight for this? (Is it known issue in MSVC? Or is it something wrong in our side?)
JF Bastien
Comment 8 2018-02-22 21:25:29 PST
(In reply to Yusuke Suzuki from comment #7) > JF, do you have any insight for this? > (Is it known issue in MSVC? Or is it something wrong in our side?) Not known to me. Can you craft a small repro? This seems to work: https://godbolt.org/g/Tm9Yec
Yousuke Kimoto
Comment 9 2018-02-23 07:07:47 PST
(In reply to JF Bastien from comment #8) > (In reply to Yusuke Suzuki from comment #7) > > JF, do you have any insight for this? > > (Is it known issue in MSVC? Or is it something wrong in our side?) > > Not known to me. Can you craft a small repro? This seems to work: > https://godbolt.org/g/Tm9Yec Yusuke Suzuki, JF Bastien, I made a simple sample. Does this example show what happen in MSVC? https://godbolt.org/g/TtDbAL
JF Bastien
Comment 10 2018-02-23 08:41:48 PST
(In reply to Yousuke Kimoto from comment #9) > (In reply to JF Bastien from comment #8) > > (In reply to Yusuke Suzuki from comment #7) > > > JF, do you have any insight for this? > > > (Is it known issue in MSVC? Or is it something wrong in our side?) > > > > Not known to me. Can you craft a small repro? This seems to work: > > https://godbolt.org/g/Tm9Yec > > Yusuke Suzuki, JF Bastien, > > I made a simple sample. Does this example show what happen in MSVC? > https://godbolt.org/g/TtDbAL Ping'd a friend on the MSVC team. Confirmed to be an MSVC bug: https://twitter.com/apardoe/status/967076489085599744
Yusuke Suzuki
Comment 11 2018-02-23 09:18:07 PST
(In reply to JF Bastien from comment #10) > (In reply to Yousuke Kimoto from comment #9) > > (In reply to JF Bastien from comment #8) > > > (In reply to Yusuke Suzuki from comment #7) > > > > JF, do you have any insight for this? > > > > (Is it known issue in MSVC? Or is it something wrong in our side?) > > > > > > Not known to me. Can you craft a small repro? This seems to work: > > > https://godbolt.org/g/Tm9Yec > > > > Yusuke Suzuki, JF Bastien, > > > > I made a simple sample. Does this example show what happen in MSVC? > > https://godbolt.org/g/TtDbAL > > Ping'd a friend on the MSVC team. Confirmed to be an MSVC bug: > https://twitter.com/apardoe/status/967076489085599744 Cool!
WebKit Commit Bot
Comment 12 2018-02-23 10:32:46 PST
Comment on attachment 334106 [details] bz182873-1.patch Clearing flags on attachment: 334106 Committed r228951: <https://trac.webkit.org/changeset/228951>
WebKit Commit Bot
Comment 13 2018-02-23 10:32:48 PST
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 14 2018-02-23 10:33:23 PST
Note You need to log in before you can comment on or make changes to this bug.