1 // RUN: %clang_cc1 -triple x86_64-apple-darwin10 -fsyntax-only -verify %s
2 // RUN: %clang_cc1 -x objective-c++ -triple x86_64-apple-darwin10 -fsyntax-only -verify %s
16 - (const struct Bar)bar {
22 [self bar].x = 10; // expected-error {{assigning to 'readonly' return result of an objective-c message not allowed}}