1a11d129aa8ad9fa123e72d0663c327d5578d2602Eric Christopher// RUN: %clang_cc1 -O1 -emit-llvm %s -o - | grep icmp 2a11d129aa8ad9fa123e72d0663c327d5578d2602Eric Christopher// PR1678 3a11d129aa8ad9fa123e72d0663c327d5578d2602Eric Christopher 4a11d129aa8ad9fa123e72d0663c327d5578d2602Eric Christopherextern void B (void); 5a11d129aa8ad9fa123e72d0663c327d5578d2602Eric Christopherstatic __typeof(B) A __attribute__ ((__weakref__("B"))); 6a11d129aa8ad9fa123e72d0663c327d5578d2602Eric Christopherint active (void) 7a11d129aa8ad9fa123e72d0663c327d5578d2602Eric Christopher{ 8a11d129aa8ad9fa123e72d0663c327d5578d2602Eric Christopher static void *const p = __extension__ (void *) &A; 9a11d129aa8ad9fa123e72d0663c327d5578d2602Eric Christopher return p != 0; 10a11d129aa8ad9fa123e72d0663c327d5578d2602Eric Christopher} 11