File tree Expand file tree Collapse file tree 1 file changed +11
-11
lines changed
libcxx/test/std/language.support/support.dynamic/ptr.launder Expand file tree Collapse file tree 1 file changed +11
-11
lines changed Original file line number Diff line number Diff line change 2020
2121void foo () {}
2222
23- int main (int , char **)
24- {
25- void *p = nullptr ;
26- (void ) std::launder (( void *) nullptr );
27- (void ) std::launder ((const void *) nullptr );
28- (void ) std::launder (( volatile void *) nullptr );
29- ( void ) std::launder (( const volatile void *) nullptr ); // expected-error-re@*:* 4 {{static assertion failed{{.*}}can't launder cv-void}}
30- // expected-error@*:* 0-4 {{void pointer argument to '__builtin_launder' is not allowed}}
31-
32- (void ) std::launder (foo); // expected-error-re@*:* 1 {{static assertion failed{{.*}}can't launder functions}}
33- // expected-error@*:* 0-1 {{function pointer argument to '__builtin_launder' is not allowed}}
23+ int main (int , char **) {
24+ void * p = nullptr ;
25+ ( void ) std::launder (( void *) nullptr ) ;
26+ (void )std::launder ((const void *) nullptr );
27+ (void )std::launder ((volatile void *) nullptr );
28+ (void )std::launder (
29+ ( const volatile void *) nullptr ); // expected-error-re@*:* 4 {{static assertion failed{{.*}}can't launder cv-void}}
30+ // expected-error@*:* 0-4 {{void pointer argument to '__builtin_launder' is not allowed}}
31+
32+ (void )std::launder (foo); // expected-error-re@*:* 1 {{static assertion failed{{.*}}can't launder functions}}
33+ // expected-error@*:* 0-1 {{function pointer argument to '__builtin_launder' is not allowed}}
3434
3535 return 0 ;
3636}
You can’t perform that action at this time.
0 commit comments