FunctionDefinition
using CLanguage.Compiler;
using System;
using System.Collections.Generic;
using System.Runtime.CompilerServices;
namespace CLanguage.Syntax
{
[System.Runtime.CompilerServices.NullableContext(1)]
[System.Runtime.CompilerServices.Nullable(0)]
public class FunctionDefinition : Statement
{
public DeclarationSpecifiers Specifiers { get; set; }
public Declarator Declarator { get; set; }
[System.Runtime.CompilerServices.Nullable(new byte[] {
2,
1
})]
[field: System.Runtime.CompilerServices.Nullable(new byte[] {
2,
1
})]
public List<Declaration> ParameterDeclarations {
[return: System.Runtime.CompilerServices.Nullable(new byte[] {
2,
1
})]
get;
[param: System.Runtime.CompilerServices.Nullable(new byte[] {
2,
1
})]
set;
}
public Block Body { get; set; }
public override bool AlwaysReturns => false;
public FunctionDefinition(DeclarationSpecifiers specifiers, Declarator declarator, [System.Runtime.CompilerServices.Nullable(new byte[] {
2,
1
})] List<Declaration> parameterDeclarations, Block body)
{
if (specifiers == null)
throw new ArgumentNullException("specifiers");
Specifiers = specifiers;
if (declarator == null)
throw new ArgumentNullException("declarator");
Declarator = declarator;
ParameterDeclarations = parameterDeclarations;
if (body == null)
throw new ArgumentNullException("body");
Body = body;
}
protected override void DoEmit(EmitContext ec)
{
}
}
}