Advertisement
Guest User

Untitled

a guest
Apr 25th, 2019
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.47 KB | None | 0 0
  1. struct Foo {
  2. Foo(int, const OUString &) {}
  3. Foo(OUString const &, int) {}
  4. };
  5.  
  6. int main() {
  7. Foo aFoo(OUString("xxx1"), 1); // expected-error {{in call of 'Foo::Foo', replace 'OUString' constructed from a string literal directly with the string literal}}
  8. (void)aFoo;
  9. Foo aFoo3(1, OUString("xxx2")); // expected-error {{in call of 'Foo::Foo', replace 'OUString' constructed from a string literal directly with the string literal}}
  10. (void)aFoo3;
  11. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement