Multiple return value as requirements for safety and performance

Ilya Yaroshenko via Digitalmars-d digitalmars-d at puremagic.com
Tue Dec 20 09:15:53 PST 2016


On Tuesday, 20 December 2016 at 17:05:03 UTC, Stefan Koch wrote:
> On Tuesday, 20 December 2016 at 16:57:34 UTC, Ilya Yaroshenko 
> wrote:
>> On Tuesday, 20 December 2016 at 16:34:04 UTC, Walter Bright 
>> wrote:
>>> On 12/20/2016 6:08 AM, Ilya Yaroshenko wrote:
>>>> No, tuples stores either value or pointer. If it stores 
>>>> pointer then it is not
>>>> safe and it is not CTFE.
>>>
>>> You can make it safe by using an array rather than a pointer.
>>
>> Ranges a and b may not be arrays. They just have Range API and 
>> return front by reference.How this can be handled for CTFE, 
>> safe code? Would the solution be fast?
>
> What are you even talking about ?
> Making a Tuple is fine.
> Pointers can also be perfectly safe and CTFEable if you do not

Are they already CTFEable? I have not seen an anounce, sorry


More information about the Digitalmars-d mailing list