diff options
| author | Yong He <yonghe@outlook.com> | 2023-08-04 15:47:39 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-08-04 15:47:39 -0700 |
| commit | a2d90fb275962da84611160f8ddd74d934a68dbd (patch) | |
| tree | 066084537b9f4fe1f367de100ed6638a88a028c1 /source/slang/slang-serialize-types.cpp | |
| parent | 17da4f0dec2b86ba3a4bdaf8a2ae112047d23623 (diff) | |
Redesign `DeclRef` and systematic `Val` deduplication (#3049)
* Redesign DeclRef + Deduplicate Val.
* Update project files
* Fix warning.
* Fix.
* Fix.
* Remove `Val::_equalsImplOverride`.
* Rmove `Val::_getHashCodeOverride`.
* Remove `semanticVisitor` param from `resolve`.
* Cleanups.
---------
Co-authored-by: Yong He <yhe@nvidia.com>
Diffstat (limited to 'source/slang/slang-serialize-types.cpp')
| -rw-r--r-- | source/slang/slang-serialize-types.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/slang/slang-serialize-types.cpp b/source/slang/slang-serialize-types.cpp index 6c4512b1d..a091a2850 100644 --- a/source/slang/slang-serialize-types.cpp +++ b/source/slang/slang-serialize-types.cpp @@ -48,7 +48,8 @@ struct ByteReader const int numPrefixBytes = encodeUnicodePointToUTF8(len, prefixBytes); const Index baseIndex = stringTable.getCount(); - stringTable.setCount(baseIndex + numPrefixBytes + len); + auto newCount = baseIndex + numPrefixBytes + len; + stringTable.growToCount(newCount); char* dst = stringTable.begin() + baseIndex; |
