Daniel Dunbar | d7d5f02 | 2009-03-24 02:24:46 +0000 | [diff] [blame] | 1 | // RUN: clang-cc %s -verify |
Chris Lattner | 810f6d5 | 2009-03-13 17:38:01 +0000 | [diff] [blame] | 2 | |
3 | int foo() { | ||||
4 | int a; | ||||
5 | // PR3788 | ||||
6 | asm("nop" : : "m"((int)(a))); // expected-error {{cast in a inline asm context requiring an l-value}} | ||||
7 | // PR3794 | ||||
8 | asm("nop" : "=r"((unsigned)a)); // expected-error {{cast in a inline asm context requiring an l-value}} | ||||
9 | } | ||||
10 |