summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaCXX/member-pointer-ms.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Add missing test coverage for an inheritance model attrib merge diag.Nico Weber2016-09-101-0/+8
| | | | | | | Without this, no tests fail if I remove the Diag() in the first if in Sema::mergeMSInheritanceAttr(). llvm-svn: 281136
* [MS ABI] Fix the preferred alignment of member pointersDavid Majnemer2015-04-241-7/+7
| | | | | | | Member pointers in the MS ABI have different alignment depending on whether they were created on the stack or live in a record. llvm-svn: 235681
* MS ABI: Handle member function pointers returning a member data pointerDavid Majnemer2014-08-071-0/+19
| | | | | | | | | MSVC doesn't decide what the inheritance model for a returned member pointer *until* a call expression returns it. This fixes PR20017. llvm-svn: 215164
* MS ABI: Add support for the -vm{b,g,s,m,v} flagsDavid Majnemer2014-02-111-3/+50
| | | | | | | | | These flags control the inheritance model initially used by the translation unit. Differential Revision: http://llvm-reviews.chandlerc.com/D2741 llvm-svn: 201175
* MS ABI: Add support for #pragma pointers_to_membersDavid Majnemer2014-02-101-0/+23
| | | | | | | | | | | | | | | | | | | Introduce a notion of a 'current representation method' for pointers-to-members. When starting out, this is set to 'best case' (representation method is chosen by examining the class, selecting the smallest representation that would work given the class definition or lack thereof). This pragma allows the translation unit to dictate exactly what representation to use, similar to how the inheritance model keywords operate. N.B. PCH support is forthcoming. Differential Revision: http://llvm-reviews.chandlerc.com/D2723 llvm-svn: 201105
* MS ABI: Don't be so hasty to judge an inheritance modelDavid Majnemer2014-02-071-0/+3
| | | | | | | | If we are in the middle of defining the class, don't attempt to validate previously annotated declarations. We may not have seen base specifiers or virtual method declarations yet. llvm-svn: 200959
* [ms-cxxabi] Raise aggregate memptr alignment to 8 for x86_32Reid Kleckner2014-01-311-3/+24
| | | | | | | | | | | | | | | | With this change, we give different results for __alignof than MSVC, but our record layout is compatible. Some data member pointers also now have a size that is not a multiple of their alignment. Fixes PR18618. Reviewers: majnemer Differential Revision: http://llvm-reviews.chandlerc.com/D2669 llvm-svn: 200585
* Sema: Diagnose improper application of inheritance keywordsDavid Majnemer2014-01-291-3/+15
| | | | | | | | | | | We would previously allow inappropriate inheritance keywords to appear on class declarations. We would also allow inheritance keywords on templates which were not fully specialized; this was divergent from MSVC. Differential Revision: http://llvm-reviews.chandlerc.com/D2585 llvm-svn: 200423
* Remove the -cxx-abi command-line flag.Hans Wennborg2014-01-141-2/+2
| | | | | | | | | | | | | | | This makes the C++ ABI depend entirely on the target: MS ABI for -win32 triples, Itanium otherwise. It's no longer possible to do weird combinations. To be able to run a test with a specific ABI without constraining it to a specific triple, new substitutions are added to lit: %itanium_abi_triple and %ms_abi_triple can be used to get the current target triple adjusted to the desired ABI. For example, if the test suite is running with the i686-pc-win32 target, %itanium_abi_triple will expand to i686-pc-mingw32. Differential Revision: http://llvm-reviews.chandlerc.com/D2545 llvm-svn: 199250
* Add a few more tests for casts.Eli Friedman2013-06-201-2/+3
| | | | llvm-svn: 184392
* [ms-cxxabi] Add more tests for r178297Reid Kleckner2013-03-281-0/+33
| | | | | | | This covers a few cases where the class of a member pointer is not a CXXRecordDecl. llvm-svn: 178307
* [ms-cxxabi] Correctly compute the size of member pointersReid Kleckner2013-03-281-11/+131
| | | | | | | | | | | | | | | | | Summary: This also relaxes the requirement on Windows that the member pointer class type be a complete type (http://llvm.org/PR12070). We still ask for a complete type to instantiate any templates (MSVC does this), but if that fails we continue as normal, relying on any inheritance attributes on the declaration. Reviewers: rjmccall CC: triton, timurrrr, cfe-commits Differential Revision: http://llvm-reviews.chandlerc.com/D568 llvm-svn: 178283
* Revert r163078 per chandlerc's request.Joao Matos2012-09-041-7/+5
| | | | llvm-svn: 163145
* Added a diagnostic for mismatched MS inheritance attributes. Also fixed the ↵Joao Matos2012-09-021-5/+7
| | | | | | incomplete type member pointer size calculation under the MS ABI. llvm-svn: 163078
* Error out if reinterpret_casting between member pointers of two differentCharles Davis2010-08-161-0/+8
| | | | | | sizes. llvm-svn: 111119
* Err on incomplete class types in member pointers when compiling for theCharles Davis2010-08-161-0/+6
Microsoft C++ ABI, for now. llvm-svn: 111118
OpenPOWER on IntegriCloud