gnu

Is there a field that stores the exact field separator FS used when in a regular expression, equivalent to RT for RS?

江枫思渺然 提交于 2021-01-20 19:58:29
问题 In GNU Awk's 4.1.2 Record Splitting with gawk we can read: When RS is a single character, RT contains the same single character. However, when RS is a regular expression, RT contains the actual input text that matched the regular expression. This variable RT is very useful in some cases. Similarly, we can set a regular expression as the field separator. For example, in here we allow it to be either ";" or "|": $ gawk -F';' '{print NF}' <<< "hello;how|are you" 2 # there are 2 fields, since ";"

Is there a field that stores the exact field separator FS used when in a regular expression, equivalent to RT for RS?

荒凉一梦 提交于 2021-01-20 19:55:47
问题 In GNU Awk's 4.1.2 Record Splitting with gawk we can read: When RS is a single character, RT contains the same single character. However, when RS is a regular expression, RT contains the actual input text that matched the regular expression. This variable RT is very useful in some cases. Similarly, we can set a regular expression as the field separator. For example, in here we allow it to be either ";" or "|": $ gawk -F';' '{print NF}' <<< "hello;how|are you" 2 # there are 2 fields, since ";"

Is there a field that stores the exact field separator FS used when in a regular expression, equivalent to RT for RS?

依然范特西╮ 提交于 2021-01-20 19:54:50
问题 In GNU Awk's 4.1.2 Record Splitting with gawk we can read: When RS is a single character, RT contains the same single character. However, when RS is a regular expression, RT contains the actual input text that matched the regular expression. This variable RT is very useful in some cases. Similarly, we can set a regular expression as the field separator. For example, in here we allow it to be either ";" or "|": $ gawk -F';' '{print NF}' <<< "hello;how|are you" 2 # there are 2 fields, since ";"

GNU standard library naming conventions

梦想的初衷 提交于 2020-12-30 17:31:10
问题 When I'm looking at the implementation of GNU libraries (well, libstdc++ mostly), I can see that there are recurring patterns in naming. Template types are named _Tp , members have prepending _M_ , some tokens have prepending double underscores, etc. I tried to find documentation on naming conventions to no avail. GNU has a styling guide, which is also followed in the code, but is more like a subset of this naming convention. Do you know any documentation on styling specifics of GNU gcc

GNU standard library naming conventions

不羁的心 提交于 2020-12-30 17:28:23
问题 When I'm looking at the implementation of GNU libraries (well, libstdc++ mostly), I can see that there are recurring patterns in naming. Template types are named _Tp , members have prepending _M_ , some tokens have prepending double underscores, etc. I tried to find documentation on naming conventions to no avail. GNU has a styling guide, which is also followed in the code, but is more like a subset of this naming convention. Do you know any documentation on styling specifics of GNU gcc

GNU standard library naming conventions

青春壹個敷衍的年華 提交于 2020-12-30 17:24:53
问题 When I'm looking at the implementation of GNU libraries (well, libstdc++ mostly), I can see that there are recurring patterns in naming. Template types are named _Tp , members have prepending _M_ , some tokens have prepending double underscores, etc. I tried to find documentation on naming conventions to no avail. GNU has a styling guide, which is also followed in the code, but is more like a subset of this naming convention. Do you know any documentation on styling specifics of GNU gcc

GNU standard library naming conventions

流过昼夜 提交于 2020-12-30 17:12:34
问题 When I'm looking at the implementation of GNU libraries (well, libstdc++ mostly), I can see that there are recurring patterns in naming. Template types are named _Tp , members have prepending _M_ , some tokens have prepending double underscores, etc. I tried to find documentation on naming conventions to no avail. GNU has a styling guide, which is also followed in the code, but is more like a subset of this naming convention. Do you know any documentation on styling specifics of GNU gcc

GNU standard library naming conventions

风格不统一 提交于 2020-12-30 17:10:57
问题 When I'm looking at the implementation of GNU libraries (well, libstdc++ mostly), I can see that there are recurring patterns in naming. Template types are named _Tp , members have prepending _M_ , some tokens have prepending double underscores, etc. I tried to find documentation on naming conventions to no avail. GNU has a styling guide, which is also followed in the code, but is more like a subset of this naming convention. Do you know any documentation on styling specifics of GNU gcc

Macro substituting a constant number in GAS

烈酒焚心 提交于 2020-12-05 04:58:25
问题 What't wrong with that macro on X86 GNU Assembly? It says the symbol S is undefined during linking. .macro S size=40 \size .endm I'm using it like mov %eax, S 回答1: Macros are used to create templates for code you frequently use, not to input a constant number. As such, I do not believe the assembler does macro expansion within an expression. Since you simply want a number, you could use .set to define a constant. .set S, 40 mov %eax, S Also, in case you usually use intel syntax, make sure you