Chromium Code Reviews| Index: tools/clang/rewrite_to_chrome_style/tests/fields-original.cc |
| diff --git a/tools/clang/rewrite_to_chrome_style/tests/fields-original.cc b/tools/clang/rewrite_to_chrome_style/tests/fields-original.cc |
| index 2710d237efcc4d2afd7dc1710e3a49cb22d64084..784fc81b32ae710a6e84fb51a55cc10ab62e65be 100644 |
| --- a/tools/clang/rewrite_to_chrome_style/tests/fields-original.cc |
| +++ b/tools/clang/rewrite_to_chrome_style/tests/fields-original.cc |
| @@ -4,6 +4,9 @@ |
| namespace blink { |
| +// Note: do not add any copy or move constructors to this class: doing so will |
|
danakj
2016/01/29 00:16:56
Probably need this in the expected too.
dcheng
2016/01/29 01:17:30
Oops done.
|
| +// break test coverage that we don't clobber the class name by trying to emit |
| +// replacements for synthesized functions. |
| class C { |
| public: |
| // Make sure initializers are updated to use the new names. |
| @@ -50,4 +53,8 @@ union U { |
| void F() { |
| // Test that references to a static field are correctly rewritten. |
| blink::C::instanceCount++; |
| + // Force instantiation of a copy constructor for blink::C to make sure field |
| + // initializers for synthesized functions don't cause weird rewrites. |
| + blink::C c; |
| + blink::C c2 = c; |
| } |