bpmurray wrote: » One of the guys pointed out that there was a dependency of one C file on another C file (not a header file) which surprised me. After a little investigation, I realised that it was a piece of wonderful workaround-code that I had written myself in a former existence 16 years ago! Hopefully I'm not as daft any more.
Labarbapostiza wrote: » I don't see anything wrong with that or that it's bad practice. I think you need to compile the referenced C file, and then place the OBJ where the linker can see it. Are you suggesting writing everything in one monolithic C file is good practice, as opposed to splitting code over many C files?
private static void UpdateNode(XmlNode theNode, string nodesNewValue) { theNode.InnerText = nodesNewValue; }
[Rasta] wrote: » This was the best piece of code that I could find in a class I recently looked at. private static void UpdateNode(XmlNode theNode, string nodesNewValue) { theNode.InnerText = nodesNewValue; } I checked through version control and it has never been changed.
Hi c_man, As we all know, you're behind on *issue*. I was thinking about this, have you considered asking on Stack Overflow?
c_man wrote: » I've been working on this right little... so-and-so of an issue since before Christmas. New scrum-master trying to impress others sends a wide email (I don't know if anybody wasn't CCed on it) this morning, :rolleyes: Never thought of that... Oh and I was the one who happened to notice *issue* the day before they were all set to push this out to thousands of customers. But nah, yeah it's my fault.
moycullen14 wrote: » You could try an troll him by replaying 'What is this Stack Overflow of which you speak?'
djpbarry wrote: » Or better still, respond with: "I'm not sure Stack Overflow is a suitable forum to seek advice on dealing with a scrum master who's being a dick".
BrokenArrows wrote: » Or you could reply all and say "Hi ScrumMaster, I would like to have a private discussion regarding your suggestion". Fairly clear to everyone on the list what your going to say in this private chat.
c_man wrote: » Opening a "manager" class, responsible for all manner of threading funkiness. Then I see this... #if defined WIN32 ...... #elif defined Linux //this is guess work! Have no Linux machine Repeated throughout the class.
Buford T Justice wrote: » and if its a 64 bit?
_WIN32 Defined for applications for Win32 and Win64. Always defined.
neil_hosey wrote: » One of the "senior" guys in current place on me pushing for TDD.. Oh yeah go ahead, but don't write too many unit tests because it will slow down the build.. :mad:
Raging_Ninja wrote: » Another horror from StackOverflow:https://stackoverflow.com/questions/35634793/how-to-query-a-database-within-a-loop-in-c-sharp Some guy is running his SQL queries from embedded Razor in his MVC views. On phone so will post code later in case it is deleted.
Page Not Found This question was voluntarily removed by its author. Here are some similar questions that might be relevant:
[Rasta] wrote: » I'm in a 3 man development team and I asked the Senior Developer (SD) why we don't have any strategy for working on projects. SD says, something along the lines of: In the real world there is no time to plan projects, you just have to do stuff as you go along. The only way the SD tackles projects is by simply going to 1 meeting to get some specifications from the user and then cracking away writing code. And here's me wondering why there is no source control, no project plan, no documentation, no best practices, no software patterns used... The SD is adamant on writing everything in one class. If the SD sees more than 2-3 classes in a library you need to rewrite. We have an email group for error messages. I redirect those into a sub folder. It has about 7.5k emails after 6 months or so. When I questioned the SD about these, the SD said that i'll get used to seeing the ones that are actually bad errors I checked one of the server's event viewer. About 4k error entries in there. There is possibly new management rolling in, so I'm sure they'd spot and sort this madness. Gladly the other Developer is on the same page as me, so there seems to be a bit of hope.
BrokenArrows wrote: » Had a look at some of our automated tests today and came across this test class which dozens of test methods like this:[TestMethod()] public void OpenTimeTest() { MyClass target = new MyClass(); target.OpenTime = DateTime.Now; DateTime ActualTime = target.OpenTime; Assert.AreEqual(target.OpenTime, ActualTime); } The OpenTime is a field so no work is being done when it is set. I guess someone just wants to see lots of green ticks beside their automated tests.
[TestMethod()] public void OpenTimeTest() { MyClass target = new MyClass(); target.OpenTime = DateTime.Now; DateTime ActualTime = target.OpenTime; Assert.AreEqual(target.OpenTime, ActualTime); }
Anesthetize wrote: » There's "senior" guys where I work who just won't write unit tests full-stop.
I once found that an end-of-month report for our supply department had a value at the end of the document that had no meaning from a programming perspective. It used a table column that was long obsolete, and even though the data no longer meant anything, the program still reported the value. I removed the report entry, and explained to the supply manager the reasons for doing so. His response was, “I have always reported this figure to senior management, I must continue to do so.” All that was needed was a simple change to the code:Seed = today; ReportValue = random(Seed)*1000; Happy manager. Senior management none the wiser.
Seed = today; ReportValue = random(Seed)*1000;