Daniel Dunbar | 8fbe78f | 2009-12-15 20:14:24 +0000 | [diff] [blame] | 1 | // RUN: %clang_cc1 -emit-llvm-only -verify %s |
Andy Gibbs | c6e68da | 2012-10-19 12:44:48 +0000 | [diff] [blame] | 2 | // expected-no-diagnostics |
Eli Friedman | 274ab90 | 2009-11-14 08:51:33 +0000 | [diff] [blame] | 3 | |
4 | // Make sure we don't crash generating y; its value is constant, but the | ||||
5 | // initializer has side effects, so EmitConstantExpr should fail. | ||||
6 | int x(); | ||||
Chandler Carruth | e54ff6c | 2011-05-31 05:41:42 +0000 | [diff] [blame] | 7 | int y = x() & 0; |