c0d3r 17 Posted January 22, 2021 Just realized that the compiler error counts were always offset by 1, so where is that extra one? Are the EMBRAS... guys able to count their fingers? if not, I can teach them. 1 Share this post Link to post
Guest Posted January 22, 2021 the third error, stay to programmer that: who made the "mistake" of compiling his code and didn't even pay attention to what he was doing. 1 + 1 + programmer drinking beer while pressing the compile button ... = 3 errors NOTE: don't drink when driving your beast pc! Share this post Link to post
Lars Fosdal 1791 Posted January 22, 2021 3 hours ago, c0d3r said: Just realized that the compiler error counts were always offset by 1, so where is that extra one? Are the EMBRAS... guys able to count their fingers? if not, I can teach them. Example? 1 Share this post Link to post
Stano 143 Posted January 22, 2021 Compilers generally try very hard if they find a bug. Then they don't know when to stop. D10.4 has made significant progress in this direction. The number of reported errors is several orders of magnitude lower. Even so, it is recommended to believe only the first mistake and ignore the others. I wouldn't make it a science. 1 Share this post Link to post
c0d3r 17 Posted January 22, 2021 (edited) 8 hours ago, Lars Fosdal said: Example? Create a new vcl application, drop 2 labels, and make ONE label name typo in Oncreate event. When compiling, it said there were 2 errors in the codes: Edited January 22, 2021 by c0d3r Share this post Link to post
Uwe Raabe 2057 Posted January 22, 2021 Actually there are two errors: undeclared identifier cannot compile unit Seems to be pretty correct in my view. 2 Share this post Link to post
c0d3r 17 Posted January 22, 2021 (edited) 28 minutes ago, Uwe Raabe said: Actually there are two errors: undeclared identifier cannot compile unit Seems to be pretty correct in my view. can't compile the unit is not an error that should be included, its a result due to that ONE typo error in the codes. The errors should be reported exactly as whats in your codes. Edited January 22, 2021 by c0d3r 1 Share this post Link to post
David Heffernan 2345 Posted January 22, 2021 35 minutes ago, c0d3r said: can't compile the unit is not an error that should be included, its a result due to that ONE typo error in the codes. The errors should be reported exactly as whats in your codes. This is so important! We must leave no stone unturned in our battle to persuade Embarcadero to change this! 2 Share this post Link to post
Guest Posted January 22, 2021 33 minutes ago, c0d3r said: can't compile the unit is not an error that should be included, its a result due to that ONE typo error in the codes. The errors should be reported exactly as whats in your codes. Why are you eliminating the possibility of the compiler been schizophrenic ? Please don't deny a compiler his simple rights. Share this post Link to post
Uwe Raabe 2057 Posted January 22, 2021 After all, the first error was actually made by the developer, not the compiler. Quote He that is without sin among you, let him first cast a stone at her. Share this post Link to post
Guest Posted January 22, 2021 thanks @Uwe Raabe for confirm my suppose: 1 + 1 + programmer drinking beer while pressing the compile button ... = 3 errors Share this post Link to post
Mike Torrettinni 198 Posted January 22, 2021 6 hours ago, c0d3r said: can't compile the unit is not an error that should be included, its a result due to that ONE typo error in the codes. The errors should be reported exactly as whats in your codes. It's the same result in 10.2.3, not sure which version you have. I guess Delphi has it's own broken windows theory 😉 Share this post Link to post
Attila Kovacs 629 Posted January 22, 2021 Be positive. You can kill two birds with one stone. Share this post Link to post
David Heffernan 2345 Posted January 23, 2021 20 hours ago, c0d3r said: can't compile the unit is not an error that should be included, its a result due to that ONE typo error in the codes. The errors should be reported exactly as whats in your codes. Leaving aside my sarcastic response above, I think a majority of Delphi users will not regard this as an issue. What happens here is that the compiler reaches a point where the errors which have been encountered so far mean that it decides to abort compilation of this unit. And it reports that decision as an error. It's been this way since the dawn of time. Nobody, but nobody, cares about precisely how many errors there are in their code. There are two states that matter: The code has no errors. The code has some errors. Were the compiler to do what you ask, and not write the "cannot compile unit" error, and report a single error, you would not know that there was but a single error. Because the compiler had given up and any errors that are present in the code which follows the point at which the compiler aborted, would not be counted. It is useful for the compiler to report counts of hints and warnings, since these values are meaningful. Counts of errors are, as I have shown above, are not. That this even has to be explained astounds me. 1 Share this post Link to post
Mike Torrettinni 198 Posted January 23, 2021 (edited) Looks like Warnings is off by 1 too - well it counts same Warning 2x: @c0d3r I guess you started the scrutiny of Compile window... looks even more broken, unfortunately I'm using Delphi 10.2.3, I hope newer versions have this improved. Edited January 23, 2021 by Mike Torrettinni Share this post Link to post
David Heffernan 2345 Posted January 23, 2021 The complete lack of perspective here is breathtaking. 1 Share this post Link to post
Guest Posted January 23, 2021 24 minutes ago, Mike Torrettinni said: Looks like Warnings is off by 1 too - well it counts same Warning 2x: Why is this a problem ? It is basic physics, an empty skull might generate echo, sometimes i wrote things twice or get an idea in double folded due the desolation. Share this post Link to post
Mike Torrettinni 198 Posted January 23, 2021 1 minute ago, Kas Ob. said: Why is this a problem ? It is basic physics, an empty skull might generate echo, sometimes i wrote things twice or get an idea in double folded due the desolation. You don't think it should report 1 Warnings if there is only1 Warning? Why it counts the same warning 2 times? Hints work correct, 1 Hint = 1 reported Hint. Share this post Link to post
Guest Posted January 23, 2021 1 minute ago, Mike Torrettinni said: You don't think I don't for now and for a warning or hint, not important at all, in fact it does show the compiler have ugly workaround(s) and cut corners in its generated messages proce4ssing, but nothing serious or worth the time, even to write this exact post. Share this post Link to post
Mike Torrettinni 198 Posted January 23, 2021 16 minutes ago, Kas Ob. said: I don't for now and for a warning or hint, not important at all, in fact it does show the compiler have ugly workaround(s) and cut corners in its generated messages proce4ssing, but nothing serious or worth the time, even to write this exact post. Since I prefer short blogs over books, I suggest googling: " is attention to detail useful?" and you will find many blogs and even books that might be helpful to you, in software development and also in life. Share this post Link to post
David Heffernan 2345 Posted January 23, 2021 (edited) 33 minutes ago, Mike Torrettinni said: Since I prefer short blogs over books Perhaps this explains the focus on tiny details and missing the bigger picture. We all know about the importance of attention to detail. Of course the compiler spitting out two warnings rather than one here is imperfect. But it has no impact on any user. It's trivial. Delphi has so many big issues and this is what gets people heated?! Edited January 23, 2021 by David Heffernan Share this post Link to post
Mike Torrettinni 198 Posted January 23, 2021 3 minutes ago, David Heffernan said: Problems with attention to detail? You don't read blogs? I like to, usually is condensed topic vs books. Share this post Link to post
David Heffernan 2345 Posted January 23, 2021 2 minutes ago, Mike Torrettinni said: You don't read blogs? I like to, usually is condensed topic vs books. Sure. But if that's all you read then you don't see the big picture. Share this post Link to post
Mike Torrettinni 198 Posted January 23, 2021 2 minutes ago, David Heffernan said: Sure. But if that's all you read then you don't see the big picture. You are pretty vague here... big picture of what, what are you talking about? Share this post Link to post
David Heffernan 2345 Posted January 23, 2021 The fact that you regard this topic as important. That you feel it's important to count errors beyond one. The fact that sometimes delphi emits two warnings for the same issue. None of these things matter. 2 Share this post Link to post