[prev in list] [next in list] [prev in thread] [next in thread] 

List:       llvm-bugs
Subject:    [LLVMbugs] [Bug 12423] New: problem emitting static variable
From:       bugzilla-daemon () llvm ! org
Date:       2012-03-30 18:11:26
Message-ID: bug-12423-206 () http ! llvm ! org/bugs/
[Download RAW message or body]

http://llvm.org/bugs/show_bug.cgi?id=12423

             Bug #: 12423
           Summary: problem emitting static variable
           Product: clang
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: C++
        AssignedTo: unassignedclangbugs@nondot.org
        ReportedBy: rafael.espindola@gmail.com
                CC: dgregor@apple.com, llvmbugs@cs.uiuc.edu
    Classification: Unclassified


For

void bar(const char**);
void foo(int x) {
  if (x)     {
    static const char* keys[] = {"foo"};
    bar(keys);
  }
  else {
    static const char* keys[] = {"bar", "zed"};
    bar(keys);
  }
}

gcc will produce

_ZZ3fooiE4keys:
...
_ZZ3fooiE4keys_0:
...

Old clang produces
@_ZZ3fooiE4keys = ...
@_ZZ3fooiE4keys1 =...

but we currently error with
error: problem emitting static variable '_ZZ3fooiE4keys': already present as
different kind of symbol

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
LLVMbugs@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic