diff mbox

[FFmpeg-devel] removing comma at final enumeration items to fix pedantic warnings

Message ID 71c978a2-a11b-d95b-0588-7eb239a571ce@behrisch.de
State Superseded
Headers show

Commit Message

Michael Behrisch Oct. 19, 2016, 9:11 p.m. UTC
Signed-off-by: Michael Behrisch <oss@behrisch.de>
---
 libavutil/log.h    |  2 +-
 libavutil/pixfmt.h | 12 ++++++------
 2 files changed, 7 insertions(+), 7 deletions(-)

might differ between versions
 };

 #if AV_HAVE_BIGENDIAN
@@ -401,7 +401,7 @@ enum AVColorPrimaries {
     AVCOL_PRI_SMPTEST428_1 = 10, ///< SMPTE ST 428-1 (CIE 1931 XYZ)
     AVCOL_PRI_SMPTE431    = 11, ///< SMPTE ST 431-2 (2011)
     AVCOL_PRI_SMPTE432    = 12, ///< SMPTE ST 432-1 D65 (2010)
-    AVCOL_PRI_NB,               ///< Not part of ABI
+    AVCOL_PRI_NB                ///< Not part of ABI
 };

 /**
@@ -427,7 +427,7 @@ enum AVColorTransferCharacteristic {
     AVCOL_TRC_SMPTEST2084  = 16, ///< SMPTE ST 2084 for 10-, 12-, 14-
and 16-bit systems
     AVCOL_TRC_SMPTEST428_1 = 17, ///< SMPTE ST 428-1
     AVCOL_TRC_ARIB_STD_B67 = 18, ///< ARIB STD-B67, known as "Hybrid
log-gamma"
-    AVCOL_TRC_NB,                ///< Not part of ABI
+    AVCOL_TRC_NB                 ///< Not part of ABI
 };

 /**
@@ -446,7 +446,7 @@ enum AVColorSpace {
     AVCOL_SPC_BT2020_NCL  = 9,  ///< ITU-R BT2020 non-constant
luminance system
     AVCOL_SPC_BT2020_CL   = 10, ///< ITU-R BT2020 constant luminance system
     AVCOL_SPC_SMPTE2085   = 11, ///< SMPTE 2085, Y'D'zD'x
-    AVCOL_SPC_NB,               ///< Not part of ABI
+    AVCOL_SPC_NB                ///< Not part of ABI
 };
 #define AVCOL_SPC_YCGCO AVCOL_SPC_YCOCG

@@ -458,7 +458,7 @@ enum AVColorRange {
     AVCOL_RANGE_UNSPECIFIED = 0,
     AVCOL_RANGE_MPEG        = 1, ///< the normal 219*2^(n-8) "MPEG" YUV
ranges
     AVCOL_RANGE_JPEG        = 2, ///< the normal     2^n-1   "JPEG" YUV
ranges
-    AVCOL_RANGE_NB,              ///< Not part of ABI
+    AVCOL_RANGE_NB               ///< Not part of ABI
 };

 /**
@@ -484,7 +484,7 @@ enum AVChromaLocation {
     AVCHROMA_LOC_TOP         = 4,
     AVCHROMA_LOC_BOTTOMLEFT  = 5,
     AVCHROMA_LOC_BOTTOM      = 6,
-    AVCHROMA_LOC_NB,              ///< Not part of ABI
+    AVCHROMA_LOC_NB               ///< Not part of ABI
 };

 #endif /* AVUTIL_PIXFMT_H */

Comments

Michael Niedermayer Oct. 20, 2016, 1:27 a.m. UTC | #1
On Wed, Oct 19, 2016 at 11:11:21PM +0200, Michael Behrisch wrote:
> Signed-off-by: Michael Behrisch <oss@behrisch.de>
> ---
>  libavutil/log.h    |  2 +-
>  libavutil/pixfmt.h | 12 ++++++------
>  2 files changed, 7 insertions(+), 7 deletions(-)
> 
> diff --git a/libavutil/log.h b/libavutil/log.h
> index 0acc1b9..f0a5738 100644
> --- a/libavutil/log.h
> +++ b/libavutil/log.h
> @@ -44,7 +44,7 @@ typedef enum {
>      AV_CLASS_CATEGORY_DEVICE_AUDIO_INPUT,
>      AV_CLASS_CATEGORY_DEVICE_OUTPUT,
>      AV_CLASS_CATEGORY_DEVICE_INPUT,
> -    AV_CLASS_CATEGORY_NB, ///< not part of ABI/API
> +    AV_CLASS_CATEGORY_NB  ///< not part of ABI/API
>  }AVClassCategory;
> 
>  #define AV_IS_INPUT_DEVICE(category) \
> diff --git a/libavutil/pixfmt.h b/libavutil/pixfmt.h
> index b15c0ef..7a3f68b 100644
> --- a/libavutil/pixfmt.h
> +++ b/libavutil/pixfmt.h
> @@ -306,7 +306,7 @@ enum AVPixelFormat {
> 
>      AV_PIX_FMT_MEDIACODEC, ///< hardware decoding through MediaCodec
> 
> -    AV_PIX_FMT_NB,        ///< number of pixel formats, DO NOT USE THIS
> if you want to link with shared libav* because the number of formats
> might differ between versions
> +    AV_PIX_FMT_NB         ///< number of pixel formats, DO NOT USE THIS
> if you want to link with shared libav* because the number of formats
> might differ between versions
>  };

patch is corrupted by newlines / word wrap

[...]
Muhammad Faiz Oct. 20, 2016, 2:18 a.m. UTC | #2
On 10/20/16, Michael Behrisch <oss@behrisch.de> wrote:
> Signed-off-by: Michael Behrisch <oss@behrisch.de>
> ---
>  libavutil/log.h    |  2 +-
>  libavutil/pixfmt.h | 12 ++++++------
>  2 files changed, 7 insertions(+), 7 deletions(-)

If you have difficulty to send your patch directly (you should use git
send-email, not just copy paste), you may send it as an attachment.

Thank's
Ronald S. Bultje Oct. 20, 2016, 2:38 a.m. UTC | #3
Hi,

On Wed, Oct 19, 2016 at 5:11 PM, Michael Behrisch <oss@behrisch.de> wrote:

> Signed-off-by: Michael Behrisch <oss@behrisch.de>
> ---
>  libavutil/log.h    |  2 +-
>  libavutil/pixfmt.h | 12 ++++++------
>  2 files changed, 7 insertions(+), 7 deletions(-)


FWIW I still have doubts about this.

Ronald
Michael Behrisch Oct. 20, 2016, 6:52 a.m. UTC | #4
Am 20.10.2016 um 04:18 schrieb Muhammad Faiz:
> On 10/20/16, Michael Behrisch <oss@behrisch.de> wrote:
>> Signed-off-by: Michael Behrisch <oss@behrisch.de>
>> ---
>>  libavutil/log.h    |  2 +-
>>  libavutil/pixfmt.h | 12 ++++++------
>>  2 files changed, 7 insertions(+), 7 deletions(-)
> 
> If you have difficulty to send your patch directly (you should use git
> send-email, not just copy paste), you may send it as an attachment.

Sorry about that, still struggling a little with git. I did not know how
to insert the signed off when using send-email.

I hope the new patch (in the separate mail) is fine.

Best regards,
Michael
Nicolas George Oct. 20, 2016, 7:49 a.m. UTC | #5
L'octidi 28 vendémiaire, an CCXXV, Ronald S. Bultje a écrit :
> FWIW I still have doubts about this.

FWIW, I still have more than doubts about this. This comma is entirely
valid. If anything should be changed, it should be to add it where it is
missing, for consistency.

Regards,
Clément Bœsch Oct. 20, 2016, 7:54 a.m. UTC | #6
On Thu, Oct 20, 2016 at 09:49:40AM +0200, Nicolas George wrote:
> L'octidi 28 vendémiaire, an CCXXV, Ronald S. Bultje a écrit :
> > FWIW I still have doubts about this.
> 
> FWIW, I still have more than doubts about this. This comma is entirely
> valid. If anything should be changed, it should be to add it where it is
> missing, for consistency.
> 

it's a _NB entry, there won't be any entry added after those.

also, "2 files changed, 7 insertions(+), 7 deletions(-)"

it's really a trivial and harmless patch.
Nicolas George Oct. 20, 2016, 7:55 a.m. UTC | #7
Le nonidi 29 vendémiaire, an CCXXV, Clement Boesch a écrit :
> it's really a trivial and harmless patch.

Which is not enough to accept it.

I am sure there are better uses of contributors' time than that.

Regards,
Carl Eugen Hoyos Oct. 20, 2016, 7:58 a.m. UTC | #8
2016-10-20 9:55 GMT+02:00 Nicolas George <george@nsup.org>:

> I am sure there are better uses of contributors' time than that.

After many years on this list, I don't think this is a helpful approach.

Carl Eugen
Clément Bœsch Oct. 20, 2016, 8 a.m. UTC | #9
On Thu, Oct 20, 2016 at 09:55:17AM +0200, Nicolas George wrote:
> Le nonidi 29 vendémiaire, an CCXXV, Clement Boesch a écrit :
> > it's really a trivial and harmless patch.
> 
> Which is not enough to accept it.
> 

but the patch is perfectly fine and semantically more correct (it
explicits that it's wrong to add entry afterward).

> I am sure there are better uses of contributors' time than that.
> 

people are free to do whatever they feel like; you're just wasting yours
by bikeshedding about this stuff you could just ignore.
diff mbox

Patch

diff --git a/libavutil/log.h b/libavutil/log.h
index 0acc1b9..f0a5738 100644
--- a/libavutil/log.h
+++ b/libavutil/log.h
@@ -44,7 +44,7 @@  typedef enum {
     AV_CLASS_CATEGORY_DEVICE_AUDIO_INPUT,
     AV_CLASS_CATEGORY_DEVICE_OUTPUT,
     AV_CLASS_CATEGORY_DEVICE_INPUT,
-    AV_CLASS_CATEGORY_NB, ///< not part of ABI/API
+    AV_CLASS_CATEGORY_NB  ///< not part of ABI/API
 }AVClassCategory;

 #define AV_IS_INPUT_DEVICE(category) \
diff --git a/libavutil/pixfmt.h b/libavutil/pixfmt.h
index b15c0ef..7a3f68b 100644
--- a/libavutil/pixfmt.h
+++ b/libavutil/pixfmt.h
@@ -306,7 +306,7 @@  enum AVPixelFormat {

     AV_PIX_FMT_MEDIACODEC, ///< hardware decoding through MediaCodec

-    AV_PIX_FMT_NB,        ///< number of pixel formats, DO NOT USE THIS
if you want to link with shared libav* because the number of formats
might differ between versions
+    AV_PIX_FMT_NB         ///< number of pixel formats, DO NOT USE THIS
if you want to link with shared libav* because the number of formats