Skip to content

Commit

Permalink
preserve public API
Browse files Browse the repository at this point in the history
  • Loading branch information
Luis Rivera committed Feb 28, 2025
1 parent 1a22533 commit ed2bb46
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
6 changes: 5 additions & 1 deletion src/Engine/ProtoAssociative/CodeGen.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5910,7 +5910,7 @@ private void EmitGroupExpressionNode(AssociativeNode node, ref ProtoCore.Type in
}
}

protected override void EmitReturnNull(Guid? guid = null)
protected override void EmitReturnNull(Guid? guid)
{
int startpc = pc;

Expand All @@ -5936,6 +5936,10 @@ protected override void EmitReturnNull(Guid? guid = null)

PushGraphNode(retNode);
}
protected override void EmitReturnNull()
{
EmitReturnNull(null);
}

private ProtoCore.Type BuildArgumentTypeFromVarDeclNode(VarDeclNode argNode, GraphNode graphNode = null)
{
Expand Down
3 changes: 2 additions & 1 deletion src/Engine/ProtoCore/CodeGen.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2363,7 +2363,8 @@ protected bool InsideFunction()

// used to manully emit "return = null" instruction if a function or language block does not have a return statement
// there is update code involved in associativen code gen, so it is not implemented here
protected abstract void EmitReturnNull(Guid? guid = null);
protected abstract void EmitReturnNull(Guid? guid);
protected abstract void EmitReturnNull();

protected abstract void DfsTraverse(Node node, ref ProtoCore.Type inferedType, bool isBooleanOp = false, ProtoCore.AssociativeGraph.GraphNode graphNode = null,
ProtoCore.CompilerDefinitions.SubCompilePass subPass = ProtoCore.CompilerDefinitions.SubCompilePass.None, ProtoCore.AST.Node parentNode = null);
Expand Down
5 changes: 5 additions & 0 deletions src/Engine/ProtoImperative/CodeGen.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2549,6 +2549,11 @@ protected override void EmitReturnNull(Guid? guid = null)
EmitReturnToRegister();
}

protected override void EmitReturnNull()
{
EmitReturnNull(null);
}

protected void EmitGropuExpressionNode(ImperativeNode node, ref ProtoCore.Type inferedType)
{
GroupExpressionNode group = node as GroupExpressionNode;
Expand Down

0 comments on commit ed2bb46

Please sign in to comment.