diff options
| author | Brad Lewis <22850972+BradLewis@users.noreply.github.com> | 2025-07-19 15:46:55 -0400 |
|---|---|---|
| committer | Brad Lewis <22850972+BradLewis@users.noreply.github.com> | 2025-07-22 18:48:22 -0400 |
| commit | 4eda03d0564acbbd577edb54183f4443fbdd0e94 (patch) | |
| tree | 14cb81c9595722d407f6b277f4976cfd8b99aabf /src/server/clone.odin | |
| parent | 01dd0ca11f34a58c9470ed377142da4a144631f2 (diff) | |
Add proc calling convention to hover information
Diffstat (limited to 'src/server/clone.odin')
| -rw-r--r-- | src/server/clone.odin | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/server/clone.odin b/src/server/clone.odin index 7baec58..3fdebdb 100644 --- a/src/server/clone.odin +++ b/src/server/clone.odin @@ -300,3 +300,19 @@ clone_comment_group :: proc( ) -> ^ast.Comment_Group { return cast(^ast.Comment_Group)clone_node(node, allocator, unique_strings) } + +clone_calling_convention :: proc( + cc: ast.Proc_Calling_Convention, allocator: mem.Allocator, unique_strings: ^map[string]string, +) -> ast.Proc_Calling_Convention { + if cc == nil { + return nil + } + + switch v in cc { + case string: + return get_index_unique_string(unique_strings, allocator, v) + case ast.Proc_Calling_Convention_Extra: + return v + } + return nil +} |