Socket
Socket
Sign inDemoInstall

tree-sitter-c-sharp

Package Overview
Dependencies
13
Maintainers
4
Versions
13
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    tree-sitter-c-sharp

C# grammar for tree-sitter


Version published
Weekly downloads
3.5K
increased by43.27%
Maintainers
4
Created
Weekly downloads
 

Readme

Source

tree-sitter-c-sharp

Build Status

C# grammar for tree-sitter

Status

Based on an export of the Roslyn grammar export with various changes in order to:

  • Deal with differences between the parsing technologies
  • Work around some bugs in that grammar
  • Handle #if, #else, #elif, #endif blocks
  • Support syntax highlighting/parsing of fragments
  • Simplify the output tree

Detailed status

Comprehensive support for C# exists with the following exceptions:

C# 7.0
C# 7.1
  • async main method
  • Default literals (as default_expression)
  • Inferred tuple element names
  • Generic type pattern matching
C# 7.2
  • in parameter modifiers
  • ref readonly method returns
  • readonly struct
  • ref struct
  • Non-trailing named arguments
  • _ leading binary and hex literals
  • private protected modifier
  • Conditional ref expressions
C# 7.3
  • stackalloc array initializers
  • unmanaged generic type parameter constraint
  • Attributes attached to auto property backing fields
  • out support for parameters on initializers, constructors etc.
C# 8.0
  • readonly members
  • Default interface methods
  • switch expressions
  • switch property patterns
  • switch tuple patterns
  • static local functions
  • nullable reference types
  • null-forgiving operator

References

Keywords

FAQs

Last updated on 02 Dec 2019

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc