• Mikelius@lemmy.ml
    link
    fedilink
    arrow-up
    16
    ·
    5 months ago

    What is that weird >>=== symbol? Looks like a cross breed between C and JavaScript here.

    • underscore_@sopuli.xyz
      link
      fedilink
      arrow-up
      21
      ·
      edit-2
      5 months ago

      It’s a the right shift assignment operator so x >>= 4 right shifts x by 4 and assigns the result back to x. The code editor is displaying single double wide symbol (ligature) instead of the three character long operator >>=, I discovered today these are in fact well loved by some coders.

    • EmptySlime@lemmy.blahaj.zone
      link
      fedilink
      English
      arrow-up
      8
      ·
      5 months ago

      I guess it’s a special kind of character called a ligature. They apparently are characters for combined operators. So in this case it seems to just be >>== all as one character?

      • zod000@lemmy.ml
        link
        fedilink
        arrow-up
        3
        ·
        5 months ago

        It is exactly that. Some people really like them, others do not (me included). You usually need to go a little out of your way to get a font that supports ligatures for your editor.