Hi

Yes, please no more global constants with names that are shortened beyond all recognition.

On 7/9/24 18:59, Kamil Tekiela wrote:
Boolean is a much more confusing value here. A bit mask is ok, but I would
prefer a better solution. Maybe a simple value object?


If it's "simple" then it would also be unwieldy to use. To me the obvious modern alternative would be a list of enum cases that represent the differences, with an empty array meaning no differences. The function should probably be renamed 'imagediff()' or similar then.

    namespace Gd;

    enum ImageDifference {
        case Height;
        case Width;
        case AlphaChannel; // or: case Transparency
        case Interlacing;
        // ...
    }

Best regards
Tim Düsterhus

Reply via email to