40 lines · cpp
1// RUN: rm -rf %t2// RUN: %clang_cc1 -std=c++11 -I%S/Inputs/PR27401 -verify %s3// RUN: %clang_cc1 -std=c++11 -fmodules -fmodule-map-file=%S/Inputs/PR27401/module.modulemap -fmodules-cache-path=%t -I%S/Inputs/PR27401 -verify %s4// RUN: %clang_cc1 -std=c++11 -fmodules -fmodule-map-file=%S/Inputs/PR27401/module.modulemap -fmodules-cache-path=%t -I%S/Inputs/PR27401 -verify %s -triple i686-windows5 6#include "a.h"7#define _LIBCPP_VECTOR8template <class, class _Allocator>9class __vector_base {10protected:11 _Allocator __alloc() const;12 __vector_base(_Allocator);13};14 15template <class _Tp, class _Allocator = allocator>16class vector : __vector_base<_Tp, _Allocator> {17public:18 vector() noexcept(is_nothrow_default_constructible<_Allocator>::value);19 vector(const vector &);20 vector(vector &&)21 noexcept(is_nothrow_move_constructible<_Allocator>::value);22};23 24template <class _Tp, class _Allocator>25vector<_Tp, _Allocator>::vector(const vector &__x) : __vector_base<_Tp, _Allocator>(__x.__alloc()) {}26 27 struct CommentOptions {28 vector<char> ParseAllComments;29 CommentOptions() {}30 };31 struct PrintingPolicy {32 PrintingPolicy(CommentOptions LO) : LangOpts(LO) {}33 CommentOptions LangOpts;34 };35 36#include "b.h"37CommentOptions fn1() { return fn1(); }38 39// expected-no-diagnostics40