Code review comment for lp:~alan-griffiths/mir/add-mir_surface_spec_attach

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Oops, just noticed: You're using the MirPlacement enum to hold potentially multiple values:
   void mir_surface_spec_set_placement(MirSurfaceSpec* spec, MirPlacement mode, MirRectangle* hint);

Compilers will start throwing up warnings and errors as soon as you pass in more than one value for 'mode'. So MirPlacement needs splitting into two types as we do for all other packed types:
    typedef enum MirPlacementBits ...
    typedef unsigned int MirPlacement;

Also missing a test case that will demonstrate the compiler error.

review: Needs Fixing

« Back to merge proposal