Whats the difference between .asciiz vs .ascii

后端 未结 1 856
傲寒
傲寒 2021-01-18 12:12

I read that .asciiz null terminates the string (appending \\n?) ... but when looking at the User Data Segment of QtSPIM,

User data segment [100         


        
相关标签:
1条回答
  • 2021-01-18 12:19

    As written by @osgx, ASCIIZ means that the string is terminated by the \0 (ASCII code 0) NUL character. They are even called C strings. To quote from there:

    In computing, a C string is a character sequence terminated with a null character ('\0', called NUL in ASCII). It is usually stored as one-dimensional character array.[dubious – discuss] The name refers to the C programming language which uses this string representation. Alternative names are ASCIIZ (note that C strings do not imply the use of ASCII) and null-terminated string.

    0 讨论(0)
提交回复
热议问题