summaryrefslogtreecommitdiffstats
path: root/source/compiler-core/slang-json-value.cpp
diff options
context:
space:
mode:
authorJay Kwak <82421531+jkwak-work@users.noreply.github.com>2025-05-01 00:14:24 -0700
committerGitHub <noreply@github.com>2025-05-01 00:14:24 -0700
commit15fce7c8f11985be5ac1fdb1f180a30150e9db89 (patch)
treedc801f723860b852a7fb8966de8e8d22bb825723 /source/compiler-core/slang-json-value.cpp
parenta8d7bb9f781fd77080f07bfaab54fbbcf3a3686d (diff)
Smoke test WASM as a part of CI (#6969)
* Simplify build of slang-wasm * Add smoke-test for slang-wasm in ci * Avoid git-clone playground
Diffstat (limited to 'source/compiler-core/slang-json-value.cpp')
-rw-r--r--source/compiler-core/slang-json-value.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/source/compiler-core/slang-json-value.cpp b/source/compiler-core/slang-json-value.cpp
index ae38bd086..56d003737 100644
--- a/source/compiler-core/slang-json-value.cpp
+++ b/source/compiler-core/slang-json-value.cpp
@@ -869,8 +869,8 @@ void JSONContainer::_removeKey(JSONValue& obj, Index globalIndex)
{
auto localBuf = m_objectValues.getBuffer() + range.startIndex;
::memmove(
- localBuf + localIndex,
- localBuf + localIndex + 1,
+ (void*)(localBuf + localIndex),
+ (void*)(localBuf + localIndex + 1),
sizeof(*localBuf) * (range.count - (localIndex + 1)));
}
@@ -925,7 +925,10 @@ template<typename T>
ioList.growToCount(newStartIndex + ioRange.count + 1);
auto buffer = ioList.getBuffer();
- ::memmove(buffer + newStartIndex, buffer + ioRange.startIndex, sizeof(*buffer) * ioRange.count);
+ ::memmove(
+ (void*)(buffer + newStartIndex),
+ (void*)(buffer + ioRange.startIndex),
+ sizeof(*buffer) * ioRange.count);
buffer[newStartIndex + ioRange.count] = value;