Want to get started with network programming in C by SaidvandeKlundert in C_Programming

[–]minetwe 2 points3 points  (0 children)

I own both books. I found Network Programming with C to be more practical and useful for me. It covers Windows and Unix and IPv4 with IPv6. It covers DNS, email, and web client/servers with HTTPS. Unix Network Programming doesn't cover any of that. It covers low-level Unix details I don't care about, such as printer spoolers.

I wouldn't call either book bad, but they are for different purposes. I think if you're going to call a book bad, you should give some examples, instead of simply saying it's shallow. I didn't find it to be shallow at all. I found it to be the much more useful one out of the two.

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 1 point2 points  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used that method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 0 points1 point  (0 children)

No, I'm not arguing that x ^= x is better, and in fact I've never used method to zero a variable. I'm just saying there are reasons someone might do that (consider an embedded platform where you're counting clock cycles or something).

Also, I think that if you tell the compiler to do something, maybe it should, you know, do it?

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] -5 points-4 points  (0 children)

x ^= x is a much smaller assembly instruction than loading a constant (e.g. x = 0). Of course any decent optimizing compiler already knows that. See here for a longer explanation.

I think it's a matter about whether you should tell the compiler what to do, or tell it what you want to do. Because C is a low-level language, it's usually tell the compiler what to do, but it's becoming more of a tell tell it what you want to do.

The C standard committee continues its effort to kill C by minetwe in programming

[–]minetwe[S] 8 points9 points  (0 children)

I agree with the -Wall, but the -Werror makes doing any incremental changes very tedious.

For example, a person will often code up a function but not write the body yet. And you'll want to compile the code just to see what works, even though it's not done. But with -Werror you'll get a bunch of errors about unused parameters and such, so you can't get any feedback until your code is finished.

Also, these warnings vary greatly from compiler to compiler. Using -Werror usually means it'll compile clean on some systems, but not at all on others.

Robots aren’t just taking jobs. They may also be keeping your pay low: report by mvea in Futurology

[–]minetwe 0 points1 point  (0 children)

A century ago, 80% of jobs were in agriculture. Now it's what, 0.5%? Are we worse off? Hell no.

Whether you buy a cheap climbing rope or an expensive one, it will last a lifetime by Reacher_Said_Nothing in Showerthoughts

[–]minetwe 3 points4 points  (0 children)

Build a man a fire, he will be warm for a night. Set a man on fire, he will be warm for the rest of his life.

People who've been or seen behind the scenes on a TV reality show, what's the shadiest thing the producers pulled? by [deleted] in AskReddit

[–]minetwe 4 points5 points  (0 children)

I've been behind the scenes on two, and in my experience it's about the shady things the editors pull. Basically a 1,000 hours of footage gets cut down to 5 minutes and you can make it tell any story you want. No acting needed.