Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
kekyo committed Apr 30, 2024
1 parent 3b4e673 commit b2e025f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 2 additions & 2 deletions chibild/chibild.core/Generating/CodeGenerator_Consumer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ private FieldDefinition CreatePlaceholderField() =>
private MethodDefinition CreatePlaceholderMethod() =>
CecilUtilities.CreatePlaceholderMethod(this.placeholderIndex++);

private TypeDefinition CreatePlaceholderInstruction() =>
CecilUtilities.CreatePlaceholderType(this.placeholderIndex++);
private Instruction CreatePlaceholderInstruction() =>
CecilUtilities.CreatePlaceholderInstruction(this.placeholderIndex++);

//////////////////////////////////////////////////////////////

Expand Down
3 changes: 3 additions & 0 deletions chibild/chibild.core/Internal/CecilUtilities.cs
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,9 @@ public static MethodDefinition CreatePlaceholderMethod(int postfix) =>
MethodAttributes.Private | MethodAttributes.Abstract | MethodAttributes.Final,
CreatePlaceholderType(postfix));

public static Instruction CreatePlaceholderInstruction(int postfix) =>
Instruction.Create(OpCodes.Ldc_I4, postfix);

public static bool IsValidCAbiParameter(
MethodReference method, string[] parameterTypeNames) =>
method.CallingConvention switch
Expand Down

0 comments on commit b2e025f

Please sign in to comment.