Implement DocumentationProvider#24
Merged
lerno merged 2 commits intoc3lang:masterfrom Apr 15, 2025
lyranie:master
Merged
Conversation
- added C3DocumentationProvider for hover docs for function declarations and variable declarations
lerno
requested changes
Apr 10, 2025
| println("---") | ||
|
|
||
| if (element is C3FuncDef) return generateFuncDefDoc(element) | ||
| if (element is C3LocalDeclAfterType) return generateVarDeclDoc(element) |
Contributor
There was a problem hiding this comment.
This is not picking up the globals, could that be made to work?
Contributor
Author
There was a problem hiding this comment.
as of now i don't see a way to detect top level elements as it win't even recognize the module declaration or imports. the other changes are finished i just can't get around to getting this to work
- added documentation for const declarations - fixed function docs not displaying correctly in default module - added highlighting for doc comments - added basic completion for doc comments - added check for existing function parameters for doc comments - updated regex for pattern matching in doc comments
Contributor
|
The free text before the params would be nice to add later. Thank you for this! |
Contributor
|
This breaks: <*
Pop a value who's type is known. If the type is incorrect, this
will still pop the element.
@param $Type : "The type we assume the value has"
@return "The last value as the type given"
@return? TYPE_MISMATCH, NO_MORE_ELEMENT
*> |
Contributor
|
This also fails: <*
Push an element to the front of the list.
@param value : "The value to push to the list"
*>
macro void AnyList.push_front(&self, value)
{
self.insert_at(0, value);
} |
Contributor
Author
this fails because i forgot to check for macros. it currently only checks for functions |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Variables

Functions
