Why I hate C++. Volume 985 of a series. Collect them all.
So I'm trying to do a very simple thing, use fscanf to read data from a
tab-delimited file. This is 'major yawn' code. Despite this, I've spent
the past three hours debugging code, tearing apart my elegant one-line
fscanf into an un ugly and ungainly loop to track down the error.
Finally, I type the error code I'm getting into google and see what
pops up.
It seems that you can't do a string to floating point conversion if the
floating point library isn't linked in...and Microsoft's compiler is
too "smart" to link it if there's no FP math. So to get fscanf to work,
I need to include:
float num=0;
In order to force the FP library to load.
To paraphrase Han Solo "No paycheck is worth this."
Comments (1)