summaryrefslogtreecommitdiffstats
path: root/source/compiler-core
diff options
context:
space:
mode:
authorYong He <yonghe@outlook.com>2025-07-01 14:02:35 -0700
committerGitHub <noreply@github.com>2025-07-01 21:02:35 +0000
commiteb7f3357a1c316bad51cf0bfaea27d81a93f96ad (patch)
tree448a2a07d36ef11b66ef79522086765efc5e708b /source/compiler-core
parent5120c1cd072548654c9ce79fa85426a5e48736c4 (diff)
Misc language server improvements. (#7569)
* Misc language server improvements. * Fix. * Fix decl path printing for existential lookup. * More existential decl path fix. * Polish. * Fix test.
Diffstat (limited to 'source/compiler-core')
-rw-r--r--source/compiler-core/slang-json-value.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/compiler-core/slang-json-value.cpp b/source/compiler-core/slang-json-value.cpp
index 56d003737..e2e95a968 100644
--- a/source/compiler-core/slang-json-value.cpp
+++ b/source/compiler-core/slang-json-value.cpp
@@ -655,6 +655,9 @@ bool JSONContainer::asBool(const JSONValue& value)
return asInteger(value) != 0;
case JSONValue::Type::FloatLexeme:
return asFloat(value) != 0.0;
+ case JSONValue::Type::StringLexeme:
+ return getTransientString(value).caseInsensitiveEquals(toSlice("true")) ||
+ getTransientString(value).caseInsensitiveEquals(toSlice("1"));
default:
return value.asBool();
}