mirror of
https://github.com/FabInfra/capnproto-dotnetcore_Runtime.git
synced 2025-03-12 23:01:44 +01:00
The TypeDefinition is no longer overloaded for Annotation and Constant nodes, and the generator is happy again.
20 lines
461 B
C#
20 lines
461 B
C#
|
|
namespace CapnpC.Model
|
|
{
|
|
class Constant : IDefinition
|
|
{
|
|
public ulong Id { get; }
|
|
public TypeTag Tag { get => TypeTag.Const; }
|
|
public IHasNestedDefinitions DeclaringElement { get; }
|
|
|
|
public Value Value { get; set; }
|
|
|
|
public Constant(ulong id, IHasNestedDefinitions parent)
|
|
{
|
|
Id = id;
|
|
DeclaringElement = parent;
|
|
parent.NestedDefinitions.Add(this);
|
|
}
|
|
}
|
|
}
|