mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-24 23:28:41 +00:00
Print out the variable declaration only if it is a declaration. Otherwise, a
'static' variable will be emitted twice. PR10081 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137134 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -1817,7 +1817,7 @@ bool CWriter::doInitialization(Module &M) {
|
||||
Out << "\n\n/* Global Variable Declarations */\n";
|
||||
for (Module::global_iterator I = M.global_begin(), E = M.global_end();
|
||||
I != E; ++I)
|
||||
if (!I->isDeclaration()) {
|
||||
if (I->isDeclaration()) {
|
||||
// Ignore special globals, such as debug info.
|
||||
if (getGlobalVariableClass(I))
|
||||
continue;
|
||||
|
Reference in New Issue
Block a user