131bc1d2da58677b95346d1c34ba289e6a178bec3David Majnemer// RUN: %clang_cc1 -triple i686-pc-openbsd -fsyntax-only -verify -ffreestanding %s 207a5c22bb6fb0674c95205ae189365bf8e1b695eJohn McCall 307a5c22bb6fb0674c95205ae189365bf8e1b695eJohn McCall// Tests that -ffreestanding disables all special treatment of main(). 407a5c22bb6fb0674c95205ae189365bf8e1b695eJohn McCall 507a5c22bb6fb0674c95205ae189365bf8e1b695eJohn McCallvoid* allocate(long size); 607a5c22bb6fb0674c95205ae189365bf8e1b695eJohn McCall 707a5c22bb6fb0674c95205ae189365bf8e1b695eJohn McCallvoid* main(void* context, long size) { 807a5c22bb6fb0674c95205ae189365bf8e1b695eJohn McCall if (context) return allocate(size); 907a5c22bb6fb0674c95205ae189365bf8e1b695eJohn McCall} // expected-warning {{control may reach end of non-void function}} 10