http://d.puremagic.com/issues/show_bug.cgi?id=4406



--- Comment #1 from Steven Schveighoffer <schvei...@yahoo.com> 2010-06-29 
07:40:36 PDT ---
Ops is a type, I don't think that will compile.

I'd say a more complex solution is needed:

        final void get(T...)( T _ops )
        {
            static assert( T.length );

            static if( isImplicitlyConvertible!(T[0], long) )
            {
                alias TypeTuple!(T[1 .. $]) Ops;
                enum timedWait = true;
                assert( _ops[0] >= 0 );
                long period = _ops[0];
                Ops ops = _ops[1 .. $];  // Line 609
            }
            else
            {
                 alias TypeTuple!(T) Ops;
                 enum timedWait = false;
                 alias _ops ops; // not sure if this works
            }

If the alias doesn't work, you may have to do something with the function
signature.  I'm not sure how assigning _ops to ops will work, it may invoke
some unnecessary ctors/dtors.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to