summaryrefslogtreecommitdiffstats
path: root/modules/mono/editor/Godot.NET.Sdk/Godot.SourceGenerators.Sample/Generic.cs
Commit message (Collapse)AuthorAgeFilesLines
* Cleanup C# projects, code quality & stylePaul Joannon2024-02-271-1/+1
| | | | | | | | | | | | | | | | | | | | | New rules: - Do not silence CA1805 any more - Limit where we silence CA1707, CA1711, CA1720 - Enforce severity=warning for IDE0040 - Enforce Allman style braces - Enforce naming conventions (IDE1006 is still severity=suggestion) Fixes: - Fix REFL045, CS1572, CS1573 - Suppress CS0618 when generating `InvokeGodotClassMethod` - Fix indent when generating GD_constants.cs - Temporarily silence CS1734 in generated code - Fix a lot of naming rule violations Misc.: - Remove ReSharper comments for RedundantNameQualifier - Remove suppression attributes for RedundantNameQualifier - Remove severity=warnings for CA1716, CA1304 (already included in the level of analysis we run)
* C#: Various fixes to generic scriptsRaul Santos2024-02-191-11/+0
| | | | | | - Report a diagnostic when there are multiple classes that match the script file name in the same script since that will result in a duplicate path key in the bimap and it's not allowed. - Fix InspectorPlugin to handle empty paths in case the project was built with a previous version of Godot that used empty paths for generic scripts. - Add tests for the new diagnostic GD0003.
* C#: Rename `Object` to `GodotObject`Raul Santos2023-01-271-3/+3
|
* C#: Add source generator for properties and exports default valuesIgnacio Roldán Etcheverry2022-08-221-0/+5
| | | | | | | | | | | | | | The editor no longer needs to create temporary instances to get the default values. The initializer values of the exported properties are still evaluated at runtime. For example, in the following example, `GetInitialValue()` will be called when first looks for default values: ``` [Export] int MyValue = GetInitialValue(); ``` Exporting fields with a non-supported type now results in a compiler error rather than a runtime error when the script is used.
* Fix Godot.SourceGenerators for generic classesRaul Santos2021-12-051-0/+16
Fix invalid C# generated by source generators for generic classes and add generic classes to the Sample project for testing.