From f149b4c309bbd780e67e36752b167ad832e3723c Mon Sep 17 00:00:00 2001 From: Janne Kiiskila Date: Mon, 19 Aug 2019 18:54:32 +0300 Subject: [PATCH] IAR / FATFS - Pe029 error IAR compilation fails at `_fs = { 0 };` due to ``` [Error] FATFileSystem.cpp@285,0: [Pe029]: expected an expression ``` Changing that object initializer list instead, as that seems to pass IAR compilation, too. Changed original memset to object initialiser list based on review feedback from Kevin Bracey. --- features/storage/filesystem/fat/FATFileSystem.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/features/storage/filesystem/fat/FATFileSystem.cpp b/features/storage/filesystem/fat/FATFileSystem.cpp index 81d142c8b0..90229131f2 100644 --- a/features/storage/filesystem/fat/FATFileSystem.cpp +++ b/features/storage/filesystem/fat/FATFileSystem.cpp @@ -280,9 +280,8 @@ extern "C" DRESULT disk_ioctl(BYTE pdrv, BYTE cmd, void *buff) // Filesystem implementation (See FATFilySystem.h) FATFileSystem::FATFileSystem(const char *name, BlockDevice *bd) - : FileSystem(name), _id(-1) + : FileSystem(name), _fs(), _id(-1) { - _fs = { 0 }; if (bd) { mount(bd); }