private Operand ConvertToOperand(BlockBuilder currentBlock, Value value, DataType type)
        {
            if (value is Operand operand)
            {
                return(operand);
            }
            var tempVariable = graph.Let(type.AssertResolved());

            currentBlock.AddAssignment(tempVariable.Reference, value, value.Span);
            return(tempVariable.Reference);
        }