On 04/25/2018 11:35 PM, Phil Bouchard wrote:
template<int N>
void foo(int (&array)[N]) ?

Since I just started testing C++98 as of last week, I haven't yet had a chance to test templates thoroughly. So this one is buggy and I'll have to fix it.

I already fixed the problem. The following code:

template <typename T, size_t S>
    void foo(T (&array)[S])
    {
        cout << __PRETTY_FUNCTION__ << endl;
    }

int main()
{
    int array[10];

    foo(array);

    return 0;
}

Now correctly outputs:
void foo(const boost::node_proxy &, boost::root_array<std::vector<int>, 10> (&))


Regards,
-Phil

_______________________________________________
Development mailing list
Development@qt-project.org
http://lists.qt-project.org/mailman/listinfo/development

Reply via email to