|
Yeah I don't intend to be ugly about it.
What else is everyone in the raft supposed to do when someone says they'll prioritize themselves ahead as much as they want to everyone else's detriment?
|
|
|
|
|
jochance wrote: What else is everyone in the raft supposed to do when someone says they'll prioritize themselves ahead as much as they want to everyone else's detriment?
The rest of the survivors eat them first?
Freedom is the freedom to say that two plus two make four. If that is granted, all else follows.
-- 6079 Smith W.
|
|
|
|
|
Two devs and a deadline? Looks like the results of a yet another successful death march. Code works, mission accomplished.
|
|
|
|
|
const char const *szSTATUS_DONE = "D";
const char cSTATUS_DONE = *szSTATUS_DONE;
This will make you feel better…
|
|
|
|
|
lol.
(heart attack)
CI/CD = Continuous Impediment/Continuous Despair
|
|
|
|
|
I frequently define two representations of the same status, error or whatever, although usually an enum and a text string, rather than a char and a text string. From the old days, I like switch()-ing on scalars, not on strings or whatever. Besides, the switch variable is language independent, while the text string is language dependent.
The question is whether the two representations should be kept together, which may seem like a good idea for maintenance purposes. Then you must keep all the language variants of the string in the same place, and they must have different names. Or you separate them, which makes maintenance more difficult, but you can keep all the Norwegian strings together, the German strings together and so on. Maybe they are even referenced by the same name. Then, if you add another status/error/... code, you have to look up all the different places where strings are defined, to make sure that you have a string version in all supported languages.
Usually that is not a issue to consider in USA software: Who would ever want any other language than English?
|
|
|
|
|
All c++ header #define are a PITA
Why I should help the compiler to do it's job?
I love c++ but I hate it also for the above....
|
|
|
|
|
Maximilien wrote: they represent the same status (and values) They may represent the same status but they certainly don't represent the same values. One is a string while the other is a character.
/ravi
|
|
|
|
|
obviously.
CI/CD = Continuous Impediment/Continuous Despair
|
|
|
|
|
I had to work on a code base with a static code checker enforcement. And if you used a 'constant' more than twice it would flag it.
Static code checkers are absolutely worthless.
|
|
|
|
|
jschell wrote: Static code checkers are absolutely worthless. You must have encountered an (or several) really bad code checkers. Some of them are really good. On the other hand: The good ones are far from cheap. You get what you pay for.
Also, all the ones I have been in touch with, from the very top down to simple lint, has provided mechanisms for suppressing reports on each specific 'defect'. I see no viable justification for treating >2 uses of constant as a defect, so I would disable that test immediately.
Religious freedom is the freedom to say that two plus two make five.
|
|
|
|
|
trønderen wrote: Some of them are really good
None of them can be that good by their very nature. They can only look for simple problems.
And that is only appropriate with a lot of junior programmers and with little, poor or non-existent code reviews.
Often the problems are stylistic in nature as well.
Complex real bugs originate from execution flow which static code checkers cannot detect at all.
trønderen wrote: mechanisms for suppressing reports on each specific 'defect'.
However they are put in place in the context of process. So people fixate on the process and will not allow that. As I have encountered multiple times. They fixate on the idea that it is 'better' without understanding what is going on.
trønderen wrote: down to simple lint,
I worked at hard core linux/unix C and C++ shops along with reading tech journals for years. And far as I recall no one ever considered lint to be a good idea.
trønderen wrote: You get what you pay for.
It was a paid product.
|
|
|
|
|
jschell wrote: None of them can be that good by their very nature. They can only look for simple problems. It seems quite obvious to me that you have never been introduced to a high quality static analyzer.
It seems to me that if you were offered an opportunity to try out an advanced code analyzer you might reject it as a waste of time, because you know in advance that such animals do not exist.
You are in your full right to think so. And I am in my full right to disagree with you.
Religious freedom is the freedom to say that two plus two make five.
|
|
|
|
|
trønderen wrote: that you have never been introduced to a high quality static analyzer.
Perhaps. You can suggest one if you wish.
I have however, as a principle programmer, been tasked with fixing many bugs which have shown up in production and none of which a static analyzer could have detected.
|
|
|
|
|
jschell wrote: Often the problems are stylistic in nature as well. It must be possible to disable a lot of the warnings about "code smells" based on things like the C++ Core Guidelines and MISRA. Some of these act as if everyone started development inh C++20, exaggerate their importance, and lead to so many warnings as to make the tool useless. As you say, it gets out of hand if people focus on process--the metrics that these tools spit out--without assessing whether the code really needs to change.
jschell wrote: Complex real bugs originate from execution flow which static code checkers cannot detect at all. Coverity and Sonarcloud both highlight execution flows that could lead to the use of a null pointer. For example, they'll tell you that if the following 6 branches are taken, you could end up using an invalid pointer. In some cases, they even detect it across a chain of function calls. Perhaps you don't call this static analysis, because it actually analyzes execution flows, but both of these are classified as static analysis tools. Some warnings can be false positives for reasons that the tool can't understand, but they're worth investigating.
|
|
|
|
|
Greg Utas wrote: Perhaps you don't call this static analysis,
I do.
Greg Utas wrote: they even detect it across a chain of function calls
That I have not seen. Unclear if the tool did not look of if they did not exist.
|
|
|
|
|
|
But can it generate itself?
Freedom is the freedom to say that two plus two make four. If that is granted, all else follows.
-- 6079 Smith W.
|
|
|
|
|
It had been awhile since I pulled up the code, but sure enough when I did, I found a Deslanged.Export.cs file in the Deslang project. Such files are created by Deslang itself. So I did use it to build itself.
Check out my IoT graphics library here:
https://honeythecodewitch.com/gfx
And my IoT UI/User Experience library here:
https://honeythecodewitch.com/uix
|
|
|
|
|
Cool stuff honey. The idea of code writing code is one of the first mind blowers that made me want to write code.
Because you guys will like this if you haven't seen it, even though it's likely I found it from here somehow.
This is in the same "codeception" vein.
This image displays the CRC value of the file which contains it.
[^]
|
|
|
|
|
|
The extra Cs evoke the yack/vomit homophone for me.
Never happened with yak/yac/antlr/JavaCC/etc
|
|
|
|
|
|
I thought The Who did My Generation
|
|
|
|
|
I did it too, there is a big company that operates like that for their products.
GCS/GE d--(d) s-/+ a C+++ U+++ P-- L+@ E-- W+++ N+ o+ K- w+++ O? M-- V? PS+ PE Y+ PGP t+ 5? X R+++ tv-- b+(+++) DI+++ D++ G e++ h--- r+++ y+++* Weapons extension: ma- k++ F+2 X
The shortest horror story: On Error Resume Next
|
|
|
|