summaryrefslogtreecommitdiffstats
path: root/libcxx/test/utilities/memory/unique.ptr/unique.ptr.dltr/unique.ptr.dltr.dflt1/incomplete.fail.cpp
blob: 6fcb94c56375870d44cd862a52838e8cdf33093a (plain)
1
//===----------------------------------------------------------------------===//
//
//                     The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//

// <memory>

// default_delete

// Test that default_delete<T[]>'s operator() requires a complete type

#include <memory>
#include <cassert>

struct A;

int main()
{
    std::default_delete<A[]> d;
    A* p = 0;
    d(p);
}
OpenPOWER on IntegriCloud