Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
158 changes: 158 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,158 @@

[*]
charset = utf-8-bom
end_of_line = crlf
trim_trailing_whitespace = false
insert_final_newline = false
indent_style = space
indent_size = 2

# Microsoft .NET properties
csharp_new_line_before_catch = false
csharp_new_line_before_else = false
csharp_new_line_before_finally = false
csharp_new_line_before_members_in_object_initializers = false
csharp_new_line_before_open_brace = none
csharp_preferred_modifier_order = public, protected, async, private, file, new, internal, abstract, virtual, static, override, sealed, extern, unsafe, volatile, required, readonly:suggestion
csharp_style_prefer_utf8_string_literals = true:suggestion
csharp_style_var_elsewhere = true:suggestion
csharp_style_var_for_built_in_types = true:suggestion
csharp_style_var_when_type_is_apparent = true:suggestion
dotnet_naming_rule.unity_serialized_field_rule.import_to_resharper = True
dotnet_naming_rule.unity_serialized_field_rule.resharper_description = Unity serialized field
dotnet_naming_rule.unity_serialized_field_rule.resharper_guid = 5f0fdb63-c892-4d2c-9324-15c80b22a7ef
dotnet_naming_rule.unity_serialized_field_rule.severity = warning
dotnet_naming_rule.unity_serialized_field_rule.style = lower_camel_case_style
dotnet_naming_rule.unity_serialized_field_rule.symbols = unity_serialized_field_symbols
dotnet_naming_style.lower_camel_case_style.capitalization = camel_case
dotnet_naming_symbols.unity_serialized_field_symbols.applicable_accessibilities = *
dotnet_naming_symbols.unity_serialized_field_symbols.applicable_kinds =
dotnet_naming_symbols.unity_serialized_field_symbols.resharper_applicable_kinds = unity_serialised_field
dotnet_naming_symbols.unity_serialized_field_symbols.resharper_required_modifiers = instance
dotnet_style_parentheses_in_arithmetic_binary_operators = never_if_unnecessary:none
dotnet_style_parentheses_in_other_binary_operators = always_for_clarity:none
dotnet_style_parentheses_in_relational_binary_operators = never_if_unnecessary:none
dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion
dotnet_style_predefined_type_for_member_access = true:suggestion
dotnet_style_qualification_for_event = false:suggestion
dotnet_style_qualification_for_field = false:suggestion
dotnet_style_qualification_for_method = false:suggestion
dotnet_style_qualification_for_property = false:suggestion
dotnet_style_require_accessibility_modifiers = for_non_interface_members:suggestion

# ReSharper properties
resharper_align_multiline_extends_list = true
resharper_align_multiline_parameter = true
resharper_align_multiline_type_parameter_constraints = true
resharper_align_multiline_type_parameter_list = true
resharper_arguments_skip_single = true
resharper_blank_lines_after_block_statements = 0
resharper_blank_lines_after_control_transfer_statements = 1
resharper_blank_lines_after_start_comment = 0
resharper_blank_lines_after_using_list = 0
resharper_blank_lines_around_property = 0
resharper_blank_lines_around_single_line_type = 0
resharper_braces_for_for = required
resharper_braces_for_foreach = required
resharper_braces_for_ifelse = not_required
resharper_braces_for_using = not_required
resharper_braces_for_while = required
resharper_braces_redundant = false
resharper_csharp_blank_lines_around_invocable = 0
resharper_csharp_blank_lines_around_namespace = 0
resharper_csharp_blank_lines_inside_region = 0
resharper_csharp_continuous_indent_multiplier = 2
resharper_csharp_empty_block_style = together_same_line
resharper_csharp_indent_size = 2
resharper_csharp_keep_blank_lines_in_declarations = 100
resharper_csharp_max_line_length = 301
resharper_csharp_remove_blank_lines_near_braces_in_code = false
resharper_csharp_remove_blank_lines_near_braces_in_declarations = false
resharper_csharp_tab_width = 2
resharper_csharp_wrap_ternary_expr_style = wrap_if_long
resharper_formatter_off_tag = @formatter:off
resharper_formatter_on_tag = @formatter:on
resharper_formatter_tags_enabled = true
resharper_indent_preprocessor_region = do_not_change
resharper_instance_members_qualify_declared_in =
resharper_local_function_body = expression_body
resharper_method_or_operator_body = expression_body
resharper_parentheses_redundancy_style = remove
resharper_place_accessorholder_attribute_on_same_line = false
resharper_place_expr_accessor_on_single_line = true
resharper_place_expr_property_on_single_line = true
resharper_place_simple_anonymousmethod_on_single_line = false
resharper_place_simple_embedded_statement_on_same_line = true
resharper_place_simple_initializer_on_single_line = false
resharper_place_simple_property_pattern_on_single_line = false
resharper_place_single_method_argument_lambda_on_same_line = false
resharper_show_autodetect_configure_formatting_tip = false
resharper_use_indent_from_vs = false
resharper_wrap_array_initializer_style = chop_always
resharper_wrap_object_and_collection_initializer_style = chop_always
resharper_wrap_property_pattern = chop_always
resharper_xmldoc_indent_size = 2
resharper_xmldoc_tab_width = 2

# ReSharper inspection severities
resharper_arrange_redundant_parentheses_highlighting = hint
resharper_arrange_this_qualifier_highlighting = hint
resharper_arrange_type_member_modifiers_highlighting = hint
resharper_arrange_type_modifiers_highlighting = hint
resharper_built_in_type_reference_style_for_member_access_highlighting = hint
resharper_built_in_type_reference_style_highlighting = hint
resharper_mvc_action_not_resolved_highlighting = warning
resharper_mvc_area_not_resolved_highlighting = warning
resharper_mvc_controller_not_resolved_highlighting = warning
resharper_mvc_masterpage_not_resolved_highlighting = warning
resharper_mvc_partial_view_not_resolved_highlighting = warning
resharper_mvc_template_not_resolved_highlighting = warning
resharper_mvc_view_component_not_resolved_highlighting = warning
resharper_mvc_view_component_view_not_resolved_highlighting = warning
resharper_mvc_view_not_resolved_highlighting = warning
resharper_razor_assembly_not_resolved_highlighting = warning
resharper_redundant_base_qualifier_highlighting = warning
resharper_suggest_var_or_type_built_in_types_highlighting = hint
resharper_suggest_var_or_type_elsewhere_highlighting = hint
resharper_suggest_var_or_type_simple_types_highlighting = hint
resharper_web_config_module_not_resolved_highlighting = warning
resharper_web_config_type_not_resolved_highlighting = warning
resharper_web_config_wrong_module_highlighting = warning

[*.cs]
indent_style = space
indent_size = 2
tab_width = 2

[*.resx]
indent_style = space
indent_size = 4

[{*.overridetasks,*.targets,*.tasks}]
indent_style = space
indent_size = 4

[{*.androidproj,*.ccproj,*.csproj}]
indent_style = space
indent_size = 4

[{*.har,*.jsb2,*.jsb3,*.json,*.jsonc,*.postman_collection,*.postman_collection.json,*.postman_environment,*.postman_environment.json,*.sonarlint/*.json,.babelrc,.eslintrc,.prettierrc,.stylelintrc,.ws-context,connectedMode.json,jest.config}]
indent_style = space
indent_size = 2

[{*.mustache}]
indent_style = space
indent_size = 2

[{*.markdown,*.md}]
indent_style = space
indent_size = 4

[{*.http,*.rest}]
indent_style = space
indent_size = 4

[*.{appxmanifest,asax,ascx,aspx,axaml,blockshader,build,c,c++,c++m,cc,ccm,cginc,compute,cp,cpp,cppm,cshtml,cu,cuh,cxx,cxxm,dtd,fs,fsi,fsscript,fsx,fx,fxh,h,h++,hh,hlsl,hlsli,hlslinc,hp,hpp,hxx,icc,inc,inl,ino,ipp,ixx,master,ml,mli,mpp,mq4,mq5,mqh,mxx,nuspec,paml,razor,resw,resx,shader,shaderFoundry,skin,tcc,tpp,urtshader,usf,ush,uxml,vb,xaml,xamlx,xoml,xsd}]
indent_style = space
indent_size = 4
tab_width = 4
6 changes: 6 additions & 0 deletions .idea/.idea.SourceGenerators/.idea/templateLanguages.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Linq;
using System.Collections.Immutable;
using Microsoft.CodeAnalysis;
using Retro.FastInject.Annotations;
using Retro.FastInject.Comparers;
Expand Down Expand Up @@ -143,10 +141,7 @@ SpecialType.System_Nullable_T or
}

private static IEnumerable<ServiceDeclaration> GetFactoryServices(IMethodSymbol methodSymbol) {
var factoryAttribute = methodSymbol.GetAttributes()
.Select(a => a.TryGetFactoryOverview(out var info) ? info : null)
.FirstOrDefault();
if (factoryAttribute == null) {
if (!methodSymbol.TryGetFactoryOverview(out var factoryAttribute)) {
return [];
}

Expand Down
Loading
Loading