ALT Linux Team development discussions
 help / color / mirror / Atom feed
From: "Kirill A. Shutemov" <kirill@shutemov.name>
To: ALT Linux Team development discussions <devel@lists.altlinux.org>
Subject: Re: [devel] union in C99
Date: Tue, 23 Sep 2008 21:22:47 +0300
Message-ID: <20080923182245.GA11804@localhost.localdomain> (raw)
In-Reply-To: <200809231922.42174.ledest@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1007 bytes --]

On Tue, Sep 23, 2008 at 07:22:41PM +0300, Led wrote:
> потребовалось сделать что-то типа такого:
> -    int         i_bframe_adaptive;
> +    union {
> +        int         i_bframe_adaptive;
> +        int         b_bframe_adaptive __attribute__((__deprecated__));
> +    };
> 
> это поля structx 264_param_t . Но при -std=c99 получаем:
> libx264.c:165: error: 'x264_param_t' has no member named 'i_bframe_adaptive'
> 
> Как это сейчас правильно реализуется?

Как вариант, можно попробовать что-то типа такого:

-    int         i_bframe_adaptive;
+#define i_bframe_adaptive bframe_adaptive.i
+#define i_bframe_adaptive bframe_adaptive.b
+    union {
+        int         i;
+        int         b __attribute__((__deprecated__));
+    } bframe_adaptive;

-- 
Regards,  Kirill A. Shutemov
 + Belarus, Minsk
 + ALT Linux Team, http://www.altlinux.com/

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 197 bytes --]

  parent reply	other threads:[~2008-09-23 18:22 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-09-23 16:22 Led
2008-09-23 16:26 ` Damir Shayhutdinov
2008-09-23 16:37   ` Led
2008-09-23 18:19   ` Led
2008-09-23 18:22 ` Kirill A. Shutemov [this message]
2008-09-23 18:32   ` Led

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20080923182245.GA11804@localhost.localdomain \
    --to=kirill@shutemov.name \
    --cc=devel@lists.altlinux.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux Team development discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/devel/0 devel/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 devel devel/ http://lore.altlinux.org/devel \
		devel@altlinux.org devel@altlinux.ru devel@lists.altlinux.org devel@lists.altlinux.ru devel@linux.iplabs.ru mandrake-russian@linuxteam.iplabs.ru sisyphus@linuxteam.iplabs.ru
	public-inbox-index devel

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.devel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git