EnumFastToStringDotNet

Enum converter

Automatically generates a faster enum to string conversion method

This is a Visual Studio C# source generator for automatically generating enum extension methods that implement a switch expression based ToString method. Why? The default enum ToString method implements a binary search which is great for large lists but becomes time and memory inefficient for a just a few items when compared to a switch expression.

GitHub

31 stars
3 watching
2 forks
Language: C#
last commit: over 4 years ago
Linked from 1 awesome list

csharpcsharp-sourcegeneratordotnetroslyn

Backlinks from these awesome lists:

Related projects:

RepositoryDescriptionStars
engrajabi/enum.source.generatorA C# source generator that creates an enumeration class from an enum type without using reflection.181
ashenblade/enumclassA source generator that creates type-safe classes inspired by Kotlin's enum class4
ceiridge/betterenumsImproves C# enum usability and performance by adding extension methods and attributes.39
tylerbrinkley/enums.netA type-safe enum utility library with high-performance extension methods and attributes management1,750
credfeto/credfeto-enum-source-generationA C# source generator that creates performance-enhanced enum lookups by generating code from existing enums.22
hamedfathi/enumerationclassgeneratorA C# source generator tool to create enumeration classes from enum types with additional features and customization options.16
leoformaggi/enum-utilities-generatorA tool that generates helper classes to map enums and their description attributes at compile-time.23
ardalis/smartenumA type-safe alternative to C# enums that supports various serialization and ORM frameworks.2,215
musictopia2/fastenumgeneratorA utility tool for generating enumerations based on music theory1
aviationexam/json-converter-source-generatorGenerates JSON converters for polymorphic data types with discriminator properties5
betwixt-labs/dot-env-generatorA source generator that transforms environment variables into constants in C# code34
therocode/smartenumA header file providing macros to simplify the declaration and use of enums in C++ with automatic string conversion and iteration support.62
dotnet/roslynProvides a compiler and code analysis API for C# and Visual Basic languages19,145
burgyn/mmlib.tostringAutomatically generates a ToString method for classes with a custom attribute18
nyrest/fastgenericnewA fast alternative to Activator.CreateInstance for creating objects in .NET.244