Releases: ByronMayne/SourceGenerator.Foundations
Releases · ByronMayne/SourceGenerator.Foundations
2.0.8
What's Changed
- Fixed the compiler error due to using the environment by @ByronMayne in #33
Full Changelog: 2.0.7...2.0.8
2.0.7
What's Changed
- Feature to turn off emitting ModuleInitializerAttribute when bringing your own polyfills by @scooter12 in #26
- Typo fixes from your friendly Grammatik-Enthusiast by @scooter12 in #28
- Added method for launching a debugger during type initialization by @ByronMayne in #31
New Contributors
- @scooter12 made their first contribution in #26
Full Changelog: 2.0.6...2.0.7
2.0.6
What's Changed
- Publishing Source.Generator.Foundations.Contracts project by @ByronMayne in #25
Full Changelog: 2.0.5...2.0.6
2.0.5
What's Changed
- Fixed a bunch of nullable warnings by @ByronMayne in #19
- Added support for unit testing the SGF Source Generators by @ByronMayne in #20
- Fixed the CI/CD being unable to publish build due to locked dlls by @ByronMayne in #22
- Fixed the compiler error for using min version of the
LangVersion
when you you uselatest
by @ByronMayne in #23
Full Changelog: 2.0.4...2.0.5
2.0.4
Bug Fixes
- Fixed a generator crash that could happen when trying to load a reference only assembly
2.0.3
- Removed the auto reference to
Microsoft.CodeAnalysis.CSharp
version4.3.1
that was being auto added to all projects. - Added a new icon for the nuget package (thank you flaticon.com)
2.0.2
#15 Added Code Analyzers for common mistakes
This release only contains new static code analyses for checking for common mistakes when using Source Generator Foundations. This include checking the following
GeneratorAttribute
is not applied toIncrementalGenerator
types.SgfGeneratorAttribute
is applied to allIncrementalGenerator
types.- All
IncrementalGenerators
must have a default constructor
What's Changed
- Added Code Analyzer for common mistakes by @ByronMayne in #15
Full Changelog: 2.0.1...2.0.2
2.0.1
Merge branch 'feature/hoist-pattern'
2.0.0
With new release I have changed the implementation of the source generator. You now need to apply the [SgsGenerator]
attribute to your class and add a constructor.
namespace Example
{
// IncrementalGenerator, is a generated type from `SourceGenerator.Foundations'
[SgfGenerator]
public class ExampleSourceGenerator : IncrementalGenerator
{
// Constructor can only take two arguments in this order
public ExampleSourceGenerator(
IGeneratorEnvironment generatorEnvironment,
ILogger logger) : base("ExampleSourceGenerator",
generatorPlatform, logger)
{
}
// SgfInitializationContext is a wrapper around IncrementalGeneratorInitializationContext
protected override void OnInitialize(SgfInitializationContext context)
{
// Attaches Visual Studio debugger without prompt
AttachDebugger();
// Writes output to Visual Studios output window
WriteLine("Hello World");
}
}
}
1.5.3
- Added warning disables around 'do not use apis'