Prev: 5.0d0+tan(phi) vs 5+tan(phi)
Next: 2D interpolation
From: Dieter Britz on 7 Jan 2010 07:51 What is a symptom of, when a print statement, inserted into a program as a diagnostic, removes an error? -- Dieter Britz (dieterbritz<at>yahoo.com)
From: Michel Olagnon on 7 Jan 2010 08:05 Dieter Britz wrote: > What is a symptom of, when a print statement, inserted into a program > as a diagnostic, removes an error? Array bound violation is the most likely. Some additional memory space is allocated for the purpose of the print statement, and the array then overflows into that space without any visible effect.
From: glen herrmannsfeldt on 7 Jan 2010 08:46 Dieter Britz <dieterbritz(a)yahoo.com> wrote: > What is a symptom of, when a print statement, inserted into a > program as a diagnostic, removes an error? Without knowing the error it is hard to say. With x87 floating point, small changes can change the precision (and/or accuracy) of the result. -- glen
From: robin on 7 Jan 2010 10:11 "Dieter Britz" <dieterbritz(a)yahoo.com> wrote in message news:hi4llg$eup$1(a)news.net.uni-c.dk... | What is a symptom of, when a print statement, inserted into a program | as a diagnostic, removes an error? Almost certainly, it is a subscript or substring error. Less likely causes are uninitialized variables, mismatched argments/dummy arguments, etc. For starters you need to turn on all checks.
From: Arjan on 7 Jan 2010 10:41
Try to explicitly switch off any optimization. I have this often when the optimizer takes a short-cut and when the print-statement prevents optimization and therefore the faulty short-cut in command execution. Also: activate all checks at compile time and see what happens now. Try different compilers. I like g95 since it warns quite often and has relatively readable/understandable error-messages. A. |