bison/src state.c

Paul Eggert <[email protected]>
Newsgroups gmane.comp.parsers.bison.cvs
Message-ID <[email protected]>
CVSROOT:	/cvsroot/bison
Module name:	bison
Changes by:	Paul Eggert <[email protected]>	02/12/13 03:37:52

Modified files:
	src            : state.c 

Log message:
	(state_compare): Now inline.  Return bool, not int.
	(state_comparator, stage_hasher): New function, to avoid casts.
	(state_hash_new): Use new functions instead of casting old functions unportably.
	(state_hash_lookup): Use MALLOC rather than alloca, so that we don't
	have to worry about alloca.
	(TRANSITIONS_ALLOC, ERRS_ALLOC, REDUCTIONS_ALLOC,
	STATE_ALLOC): Remove.
	(transitions_new, errs_new, reductions_new, state_new): Use malloc
	rather than calloc, and use offsetof to avoid allocating slightly
	too much storage.
	(state_new): Initialize all members.
	(state_hash): Use unsigned accumulator, not signed.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/bison/bison/src/state.c.diff?tr1=1.27&tr2=1.28&r1=text&r2=text
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.