When is an integer<->pointer cast actually correct?

后端 未结 15 2643
北荒
北荒 2020-12-13 07:48

The common folklore says that:

  • The type system exists for a reason. Integers and pointers are distinct types, casting between them is a malpractice in the m

15条回答
  •  一整个雨季
    2020-12-13 08:41

    The only time i cast a pointer to an integer is when i want to store a pointer, but the only storage i have available is an integer.

提交回复
热议问题