)]}'
{
  "commit": "6469b94304e5c6e521054a654d3172f47b2d0019",
  "tree": "fd24144305b372f3d6259ab5bbcc0e33cea76a00",
  "parents": [
    "7b1ab5b27586a3b297aac336d6a97873b11d4078"
  ],
  "author": {
    "name": "Bartosz Taudul",
    "email": "wolf.pld@gmail.com",
    "time": "Fri Oct 02 19:12:53 2020 +0200"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Fri Oct 02 19:12:53 2020 +0200"
  },
  "message": "Silence memset warning. (#3505)\n\nCompiling the code as-is results in the following warning:\r\n\r\n--\u003e8--\r\nimgui_freetype.cpp:341:72: warning: ‘void* memset(void*, int, size_t)’\r\n        clearing an object of type ‘struct ImFontBuildSrcDataFT’ with no\r\n        trivial copy-assignment; use assignment or value-initialization\r\n        instead [-Wclass-memaccess]\r\n  341 |     memset(src_tmp_array.Data, 0, (size_t)src_tmp_array.size_in_bytes());\r\n      |                                                                        ^\r\nimgui_freetype.cpp:302:8: note: ‘struct ImFontBuildSrcDataFT’ declared here\r\n  302 | struct ImFontBuildSrcDataFT\r\n      |        ^~~~~~~~~~~~~~~~~~~~\r\n--8\u003c--\r\n\r\nThis is caused by presence of ImVector\u003c\u003e directly in ImFontBuildSrcDataFT data\r\nstructure, as well as in the child ImBitVector. Since ImVector\u003c\u003e has a\r\nconstructor, the compiler infers that initialization by memset is not valid.\r\nSuch initialization is not a bug, however, as the default ImVector\u003c\u003e ctor just\r\nsets the structure data members to 0, which is exactly what the memset does.\r\n\r\nCasting the data structure address to void* pointer silences this warning.",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "3d62dc4b6b313333b76bbece90de1339ecb34a50",
      "old_mode": 33188,
      "old_path": "misc/freetype/imgui_freetype.cpp",
      "new_id": "412411a947632672d7503615669835e7cbeaa4b8",
      "new_mode": 33188,
      "new_path": "misc/freetype/imgui_freetype.cpp"
    }
  ]
}
