• Sylvartas@lemmy.world
    link
    fedilink
    English
    arrow-up
    4
    ·
    1 month ago

    That makes sense, but then you’d just have people converting the int to a float manually and run into the exact same issues.

    • Miaou@jlai.lu
      link
      fedilink
      English
      arrow-up
      2
      ·
      1 month ago

      They wouldn’t be running into an issue, but creating one, that’s different

      • Sylvartas@lemmy.world
        link
        fedilink
        English
        arrow-up
        1
        ·
        1 month ago

        Meh. Imo anyone comparing an integer to a float and not expecting one of them to be implicitly casted to the other’s type will create that issue for themselves when doing the same thing with an explicit cast.

        • Miaou@jlai.lu
          link
          fedilink
          English
          arrow-up
          3
          ·
          1 month ago

          What I meant is, the former can be a genuine mistake, the latter is a conscious (probably uneducated) decision