• Anton Khirnov's avatar
    all: use designated initializers for AVOption.unit · 1e7d2007
    Anton Khirnov authored
    Makes it robust against adding fields before it, which will be useful in
    following commits.
    
    Majority of the patch generated by the following Coccinelle script:
    
    @@
    typedef AVOption;
    identifier arr_name;
    initializer list il;
    initializer list[8] il1;
    expression tail;
    @@
    AVOption arr_name[] = { il, { il1,
    - tail
    + .unit = tail
    }, ...  };
    
    with some manual changes, as the script:
    * has trouble with options defined inside macros
    * sometimes does not handle options under an #else branch
    * sometimes swallows whitespace
    1e7d2007