blobify icon indicating copy to clipboard operation
blobify copied to clipboard

Unable to Use C Style Arrays

Open CuriousTommy opened this issue 5 years ago • 1 comments

Hello, I am currently playing around with blobify and I noticed that using a C arrays causes errors to appear (error.log). Here is an example below:

struct headerSFAT {
    char indentifier[4];
    uint16_t length;
    uint16_t byteOrder;
    uint32_t fileSize;
    uint32_t dataOffset;
    uint16_t versionNumber;
    uint16_t reserved;
};

I was wondering if this is normal or not?

CuriousTommy avatar Jul 06 '20 02:07 CuriousTommy

If there was a reason not to support C-array members, I can't remember it anymore.

As you probably noticed, std::array members are supported, since they are special-cased in load.hpp. A similar check could be added for C-style arrays.

neobrain avatar Jul 22 '20 12:07 neobrain