]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
sd-json: also skip assert_cc in VS Code parser 40676/head
authorLuca Boccassi <luca.boccassi@gmail.com>
Fri, 13 Feb 2026 19:34:09 +0000 (19:34 +0000)
committerLuca Boccassi <luca.boccassi@gmail.com>
Fri, 13 Feb 2026 19:34:45 +0000 (19:34 +0000)
For some reason the VS Code parser thinks sd_json_variant is still 48 bytes,
so skip the assert when running in that parser too

Follow-up for 337712e777bff389f53e26d5b378d2ceba7d98a8

src/libsystemd/sd-json/sd-json.c

index d9e6b24b8f1e1d506e7644339a63e639e0e05043..c0067cb40b4df0cac226147245b0b83ad6a9d417 100644 (file)
@@ -132,7 +132,7 @@ struct sd_json_variant {
 
 /* Let's make sure this structure isn't increased in size accidentally. This check is only for our most relevant arch
  * (x86-64). */
-#if defined(__x86_64__) && __SIZEOF_POINTER__ == 8
+#if defined(__x86_64__) && __SIZEOF_POINTER__ == 8 && !defined(__EDG__)
 assert_cc(sizeof(sd_json_variant) == 40U);
 assert_cc(INLINE_STRING_MAX == 7U);
 #endif