Rewritten hash -> Hash collides with a Hash struct |
||||
Issue descriptionRewritten hash -> Hash collides with a Hash struct
,
Dec 27 2016
The latest proposal is to blacklist renaming of "hash" regardless of whether it is a static or instance method + also blacklist renaming if it is a standalone function - https://codereview.chromium.org/2608443002 An alternative would be to rename either the |Hash| function (but |GetHash| is not an obvious name here) or the |DetailtHash<T>::Hash| typename (also no obvious name here + manually finding and renaming all the templates is a bit tricky). I think just skipping the rename is easier.
,
Dec 28 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/1b4b746ad2d2c288bdc568a046b2461b637a75fd commit 1b4b746ad2d2c288bdc568a046b2461b637a75fd Author: lukasza <lukasza@chromium.org> Date: Wed Dec 28 19:16:50 2016 Blacklisting renaming of "hash" in case of static methods and functions. BUG= 677166 Review-Url: https://codereview.chromium.org/2608443002 Cr-Commit-Position: refs/heads/master@{#440878} [modify] https://crrev.com/1b4b746ad2d2c288bdc568a046b2461b637a75fd/tools/clang/rewrite_to_chrome_style/RewriteToChromeStyle.cpp [modify] https://crrev.com/1b4b746ad2d2c288bdc568a046b2461b637a75fd/tools/clang/rewrite_to_chrome_style/tests/methods-expected.cc [modify] https://crrev.com/1b4b746ad2d2c288bdc568a046b2461b637a75fd/tools/clang/rewrite_to_chrome_style/tests/methods-original.cc
,
Dec 28 2016
nasko@, please reactivate if this comes back.
,
Dec 29 2016
Aaand it is back... If we blacklist renaming of "hash" method, then we have a problem in code generator for DOM bindings - we want the generator to consistently capitalize all method names, but this means that it will expect "Hash" as an implementation of "hash" attribute frmo Location.idl. I am not sure what options we have at this point: 1. Preland renaming of "hash" method to something else. "getHash"? (this is probably slightly blocked on issue 673039 ) 2. Special case / blacklist "hash" also in the code generator? Any option I am missing? What do people think about "getHash" name in general?
,
Jan 3 2017
getHash seems fine to me. I think this can be lumped in with all the other idl issues and we can use whatever general scheme here as well, unless there is something else special about "hash" that I am not seeing?
,
Jan 4 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/0020d5c9503dd59d2caf28999aa38bc600206303 commit 0020d5c9503dd59d2caf28999aa38bc600206303 Author: nasko <nasko@chromium.org> Date: Wed Jan 04 19:17:51 2017 Update methods requiring Get prefix to avoid collisions with Blink rewrite. This CL adds a few more methods that cause name collisions when Blink is rewritten to match Chromium style. In addition, it removes the hash method from the blacklist. BUG= 582312 , 677166 Review-Url: https://codereview.chromium.org/2608423003 Cr-Commit-Position: refs/heads/master@{#441429} [modify] https://crrev.com/0020d5c9503dd59d2caf28999aa38bc600206303/tools/clang/rewrite_to_chrome_style/RewriteToChromeStyle.cpp [modify] https://crrev.com/0020d5c9503dd59d2caf28999aa38bc600206303/tools/clang/rewrite_to_chrome_style/tests/methods-expected.cc [modify] https://crrev.com/0020d5c9503dd59d2caf28999aa38bc600206303/tools/clang/rewrite_to_chrome_style/tests/methods-original.cc
,
Jan 5 2017
|
||||
►
Sign in to add a comment |
||||
Comment 1 by lukasza@chromium.org
, Dec 27 2016