473,386 Members | 2,078 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

fatal error LNK1179

Hi,

I am getting
LNK1179: invalid or corrupt file: duplicate COMDAT '<mangled name'
The file compiles fine. What can I do?

Schobi

--
Sp******@gmx.de is never read
I'm Schobi at suespammers dot org

"Sometimes compilers are so much more reasonable than people."
Scott Meyers
Nov 17 '05 #1
7 3768
Hendrik Schober <Sp******@gmx.de> wrote:
Hi,

I am getting
LNK1179: invalid or corrupt file: duplicate COMDAT '<mangled name'
The file compiles fine. What can I do?


Well, re-compiling the file, re-opening
the IDE, and re-booting the machine did
not help. However, commenting out the
changes I made did help and after putting
them back into place one by one it was
gone.
Scary.

Schobi

--
Sp******@gmx.de is never read
I'm Schobi at suespammers dot org

"Sometimes compilers are so much more reasonable than people."
Scott Meyers
Nov 17 '05 #2
Hendrik Schober <Sp******@gmx.de> wrote:
Hendrik Schober <Sp******@gmx.de> wrote:
Hi,

I am getting
LNK1179: invalid or corrupt file: duplicate COMDAT '<mangled name'
The file compiles fine. What can I do?


Well, re-compiling the file, re-opening
the IDE, and re-booting the machine did
not help. However, commenting out the
changes I made did help and after putting
them back into place one by one it was
gone.
Scary.


Damn! It is back. I was afraid that
would happen.
What do I do?

Schobi

--
Sp******@gmx.de is never read
I'm Schobi at suespammers dot org

"Sometimes compilers are so much more reasonable than people."
Scott Meyers

Nov 17 '05 #3
> [...]

Anyone out there?
Whenever the file needs to get recompiled,
linking fails. Then I comment two lines of
code, build the project, and it links. Then
I go back and uncomment one of the two lines
and rebuild ==> this works. Then I go back
again, uncomment the second line and rebuild
==> it all works now.
Whenever I skip one step, it fails. Whenever
the file is recompiled (due to some header
changing), I have to start all over.
This is driving me mad.

And, of course, if I check this in, the build
might fail, too. So I'm sitting on this file
and don't know what to do!

Schobi

--
Sp******@gmx.de is never read
I'm Schobi at suespammers dot org

"Sometimes compilers are so much more reasonable than people."
Scott Meyers
Nov 17 '05 #4
Hendrik Schober wrote:
[...]
Anyone out there?


Out here yes - haven't encountered this particular problem, nor heard of it
before, so I'm not coming up with any ideas - sorry.
Whenever the file needs to get recompiled,
linking fails. Then I comment two lines of
code, build the project, and it links. Then
I go back and uncomment one of the two lines
and rebuild ==> this works. Then I go back
again, uncomment the second line and rebuild
==> it all works now.
Whenever I skip one step, it fails. Whenever
the file is recompiled (due to some header
changing), I have to start all over.
This is driving me mad.
May you should try re-writing the code in question using a radically
different style. It seems likely that you're encountering a fairly obscure
bug in which the compiler emits two different bodies for the a single
template instantiation.

And, of course, if I check this in, the build
might fail, too. So I'm sitting on this file
and don't know what to do!


Call Product Support.

-cd

Nov 17 '05 #5
Carl Daniel [VC++ MVP] <cp*****************************@mvps.org.nospam > wrote:
[...]
May you should try re-writing the code in question using a radically
different style.
No way. This underlies a fairly important
part of the app. Re-designing this means
another three weeks and we are days from
a deadline.
It seems likely that you're encountering a fairly obscure
bug in which the compiler emits two different bodies for the a single
template instantiation.

I don't understand this.
I suspected that it would emit two equal
bodies for different instances? But you
say, it's the other way around???
And, of course, if I check this in, the build
might fail, too. So I'm sitting on this file
and don't know what to do!


Call Product Support.


It would take days (at least!) to sort
this out through support channels. I
am after an idea what to do today. The
problem is hard to reproduce, since
changing the source file back and forth
makes it (dis-)appear.
This puzzles me the most. Is there any
files (besides PCH's which aren't used
here) where the compiler saves any
state info between compiles???
-cd


Schobi

--
Sp******@gmx.de is never read
I'm Schobi at suespammers dot org

"Sometimes compilers are so much more reasonable than people."
Scott Meyers
Nov 17 '05 #6
Hendrik Schober wrote:
Carl Daniel [VC++ MVP]
<cp*****************************@mvps.org.nospam > wrote:
[...]
May you should try re-writing the code in question using a radically
different style.
No way. This underlies a fairly important
part of the app. Re-designing this means
another three weeks and we are days from
a deadline.


All the more reason to start taking definitive action. Thrashing on an
obscure tool-chain bug has a low probability of success in any timeframe.
It seems likely that you're encountering a fairly
obscure bug in which the compiler emits two different bodies for the
a single template instantiation.

I don't understand this.
I suspected that it would emit two equal
bodies for different instances? But you
say, it's the other way around???


I think so. I've encountered a bug before that resulted in multiple
instantiations of a template function that were different (but have the same
name). IIUC, the linker matches up like-named COMDATs and discards all but
one - but it does check to verify that they do indeed contain the same
content.
And, of course, if I check this in, the build
might fail, too. So I'm sitting on this file
and don't know what to do!
Call Product Support.


It would take days (at least!) to sort
this out through support channels.


If you never start the process, it'll never happen. IMO it makes sense as a
contingency plan to get things rolling with PSS.
I
am after an idea what to do today. The
problem is hard to reproduce, since
changing the source file back and forth
makes it (dis-)appear.
This puzzles me the most. Is there any
files (besides PCH's which aren't used
here) where the compiler saves any
state info between compiles???


Not that I know of, but there is the .ilk file where the linker saves
information if you have /incremental:yes in your link options. Normally
Release builds don't do incremental links, but that might be something to
look into.

-cd
Nov 17 '05 #7
Carl Daniel [VC++ MVP] <cp*****************************@mvps.org.nospam > wrote:
[...]
May you should try re-writing the code in question using a radically
different style.
No way. This underlies a fairly important
part of the app. Re-designing this means
another three weeks and we are days from
a deadline.


All the more reason to start taking definitive action. Thrashing on an
obscure tool-chain bug has a low probability of success in any timeframe.

I'll see if I can narrow it down tonight
as I will have to make more changes to
this file anyway.

What's interesting: It compiled fine at
first try on another machine. As long as
I can somehow make it work by doing what
I did so far, it has to remain low
priority on my todo-list until we have
passed that milestone.
[...] I've encountered a bug before that resulted in multiple
instantiations of a template function that were different (but have the same
name). IIUC, the linker matches up like-named COMDATs and discards all but
one - but it does check to verify that they do indeed contain the same
content.
I see.
[...]
Call Product Support.
It would take days (at least!) to sort
this out through support channels.


If you never start the process, it'll never happen. IMO it makes sense as a
contingency plan to get things rolling with PSS.


Mhmm. After I made it passed that deadline.
I
am after an idea what to do today. The
problem is hard to reproduce, since
changing the source file back and forth
makes it (dis-)appear.
This puzzles me the most. Is there any
files (besides PCH's which aren't used
here) where the compiler saves any
state info between compiles???


Not that I know of, but there is the .ilk file where the linker saves
information if you have /incremental:yes in your link options. Normally
Release builds don't do incremental links, but that might be something to
look into.


I suppose you mean "/INCREMENTAL"?
Thanks, I will try to delete this when I
run into the problem again.
-cd


Schobi

--
Sp******@gmx.de is never read
I'm Schobi at suespammers dot org

"Sometimes compilers are so much more reasonable than people."
Scott Meyers
Nov 17 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: PeterF | last post by:
Hello, what is wrong here? the purpose is to create an array of objects and then interate over it, calling some method from all of them. I get just the following at the marked line ("// FATAL...
8
by: Tim Tyler | last post by:
I'm getting fatal errors when executing code - and my error handler is failing to trap them - so I get no stack backtrace :-( The error I am getting is: "Fatal error: Call to a member function...
2
by: Itjalve | last post by:
This gives me a fatal error. I'm using .NET VC7.1 and made a win32 consol app, I have no problems with VC6. Debug build. I have removed nearly all my code this is whats left. From the beginning...
6
by: Steve Crawford | last post by:
I've started seeing the following in my logs: FATAL: invalid frontend message type 8 I searched back over a month and there are 5 instances of this error of which 4 are in the last 24 hours. ...
4
by: ARF | last post by:
I'm testing AutoCAD 2005 automation via VS2005 Pro C++/CLR and I'm getting fatal compiler errors. I start with a default C++/CLR class library project and modify it by adding the following...
0
by: Rich | last post by:
I am trying to obtain more debugging information for an issue I reported (ref. Bug #37185 <http://bugs.php.net/bug.php?id=37185&edit=2>). Unfortunately, I do not have access to the now-ancient...
1
by: R | last post by:
Hi All, I'm using PHP 5, my code fully separates code from content, my code throws exceptions (LIZException) when error occurs. but every time I throw exception I get this fatal error: ...
3
by: Dhieraj | last post by:
While compiling a C++ code I am getting the following error : CC -c -I/opt/iona/artix/2.0/include -I/opt/iona/asp/6.0/include -I/opt/ar/api63/include -I//var/tmp/vidya/aotscommon/include ...
1
by: kvarada | last post by:
Hello Experts, I am building my application on WinNT.4.0_i386_MSVC.7.1 platform. When I build the application on a stand alone machine, it builds fine. But when I build the same application from a...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.