usage of “\” in C?

前端 未结 3 1558
忘了有多久
忘了有多久 2021-01-26 10:46

I was looking over this code, but i was unable to figure out why the usage of \"\\\" after the && operator?

if ((*(u32*)(kaddr + 0x64) == *(u32*)(kad         


        
3条回答
  •  轮回少年
    2021-01-26 11:12

    The backslash is not needed, unless this is part of a #define.

    From the C specification §5.1.1.2

    Each instance of a backslash character (\) immediately followed by a new-line character is deleted, splicing physical source lines to form logical source lines.

    But it's not needed since the C language doesn't require that an if statement be placed on a single line.

提交回复
热议问题