-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(wip): Add support for C# documents
Currently, this only includes basic support for the TreeSitter grammar, without support for symbols or LSP.
- Loading branch information
1 parent
f53e552
commit 18b8cd2
Showing
14 changed files
with
93 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Submodule tree-sitter-c-sharp
added at
362a8a
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
/* | ||
This file is part of Knut. | ||
SPDX-FileCopyrightText: 2025 Klarälvdalens Datakonsult AB, a KDAB Group company <[email protected]> | ||
SPDX-License-Identifier: GPL-3.0-only | ||
Contact KDAB at <[email protected]> for commercial licensing options. | ||
*/ | ||
|
||
#include "csharpdocument.h" | ||
|
||
#include "codedocument_p.h" | ||
#include "symbol.h" | ||
|
||
namespace { | ||
QList<Core::Symbol *> queryAllSymbols(Core::CodeDocument *const document) | ||
{ | ||
Q_UNUSED(document); | ||
// TODO | ||
return {}; | ||
} | ||
} | ||
|
||
namespace Core { | ||
|
||
CSharpDocument::CSharpDocument(QObject *parent) | ||
: CodeDocument(Type::CSharp, parent) | ||
{ | ||
helper()->querySymbols = queryAllSymbols; | ||
} | ||
|
||
CSharpDocument::~CSharpDocument() = default; | ||
|
||
} // namespace Core |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
/* | ||
This file is part of Knut. | ||
SPDX-FileCopyrightText: 2025 Klarälvdalens Datakonsult AB, a KDAB Group company <[email protected]> | ||
SPDX-License-Identifier: GPL-3.0-only | ||
Contact KDAB at <[email protected]> for commercial licensing options. | ||
*/ | ||
|
||
#pragma once | ||
|
||
#include "codedocument.h" | ||
|
||
namespace Core { | ||
|
||
class CSharpDocument : public CodeDocument | ||
{ | ||
Q_OBJECT | ||
|
||
public: | ||
explicit CSharpDocument(QObject *parent = nullptr); | ||
~CSharpDocument() override; | ||
}; | ||
|
||
} |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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