Switching between float and double precision at compile time

前端 未结 3 1572
一向
一向 2021-01-14 15:27

Where should I look at if I want to switch between float and double precision at compile time. Its like, if user wants everything in float instead of double precision how I

3条回答
  •  不要未来只要你来
    2021-01-14 15:50

    I prefer not to have #defines in my code.

    I would have two different headers with two different typedefs, and allow build options to choose which header is included.

提交回复
热议问题