• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

SamboyCoding / Cpp2IL / 15172218253

21 May 2025 08:44PM UTC coverage: 34.282% (+0.2%) from 34.047%
15172218253

Pull #462

github

web-flow
Merge 9de1a7abb into 5807d2b6c
Pull Request #462: Support overriding member types

1801 of 6650 branches covered (27.08%)

Branch coverage included in aggregate %.

127 of 226 new or added lines in 35 files covered. (56.19%)

22 existing lines in 6 files now uncovered.

4199 of 10852 relevant lines covered (38.69%)

186271.78 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

69.23
/Cpp2IL.Core/Model/Contexts/InjectedMethodAnalysisContext.cs
1
using System.Collections.Generic;
2
using System.Reflection;
3

4
namespace Cpp2IL.Core.Model.Contexts;
5

6
public class InjectedMethodAnalysisContext : MethodAnalysisContext
7
{
8
    public override ulong UnderlyingPointer => 0;
×
9

10
    public override string DefaultName { get; }
3✔
11

12
    public override TypeAnalysisContext DefaultReturnType { get; }
3✔
13

NEW
14
    public override MethodAttributes DefaultAttributes { get; }
×
15

NEW
16
    public override MethodImplAttributes DefaultImplAttributes { get; }
×
17

18
    protected override bool IsInjected => true;
×
19

20
    protected override int CustomAttributeIndex => -1;
×
21

22
    public override IEnumerable<MethodAnalysisContext> Overrides => OverridesList;
×
23
    public List<MethodAnalysisContext> OverridesList { get; } = [];
252✔
24

25
    public InjectedMethodAnalysisContext(
26
        TypeAnalysisContext parent,
27
        string name,
28
        TypeAnalysisContext returnType,
29
        MethodAttributes attributes,
30
        TypeAnalysisContext[] injectedParameterTypes,
31
        string[]? injectedParameterNames = null,
32
        ParameterAttributes[]? injectedParameterAttributes = null,
33
        MethodImplAttributes defaultImplAttributes = MethodImplAttributes.Managed) : base(null, parent)
252✔
34
    {
35
        DefaultName = name;
252✔
36
        DefaultReturnType = returnType;
252✔
37
        DefaultAttributes = attributes;
252✔
38

39
        for (var i = 0; i < injectedParameterTypes.Length; i++)
672✔
40
        {
41
            var injectedParameterType = injectedParameterTypes[i];
84✔
42
            var injectedParameterName = injectedParameterNames?[i];
84!
43
            var injectedParameterAttribute = injectedParameterAttributes?[i] ?? ParameterAttributes.None;
84!
44

45
            Parameters.Add(new InjectedParameterAnalysisContext(injectedParameterName, injectedParameterType, injectedParameterAttribute, i, this));
84✔
46
        }
47

48
        DefaultImplAttributes = defaultImplAttributes;
252✔
49
    }
252✔
50
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc