c - Is a literal always an expression? -


is literal expression?

if no, literals expressions , not?

for literals expressions:

  1. is literal primary expression, since literal doesn't contain operator?

  2. can literal either lvalue or non-lvalue? example,

  3. are literals except compound literals constant expressions?

    conversely, constant expressions not literals?

in c standard terminology, literals string literals , compound literals. guess refer things 0 known constants, not literals.

if language grammar summary (annex of c11 standard) see definition of primary-expression includes constant, string-literal. postfix-expression includes primary-expression , compound literals.

the specification of lvalue-ness compound literals can found in compound literal section (6.7.9.), string literals.

constant expression defined section 6.6 , better read entire section attempt summary here. orthogonal concept of literals.


Comments

Popular posts from this blog

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

python Tkinter Capturing keyboard events save as one single string -

sql server - Why does Linq-to-SQL add unnecessary COUNT()? -