Why is gcc not showing a warning message for using $ in a variable name?












11















I'm new to C and am learning C from Programming in C, 4th ed. by Stephen Kochan. On page 29, he writes $ is not a valid character for variable names. He is using the C11 standard.



I wrote the following code



#include <stdio.h>

int main (void)
{
int a$ = 1;

printf ("%i", a$);

return 0;
}


and ran it with the command gcc -std=c11 -pedantic practice.c -o practice.o && ./practice.o. My filename is practice.c.



The output is 1. Shouldn't the compiler give me a warning for using $? Isn't using $ sign for identifiers an extension that GCC provides?



I'm using GCC 8.2.0 in Ubuntu 18.10.



Edit:



Also, doesn't GCC not use the GNU extensions when I use -std=c11? That is what is written in the Appendix of the book (pg. no. 497).



I am getting an warning by using -std=c89 though.










share|improve this question









New contributor




Apoorv Potnis is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
















  • 7





    Unrelated, but the .o extension is usually used for object files, not for the final executable.

    – Federico klez Culloca
    13 hours ago








  • 3





    There's no extension for executables in *nix systems. The filesystem doesn't use that to determine the type of a file. So usually executables just don't have extensions and practice is correct. Check your /usr/bin directory and you'll see that the programs there don't have an extension either.

    – Federico klez Culloca
    13 hours ago








  • 2





    About the fact that its properties say "shared library" is probably because of your desktop environment. If I do file practice from the command line I get practice: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=928002f23b27d5c9bc55a15bf769edfaf3e62c23, not stripped

    – Federico klez Culloca
    13 hours ago






  • 1





    The file utility can show shared object for an ELF executable if it is a position-independent executable. Some distributions configure GCC so that it creates position-independent executables by default (usually this requires using -pie and -fPIC options).

    – Sergey Vlasov
    9 hours ago






  • 1





    @MrLister: Although traditional BASIC implementations used $ as a suffix for string-variable names, I wouldn't expect a trailing $ to have similar meanings in C. If I was examining code that used such a suffix, I'd expect that the programmer was exploiting some special way that the target implementation would process identifiers with such a suffix. For example, a compiler targeting a platform which can access objects near the frame pointer faster than those which are further away might place all objects whose names have a trailing $ after those that don't.

    – supercat
    7 hours ago
















11















I'm new to C and am learning C from Programming in C, 4th ed. by Stephen Kochan. On page 29, he writes $ is not a valid character for variable names. He is using the C11 standard.



I wrote the following code



#include <stdio.h>

int main (void)
{
int a$ = 1;

printf ("%i", a$);

return 0;
}


and ran it with the command gcc -std=c11 -pedantic practice.c -o practice.o && ./practice.o. My filename is practice.c.



The output is 1. Shouldn't the compiler give me a warning for using $? Isn't using $ sign for identifiers an extension that GCC provides?



I'm using GCC 8.2.0 in Ubuntu 18.10.



Edit:



Also, doesn't GCC not use the GNU extensions when I use -std=c11? That is what is written in the Appendix of the book (pg. no. 497).



I am getting an warning by using -std=c89 though.










share|improve this question









New contributor




Apoorv Potnis is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
















  • 7





    Unrelated, but the .o extension is usually used for object files, not for the final executable.

    – Federico klez Culloca
    13 hours ago








  • 3





    There's no extension for executables in *nix systems. The filesystem doesn't use that to determine the type of a file. So usually executables just don't have extensions and practice is correct. Check your /usr/bin directory and you'll see that the programs there don't have an extension either.

    – Federico klez Culloca
    13 hours ago








  • 2





    About the fact that its properties say "shared library" is probably because of your desktop environment. If I do file practice from the command line I get practice: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=928002f23b27d5c9bc55a15bf769edfaf3e62c23, not stripped

    – Federico klez Culloca
    13 hours ago






  • 1





    The file utility can show shared object for an ELF executable if it is a position-independent executable. Some distributions configure GCC so that it creates position-independent executables by default (usually this requires using -pie and -fPIC options).

    – Sergey Vlasov
    9 hours ago






  • 1





    @MrLister: Although traditional BASIC implementations used $ as a suffix for string-variable names, I wouldn't expect a trailing $ to have similar meanings in C. If I was examining code that used such a suffix, I'd expect that the programmer was exploiting some special way that the target implementation would process identifiers with such a suffix. For example, a compiler targeting a platform which can access objects near the frame pointer faster than those which are further away might place all objects whose names have a trailing $ after those that don't.

    – supercat
    7 hours ago














11












11








11








I'm new to C and am learning C from Programming in C, 4th ed. by Stephen Kochan. On page 29, he writes $ is not a valid character for variable names. He is using the C11 standard.



I wrote the following code



#include <stdio.h>

int main (void)
{
int a$ = 1;

printf ("%i", a$);

return 0;
}


and ran it with the command gcc -std=c11 -pedantic practice.c -o practice.o && ./practice.o. My filename is practice.c.



The output is 1. Shouldn't the compiler give me a warning for using $? Isn't using $ sign for identifiers an extension that GCC provides?



I'm using GCC 8.2.0 in Ubuntu 18.10.



Edit:



Also, doesn't GCC not use the GNU extensions when I use -std=c11? That is what is written in the Appendix of the book (pg. no. 497).



I am getting an warning by using -std=c89 though.










share|improve this question









New contributor




Apoorv Potnis is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.












I'm new to C and am learning C from Programming in C, 4th ed. by Stephen Kochan. On page 29, he writes $ is not a valid character for variable names. He is using the C11 standard.



I wrote the following code



#include <stdio.h>

int main (void)
{
int a$ = 1;

printf ("%i", a$);

return 0;
}


and ran it with the command gcc -std=c11 -pedantic practice.c -o practice.o && ./practice.o. My filename is practice.c.



The output is 1. Shouldn't the compiler give me a warning for using $? Isn't using $ sign for identifiers an extension that GCC provides?



I'm using GCC 8.2.0 in Ubuntu 18.10.



Edit:



Also, doesn't GCC not use the GNU extensions when I use -std=c11? That is what is written in the Appendix of the book (pg. no. 497).



I am getting an warning by using -std=c89 though.







c gcc gcc-warning






share|improve this question









New contributor




Apoorv Potnis is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











share|improve this question









New contributor




Apoorv Potnis is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









share|improve this question




share|improve this question








edited 13 hours ago







Apoorv Potnis













New contributor




Apoorv Potnis is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









asked 13 hours ago









Apoorv PotnisApoorv Potnis

1587




1587




New contributor




Apoorv Potnis is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





New contributor





Apoorv Potnis is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






Apoorv Potnis is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.








  • 7





    Unrelated, but the .o extension is usually used for object files, not for the final executable.

    – Federico klez Culloca
    13 hours ago








  • 3





    There's no extension for executables in *nix systems. The filesystem doesn't use that to determine the type of a file. So usually executables just don't have extensions and practice is correct. Check your /usr/bin directory and you'll see that the programs there don't have an extension either.

    – Federico klez Culloca
    13 hours ago








  • 2





    About the fact that its properties say "shared library" is probably because of your desktop environment. If I do file practice from the command line I get practice: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=928002f23b27d5c9bc55a15bf769edfaf3e62c23, not stripped

    – Federico klez Culloca
    13 hours ago






  • 1





    The file utility can show shared object for an ELF executable if it is a position-independent executable. Some distributions configure GCC so that it creates position-independent executables by default (usually this requires using -pie and -fPIC options).

    – Sergey Vlasov
    9 hours ago






  • 1





    @MrLister: Although traditional BASIC implementations used $ as a suffix for string-variable names, I wouldn't expect a trailing $ to have similar meanings in C. If I was examining code that used such a suffix, I'd expect that the programmer was exploiting some special way that the target implementation would process identifiers with such a suffix. For example, a compiler targeting a platform which can access objects near the frame pointer faster than those which are further away might place all objects whose names have a trailing $ after those that don't.

    – supercat
    7 hours ago














  • 7





    Unrelated, but the .o extension is usually used for object files, not for the final executable.

    – Federico klez Culloca
    13 hours ago








  • 3





    There's no extension for executables in *nix systems. The filesystem doesn't use that to determine the type of a file. So usually executables just don't have extensions and practice is correct. Check your /usr/bin directory and you'll see that the programs there don't have an extension either.

    – Federico klez Culloca
    13 hours ago








  • 2





    About the fact that its properties say "shared library" is probably because of your desktop environment. If I do file practice from the command line I get practice: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=928002f23b27d5c9bc55a15bf769edfaf3e62c23, not stripped

    – Federico klez Culloca
    13 hours ago






  • 1





    The file utility can show shared object for an ELF executable if it is a position-independent executable. Some distributions configure GCC so that it creates position-independent executables by default (usually this requires using -pie and -fPIC options).

    – Sergey Vlasov
    9 hours ago






  • 1





    @MrLister: Although traditional BASIC implementations used $ as a suffix for string-variable names, I wouldn't expect a trailing $ to have similar meanings in C. If I was examining code that used such a suffix, I'd expect that the programmer was exploiting some special way that the target implementation would process identifiers with such a suffix. For example, a compiler targeting a platform which can access objects near the frame pointer faster than those which are further away might place all objects whose names have a trailing $ after those that don't.

    – supercat
    7 hours ago








7




7





Unrelated, but the .o extension is usually used for object files, not for the final executable.

– Federico klez Culloca
13 hours ago







Unrelated, but the .o extension is usually used for object files, not for the final executable.

– Federico klez Culloca
13 hours ago






3




3





There's no extension for executables in *nix systems. The filesystem doesn't use that to determine the type of a file. So usually executables just don't have extensions and practice is correct. Check your /usr/bin directory and you'll see that the programs there don't have an extension either.

– Federico klez Culloca
13 hours ago







There's no extension for executables in *nix systems. The filesystem doesn't use that to determine the type of a file. So usually executables just don't have extensions and practice is correct. Check your /usr/bin directory and you'll see that the programs there don't have an extension either.

– Federico klez Culloca
13 hours ago






2




2





About the fact that its properties say "shared library" is probably because of your desktop environment. If I do file practice from the command line I get practice: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=928002f23b27d5c9bc55a15bf769edfaf3e62c23, not stripped

– Federico klez Culloca
13 hours ago





About the fact that its properties say "shared library" is probably because of your desktop environment. If I do file practice from the command line I get practice: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=928002f23b27d5c9bc55a15bf769edfaf3e62c23, not stripped

– Federico klez Culloca
13 hours ago




1




1





The file utility can show shared object for an ELF executable if it is a position-independent executable. Some distributions configure GCC so that it creates position-independent executables by default (usually this requires using -pie and -fPIC options).

– Sergey Vlasov
9 hours ago





The file utility can show shared object for an ELF executable if it is a position-independent executable. Some distributions configure GCC so that it creates position-independent executables by default (usually this requires using -pie and -fPIC options).

– Sergey Vlasov
9 hours ago




1




1





@MrLister: Although traditional BASIC implementations used $ as a suffix for string-variable names, I wouldn't expect a trailing $ to have similar meanings in C. If I was examining code that used such a suffix, I'd expect that the programmer was exploiting some special way that the target implementation would process identifiers with such a suffix. For example, a compiler targeting a platform which can access objects near the frame pointer faster than those which are further away might place all objects whose names have a trailing $ after those that don't.

– supercat
7 hours ago





@MrLister: Although traditional BASIC implementations used $ as a suffix for string-variable names, I wouldn't expect a trailing $ to have similar meanings in C. If I was examining code that used such a suffix, I'd expect that the programmer was exploiting some special way that the target implementation would process identifiers with such a suffix. For example, a compiler targeting a platform which can access objects near the frame pointer faster than those which are further away might place all objects whose names have a trailing $ after those that don't.

– supercat
7 hours ago












2 Answers
2






active

oldest

votes


















11














You get a warning with -std=c89 -pedantic. C99 and later allow other implementation-defined characters in identifiers.






share|improve this answer


























  • Yes. This is the reference: gcc.gnu.org/onlinedocs/gcc-8.2.0/cpp/…

    – Apoorv Potnis
    13 hours ago



















2














According to this : GCC Documentation




In GNU C, you may normally use dollar signs in identifier names. This
is because many traditional C implementations allow such identifiers.
However, dollar signs in identifiers are not supported on a few target
machines, typically because the target assembler does not allow them.




So, $ is valid, but it's not a conforming way to code in C.






share|improve this answer





















  • 6





    It's not valid C, only on GCC C. Try compiling with -ansi or -std=C11 and the warnings will start appearing.

    – Spidey
    13 hours ago






  • 1





    @Spidey with -std=c11 no warning appears

    – Federico klez Culloca
    13 hours ago






  • 1





    Try adding -Wall then, to show more warnings.

    – Spidey
    13 hours ago






  • 1





    @Spidey nope, still no warnings.

    – Federico klez Culloca
    13 hours ago






  • 1





    @Spidey: The Standard has no definition for "valid C". Its definition for a "conforming C program" encompasses any blob of text that is acceptable to at least one conforming C implementation. A source text that uses dollar signs in identifiers could not be a "strictly conforming proogram", but the authors of the Standard recognize that much C's usefulness stems from the ability to write non-portable programs that will be usefully processed by some C implementations even if not by all of them.

    – supercat
    7 hours ago











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});






Apoorv Potnis is a new contributor. Be nice, and check out our Code of Conduct.










draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55087023%2fwhy-is-gcc-not-showing-a-warning-message-for-using-in-a-variable-name%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























2 Answers
2






active

oldest

votes








2 Answers
2






active

oldest

votes









active

oldest

votes






active

oldest

votes









11














You get a warning with -std=c89 -pedantic. C99 and later allow other implementation-defined characters in identifiers.






share|improve this answer


























  • Yes. This is the reference: gcc.gnu.org/onlinedocs/gcc-8.2.0/cpp/…

    – Apoorv Potnis
    13 hours ago
















11














You get a warning with -std=c89 -pedantic. C99 and later allow other implementation-defined characters in identifiers.






share|improve this answer


























  • Yes. This is the reference: gcc.gnu.org/onlinedocs/gcc-8.2.0/cpp/…

    – Apoorv Potnis
    13 hours ago














11












11








11







You get a warning with -std=c89 -pedantic. C99 and later allow other implementation-defined characters in identifiers.






share|improve this answer















You get a warning with -std=c89 -pedantic. C99 and later allow other implementation-defined characters in identifiers.







share|improve this answer














share|improve this answer



share|improve this answer








edited 13 hours ago

























answered 13 hours ago









nwellnhofnwellnhof

23.6k46085




23.6k46085













  • Yes. This is the reference: gcc.gnu.org/onlinedocs/gcc-8.2.0/cpp/…

    – Apoorv Potnis
    13 hours ago



















  • Yes. This is the reference: gcc.gnu.org/onlinedocs/gcc-8.2.0/cpp/…

    – Apoorv Potnis
    13 hours ago

















Yes. This is the reference: gcc.gnu.org/onlinedocs/gcc-8.2.0/cpp/…

– Apoorv Potnis
13 hours ago





Yes. This is the reference: gcc.gnu.org/onlinedocs/gcc-8.2.0/cpp/…

– Apoorv Potnis
13 hours ago













2














According to this : GCC Documentation




In GNU C, you may normally use dollar signs in identifier names. This
is because many traditional C implementations allow such identifiers.
However, dollar signs in identifiers are not supported on a few target
machines, typically because the target assembler does not allow them.




So, $ is valid, but it's not a conforming way to code in C.






share|improve this answer





















  • 6





    It's not valid C, only on GCC C. Try compiling with -ansi or -std=C11 and the warnings will start appearing.

    – Spidey
    13 hours ago






  • 1





    @Spidey with -std=c11 no warning appears

    – Federico klez Culloca
    13 hours ago






  • 1





    Try adding -Wall then, to show more warnings.

    – Spidey
    13 hours ago






  • 1





    @Spidey nope, still no warnings.

    – Federico klez Culloca
    13 hours ago






  • 1





    @Spidey: The Standard has no definition for "valid C". Its definition for a "conforming C program" encompasses any blob of text that is acceptable to at least one conforming C implementation. A source text that uses dollar signs in identifiers could not be a "strictly conforming proogram", but the authors of the Standard recognize that much C's usefulness stems from the ability to write non-portable programs that will be usefully processed by some C implementations even if not by all of them.

    – supercat
    7 hours ago
















2














According to this : GCC Documentation




In GNU C, you may normally use dollar signs in identifier names. This
is because many traditional C implementations allow such identifiers.
However, dollar signs in identifiers are not supported on a few target
machines, typically because the target assembler does not allow them.




So, $ is valid, but it's not a conforming way to code in C.






share|improve this answer





















  • 6





    It's not valid C, only on GCC C. Try compiling with -ansi or -std=C11 and the warnings will start appearing.

    – Spidey
    13 hours ago






  • 1





    @Spidey with -std=c11 no warning appears

    – Federico klez Culloca
    13 hours ago






  • 1





    Try adding -Wall then, to show more warnings.

    – Spidey
    13 hours ago






  • 1





    @Spidey nope, still no warnings.

    – Federico klez Culloca
    13 hours ago






  • 1





    @Spidey: The Standard has no definition for "valid C". Its definition for a "conforming C program" encompasses any blob of text that is acceptable to at least one conforming C implementation. A source text that uses dollar signs in identifiers could not be a "strictly conforming proogram", but the authors of the Standard recognize that much C's usefulness stems from the ability to write non-portable programs that will be usefully processed by some C implementations even if not by all of them.

    – supercat
    7 hours ago














2












2








2







According to this : GCC Documentation




In GNU C, you may normally use dollar signs in identifier names. This
is because many traditional C implementations allow such identifiers.
However, dollar signs in identifiers are not supported on a few target
machines, typically because the target assembler does not allow them.




So, $ is valid, but it's not a conforming way to code in C.






share|improve this answer















According to this : GCC Documentation




In GNU C, you may normally use dollar signs in identifier names. This
is because many traditional C implementations allow such identifiers.
However, dollar signs in identifiers are not supported on a few target
machines, typically because the target assembler does not allow them.




So, $ is valid, but it's not a conforming way to code in C.







share|improve this answer














share|improve this answer



share|improve this answer








edited 3 hours ago

























answered 13 hours ago









Arnaud PeraltaArnaud Peralta

710116




710116








  • 6





    It's not valid C, only on GCC C. Try compiling with -ansi or -std=C11 and the warnings will start appearing.

    – Spidey
    13 hours ago






  • 1





    @Spidey with -std=c11 no warning appears

    – Federico klez Culloca
    13 hours ago






  • 1





    Try adding -Wall then, to show more warnings.

    – Spidey
    13 hours ago






  • 1





    @Spidey nope, still no warnings.

    – Federico klez Culloca
    13 hours ago






  • 1





    @Spidey: The Standard has no definition for "valid C". Its definition for a "conforming C program" encompasses any blob of text that is acceptable to at least one conforming C implementation. A source text that uses dollar signs in identifiers could not be a "strictly conforming proogram", but the authors of the Standard recognize that much C's usefulness stems from the ability to write non-portable programs that will be usefully processed by some C implementations even if not by all of them.

    – supercat
    7 hours ago














  • 6





    It's not valid C, only on GCC C. Try compiling with -ansi or -std=C11 and the warnings will start appearing.

    – Spidey
    13 hours ago






  • 1





    @Spidey with -std=c11 no warning appears

    – Federico klez Culloca
    13 hours ago






  • 1





    Try adding -Wall then, to show more warnings.

    – Spidey
    13 hours ago






  • 1





    @Spidey nope, still no warnings.

    – Federico klez Culloca
    13 hours ago






  • 1





    @Spidey: The Standard has no definition for "valid C". Its definition for a "conforming C program" encompasses any blob of text that is acceptable to at least one conforming C implementation. A source text that uses dollar signs in identifiers could not be a "strictly conforming proogram", but the authors of the Standard recognize that much C's usefulness stems from the ability to write non-portable programs that will be usefully processed by some C implementations even if not by all of them.

    – supercat
    7 hours ago








6




6





It's not valid C, only on GCC C. Try compiling with -ansi or -std=C11 and the warnings will start appearing.

– Spidey
13 hours ago





It's not valid C, only on GCC C. Try compiling with -ansi or -std=C11 and the warnings will start appearing.

– Spidey
13 hours ago




1




1





@Spidey with -std=c11 no warning appears

– Federico klez Culloca
13 hours ago





@Spidey with -std=c11 no warning appears

– Federico klez Culloca
13 hours ago




1




1





Try adding -Wall then, to show more warnings.

– Spidey
13 hours ago





Try adding -Wall then, to show more warnings.

– Spidey
13 hours ago




1




1





@Spidey nope, still no warnings.

– Federico klez Culloca
13 hours ago





@Spidey nope, still no warnings.

– Federico klez Culloca
13 hours ago




1




1





@Spidey: The Standard has no definition for "valid C". Its definition for a "conforming C program" encompasses any blob of text that is acceptable to at least one conforming C implementation. A source text that uses dollar signs in identifiers could not be a "strictly conforming proogram", but the authors of the Standard recognize that much C's usefulness stems from the ability to write non-portable programs that will be usefully processed by some C implementations even if not by all of them.

– supercat
7 hours ago





@Spidey: The Standard has no definition for "valid C". Its definition for a "conforming C program" encompasses any blob of text that is acceptable to at least one conforming C implementation. A source text that uses dollar signs in identifiers could not be a "strictly conforming proogram", but the authors of the Standard recognize that much C's usefulness stems from the ability to write non-portable programs that will be usefully processed by some C implementations even if not by all of them.

– supercat
7 hours ago










Apoorv Potnis is a new contributor. Be nice, and check out our Code of Conduct.










draft saved

draft discarded


















Apoorv Potnis is a new contributor. Be nice, and check out our Code of Conduct.













Apoorv Potnis is a new contributor. Be nice, and check out our Code of Conduct.












Apoorv Potnis is a new contributor. Be nice, and check out our Code of Conduct.
















Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55087023%2fwhy-is-gcc-not-showing-a-warning-message-for-using-in-a-variable-name%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

How to label and detect the document text images

Vallis Paradisi

Tabula Rosettana