diff options
| author | Brad Lewis <22850972+BradLewis@users.noreply.github.com> | 2025-08-19 12:19:01 -0400 |
|---|---|---|
| committer | Brad Lewis <22850972+BradLewis@users.noreply.github.com> | 2025-08-19 12:38:25 -0400 |
| commit | 558f690a8d962b658986bc28fa1e5603098674c1 (patch) | |
| tree | eaa3b34ecdb5af1ccaa0f347b8482c4bf0c8f681 /src/server/documentation.odin | |
| parent | 9ffbad23c023a84f568d6079e1181442f5e70500 (diff) | |
Correctly resolve string indexing
Diffstat (limited to 'src/server/documentation.odin')
| -rw-r--r-- | src/server/documentation.odin | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/server/documentation.odin b/src/server/documentation.odin index dc0784d..1cc804d 100644 --- a/src/server/documentation.odin +++ b/src/server/documentation.odin @@ -822,10 +822,15 @@ write_symbol_name :: proc(sb: ^strings.Builder, symbol: Symbol) { } write_symbol_type_information :: proc(sb: ^strings.Builder, ast_context: ^AstContext, symbol: Symbol) -> bool { - show_type_info := - (symbol.type == .Variable || symbol.type == .Field) && !(.Anonymous in symbol.flags) && symbol.type_name != "" + if symbol.type_name == "" { + return false + } + + if symbol.type != .Variable && symbol.type != .Field { + return false + } - if !show_type_info { + if .Anonymous in symbol.flags { return false } |