A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2001-October/017888.html below:

[Python-Dev] GC head alignment issue

[Python-Dev] GC head alignment issue [Python-Dev] GC head alignment issueGuido van Rossum guido@python.org
Thu, 11 Oct 2001 13:15:49 -0400
> My head hurts, so I'm not sure this is strictly legit C (drop-in replacement
> for the current PyGC_Head declaration):
> 
> /* GC information is stored BEFORE the object structure */
> typedef union _gc_head {
> 	struct {
> 		union _gc_head *gc_next; /* not NULL if object is tracked */
> 		union _gc_head *gc_prev;
> 		int gc_refs;
> 	};
> 	double dummy;  /* force worst-case alignment */
> } PyGC_Head;

Alas, gcc gives me warnings about this:

../Include/objimpl.h:274: warning: unnamed struct/union that defines no instances

and references to the fields fail with errors:

../Objects/cellobject.c: In function `PyCell_New':
../Objects/cellobject.c:14: union has no member named `gc_next'
[and many more]

--Guido van Rossum (home page: http://www.python.org/~guido/)



RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4