Using strings as immediate character arrays

Tomas Rokicki rokicki at navajo.STANFORD.EDU
Tue Aug 19 09:18:34 AEST 1986


[ Snugglebunnies, snugglebunnies, snuggl+~=/

In a program I have been writing, I have found it nice to
have immediate character arrays, so I could do things like

	cmdchr = "rofq"[menu_selection] ;

Is this legal and portable?  It seems to work.      -tom



More information about the Comp.lang.c mailing list