66

Why does it say someone +1'd your rant/comment in the notification while the person actually ++'d it?

a+1 and a++ are not the same.
@dfox I don't like this.

Comments
  • 7
    Holy shit I never noticed that before..
    Now I will see this all the time.
    We need an explanation!
  • 1
  • 9
    Wait I thought x++ == x+1 🤔
  • 7
    @sha-256 you can make your own iterator, where ++ isn't giving you the next iteration (would be unlogical).
    And the ++ operator doesn't exist in all language (python user :p)
  • 6
    Because when devRant started ++ was actually +1. Guess they forgot to change the message...
  • 11
    @SHA-256 x+1 doesn't change the value of x
  • 0
    @Ashkin But it does add 1 to x (if you print x+1 it will work(in python it does))
  • 3
    @SHA-256 C'mon man. It's inaccurate. And we're all developers. x+1 doesn't change the value of x. This must be fixed or it'll be ironic to have this technical error on an app like this.
  • 6
    @SHA-256 someone giving you a ++ would increment your reputation, whereas +1 would only change its displayed value
  • 3
    Out of scope but first time happy to read an argument between people because it's all about coding, and nothing else!
  • 3
    You must be new here.
  • 2
    @gitpush cool username btw
  • 0
    @bogdanwk ya signed up a month ago, rarely read comments
  • 0
  • 0
    no actually that's correct? +1'd is better than +=1

    And only I can give out multiple pluses as you can see here.... :) (j/k... its a semi-bug)
  • 0
    Maybe it depends on the compiler. If devrant compiler is faster with +=1 than ++, it would make sense
  • 4
    @SHA-256 @Ashkin is right there is a difference between '++' and '+', the fist one is an unary operator that increments the value after returning the original value while the second one is a binary operator that returns the addition between the two operands without modifying any of them.

    Something like:

    ++ =>
    function(x){
    return x;
    x = x+1; //Increment after returning
    }

    + =>
    function(x, y){
    return x + y; //No operand modified
    }
  • 4
    I guess I was feeling a little StackOverflowy
  • 0
    @andros705 This is why I want to be someone ++ your comment/rant. Not someone did your comment/rant ++.
  • 1
    @SHA-256 no x+1 == ++x

    X+1 != X++
  • 1
    I don't think it has anything to do with code.
    Did you never had a conversation on a chat and when someone say something everyone agree, they just wrote '+1', maybe it come from this, when developers don't say i agree, but rather say just +1... Maybe.
  • 0
    You all should chill, everyone knows SCHEMEs iterator is the best..
    (add1 x). If you wanna be classy you got (+ x 1). I'd say DevRant shouldn't have "++" or +1'd at all. What we need is:
    "Insert name (add1 x)'d your rant!" Now that's style.

    Thumbs up for a truly "functional" language 👍
  • 0
    @nicnaknic That would be ok too. At this point though I am more interested in having an expression that is correct than style. Plus not everyone is familiar with functional languages.

    Someone +1ing a thing means that they only incremented it on their side not on devRant's server.
  • 1
    Preincrements
  • 0
    @Damgecontrol someone ++'d you comment / rant would actually imply ++rant or ++comment.
Add Comment