From: Sandra Loosemore Date: Wed, 9 Jan 2019 21:41:36 +0000 (-0500) Subject: PR other/16615 [3/5] X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=430002e1d97ca7b02d6c9baa1378bdda4fbf7527;p=gcc.git PR other/16615 [3/5] 2019-01-09 Sandra Loosemore PR other/16615 [3/5] gcc/testsuite/ * g++.dg/lto/odr-1_1.C: Update diagnostic message patterns to replace "can not" with "cannot". * gfortran.dg/common_15.f90: Likewise. * gfortran.dg/derived_result_2.f90: Likewise. * gfortran.dg/do_check_6.f90: Likewise. * gfortran.dg/namelist_args.f90: Likewise. * gfortran.dg/negative_unit_check.f90: Likewise. * gfortran.dg/pure_formal_3.f90: Likewise. * obj-c++.dg/attributes/method-attribute-2.mm: Likewise. * obj-c++.dg/exceptions-3.mm: Likewise. * obj-c++.dg/exceptions-4.mm: Likewise. * obj-c++.dg/exceptions-5.mm: Likewise. * obj-c++.dg/property/at-property-23.mm: Likewise. * obj-c++.dg/property/dotsyntax-17.mm: Likewise. * obj-c++.dg/property/property-neg-7.mm: Likewise. * objc.dg/attributes/method-attribute-2.m: Likewise. * objc.dg/exceptions-3.m: Likewise. * objc.dg/exceptions-4.m: Likewise. * objc.dg/exceptions-5.m: Likewise. * objc.dg/param-1.m: Likewise. * objc.dg/property/at-property-23.m: Likewise. * objc.dg/property/dotsyntax-17.m: Likewise. * objc.dg/property/property-neg-7.m: Likewise. From-SVN: r267785 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 6837373cbb4..fc8395f76f6 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,31 @@ +2019-01-09 Sandra Loosemore + + PR other/16615 + + * g++.dg/lto/odr-1_1.C: Update diagnostic message patterns to replace + "can not" with "cannot". + * gfortran.dg/common_15.f90: Likewise. + * gfortran.dg/derived_result_2.f90: Likewise. + * gfortran.dg/do_check_6.f90: Likewise. + * gfortran.dg/namelist_args.f90: Likewise. + * gfortran.dg/negative_unit_check.f90: Likewise. + * gfortran.dg/pure_formal_3.f90: Likewise. + * obj-c++.dg/attributes/method-attribute-2.mm: Likewise. + * obj-c++.dg/exceptions-3.mm: Likewise. + * obj-c++.dg/exceptions-4.mm: Likewise. + * obj-c++.dg/exceptions-5.mm: Likewise. + * obj-c++.dg/property/at-property-23.mm: Likewise. + * obj-c++.dg/property/dotsyntax-17.mm: Likewise. + * obj-c++.dg/property/property-neg-7.mm: Likewise. + * objc.dg/attributes/method-attribute-2.m: Likewise. + * objc.dg/exceptions-3.m: Likewise. + * objc.dg/exceptions-4.m: Likewise. + * objc.dg/exceptions-5.m: Likewise. + * objc.dg/param-1.m: Likewise. + * objc.dg/property/at-property-23.m: Likewise. + * objc.dg/property/dotsyntax-17.m: Likewise. + * objc.dg/property/property-neg-7.m: Likewise. + 2019-01-09 Thomas Koenig PR fortran/68426 diff --git a/gcc/testsuite/g++.dg/lto/odr-1_1.C b/gcc/testsuite/g++.dg/lto/odr-1_1.C index 33a13f01bf2..494436a46c6 100644 --- a/gcc/testsuite/g++.dg/lto/odr-1_1.C +++ b/gcc/testsuite/g++.dg/lto/odr-1_1.C @@ -1,5 +1,5 @@ namespace { - struct b; // { dg-lto-message "type 'struct b' defined in anonymous namespace can not match across the translation unit boundary" } + struct b; // { dg-lto-message "type 'struct b' defined in anonymous namespace cannot match across the translation unit boundary" } } enum vals {aa,bb,cc}; // { dg-lto-message "an enum with different value name is defined in another translation unit" } struct a { // { dg-lto-message "a different type is defined in another translation unit" } diff --git a/gcc/testsuite/gfortran.dg/common_15.f90 b/gcc/testsuite/gfortran.dg/common_15.f90 index 20694fd143b..9723bd1a828 100644 --- a/gcc/testsuite/gfortran.dg/common_15.f90 +++ b/gcc/testsuite/gfortran.dg/common_15.f90 @@ -4,6 +4,6 @@ ! ! Contributed by Vittorio Zecca -common/sub/ a ! { dg-error "can not have the EXTERNAL attribute" } +common/sub/ a ! { dg-error "cannot have the EXTERNAL attribute" } external sub end diff --git a/gcc/testsuite/gfortran.dg/derived_result_2.f90 b/gcc/testsuite/gfortran.dg/derived_result_2.f90 index 51f5b863494..60cad8ddcad 100644 --- a/gcc/testsuite/gfortran.dg/derived_result_2.f90 +++ b/gcc/testsuite/gfortran.dg/derived_result_2.f90 @@ -37,9 +37,9 @@ contains subroutine test integer :: i type(grid) :: g - g = new_field()%mesh ! { dg-error "can not be a function reference" } + g = new_field()%mesh ! { dg-error "cannot be a function reference" } call new_field()%mesh%new_grid() ! { dg-error "Syntax error" } - i = new_field() % mesh%new_int() ! { dg-error "can not be a function reference" } + i = new_field() % mesh%new_int() ! { dg-error "cannot be a function reference" } end subroutine end module diff --git a/gcc/testsuite/gfortran.dg/do_check_6.f90 b/gcc/testsuite/gfortran.dg/do_check_6.f90 index 2e18f219f83..19eff8de5b4 100644 --- a/gcc/testsuite/gfortran.dg/do_check_6.f90 +++ b/gcc/testsuite/gfortran.dg/do_check_6.f90 @@ -26,10 +26,10 @@ subroutine test1() end do ! Invalid: io-implied-do - print *, (i, i=1,5 ) ! { dg-error "PROTECTED and can not appear in a variable definition context .iterator variable." } + print *, (i, i=1,5 ) ! { dg-error "PROTECTED and cannot appear in a variable definition context .iterator variable." } ! Invalid: do-variable in a do-stmt - do i = 1, 5 ! { dg-error "PROTECTED and can not appear in a variable definition context .iterator variable." } + do i = 1, 5 ! { dg-error "PROTECTED and cannot appear in a variable definition context .iterator variable." } end do end subroutine test1 diff --git a/gcc/testsuite/gfortran.dg/namelist_args.f90 b/gcc/testsuite/gfortran.dg/namelist_args.f90 index 132efcebdfb..077e2eb7833 100644 --- a/gcc/testsuite/gfortran.dg/namelist_args.f90 +++ b/gcc/testsuite/gfortran.dg/namelist_args.f90 @@ -11,8 +11,8 @@ function j(k1, k2, k3) end function program pr50555 namelist /i/ j - call g(k,l,i) ! { dg-error "can not be an argument" } - f(k,l,i)=0 ! { dg-error "can not be an argument" } - h = j(k,l,i) ! { dg-error "can not be an argument" } + call g(k,l,i) ! { dg-error "cannot be an argument" } + f(k,l,i)=0 ! { dg-error "cannot be an argument" } + h = j(k,l,i) ! { dg-error "cannot be an argument" } end program ! Note: -std=gnu needed because line 15 function statement is obsolescent diff --git a/gcc/testsuite/gfortran.dg/negative_unit_check.f90 b/gcc/testsuite/gfortran.dg/negative_unit_check.f90 index 002b5b4ac82..33866761252 100644 --- a/gcc/testsuite/gfortran.dg/negative_unit_check.f90 +++ b/gcc/testsuite/gfortran.dg/negative_unit_check.f90 @@ -1,6 +1,6 @@ ! { dg-do compile } ! Test case from PR61933. LOGICAL :: file_exists - INQUIRE(UNIT=-1,EXIST=file_exists)! { dg-error "can not be -1" } - INQUIRE(UNIT=-2,EXIST=file_exists)! { dg-error "can not be -2" } + INQUIRE(UNIT=-1,EXIST=file_exists)! { dg-error "cannot be -1" } + INQUIRE(UNIT=-2,EXIST=file_exists)! { dg-error "cannot be -2" } END diff --git a/gcc/testsuite/gfortran.dg/pure_formal_3.f90 b/gcc/testsuite/gfortran.dg/pure_formal_3.f90 index 5d08057b372..6e3b8585058 100644 --- a/gcc/testsuite/gfortran.dg/pure_formal_3.f90 +++ b/gcc/testsuite/gfortran.dg/pure_formal_3.f90 @@ -12,7 +12,7 @@ end module m pure subroutine foo() use m - call bar(x) ! { dg-error "can not appear in a variable definition context" } + call bar(x) ! { dg-error "cannot appear in a variable definition context" } call bar2(x) ! { dg-error "is local to a PURE procedure and has the POINTER attribute" } call bb(y) ! { dg-error "is local to a PURE procedure and has the POINTER attribute" } contains diff --git a/gcc/testsuite/obj-c++.dg/attributes/method-attribute-2.mm b/gcc/testsuite/obj-c++.dg/attributes/method-attribute-2.mm index 90369cc66c0..06dfa202831 100644 --- a/gcc/testsuite/obj-c++.dg/attributes/method-attribute-2.mm +++ b/gcc/testsuite/obj-c++.dg/attributes/method-attribute-2.mm @@ -14,7 +14,7 @@ @end @implementation obj -- (int) depmth __attribute__((deprecated)) { return var; } /* { dg-warning "method attributes can not be specified in @implementation context" } */ +- (int) depmth __attribute__((deprecated)) { return var; } /* { dg-warning "method attributes cannot be specified in @implementation context" } */ - (int) depmtharg:(int) iarg { return var + iarg ; } - (int) unusedarg:(int) __attribute__((unused)) uarg { return var; } - (int) depunusedarg:(int) __attribute__((unused)) uarg { return var; } diff --git a/gcc/testsuite/obj-c++.dg/exceptions-3.mm b/gcc/testsuite/obj-c++.dg/exceptions-3.mm index c29752d1399..90a657c8d70 100644 --- a/gcc/testsuite/obj-c++.dg/exceptions-3.mm +++ b/gcc/testsuite/obj-c++.dg/exceptions-3.mm @@ -51,7 +51,7 @@ int test (id object) } @try { @throw object; } - @catch (id x) /* { dg-error "@catch parameter can not be protocol-qualified" } */ + @catch (id x) /* { dg-error "@catch parameter cannot be protocol-qualified" } */ { dummy++; } @@ -63,7 +63,7 @@ int test (id object) } @try { @throw object; } - @catch (MyObject *x) /* { dg-error "@catch parameter can not be protocol-qualified" } */ + @catch (MyObject *x) /* { dg-error "@catch parameter cannot be protocol-qualified" } */ { dummy++; } @@ -86,7 +86,7 @@ int test (id object) } @try { @throw object; } - @catch (MyObjectTypedef *x) /* { dg-error "@catch parameter can not be protocol-qualified" } */ + @catch (MyObjectTypedef *x) /* { dg-error "@catch parameter cannot be protocol-qualified" } */ { dummy++; } diff --git a/gcc/testsuite/obj-c++.dg/exceptions-4.mm b/gcc/testsuite/obj-c++.dg/exceptions-4.mm index 104ad0e7fe1..ccdeb34a015 100644 --- a/gcc/testsuite/obj-c++.dg/exceptions-4.mm +++ b/gcc/testsuite/obj-c++.dg/exceptions-4.mm @@ -44,7 +44,7 @@ int test (id object) dummy++; } @catch (id ) /* { dg-error "@catch parameter can not be protocol-qualified" } */ + @catch (id ) /* { dg-error "@catch parameter cannot be protocol-qualified" } */ { dummy++; } @@ -63,7 +63,7 @@ int test (id object) } @try { @throw object; } - @catch (MyObject *) /* { dg-error "@catch parameter can not be protocol-qualified" } */ + @catch (MyObject *) /* { dg-error "@catch parameter cannot be protocol-qualified" } */ { dummy++; } @@ -87,7 +87,7 @@ int test (id object) } @try { @throw object; } - @catch (MyObjectTypedef *) /* { dg-error "@catch parameter can not be protocol-qualified" } */ + @catch (MyObjectTypedef *) /* { dg-error "@catch parameter cannot be protocol-qualified" } */ { dummy++; } diff --git a/gcc/testsuite/obj-c++.dg/property/at-property-23.mm b/gcc/testsuite/obj-c++.dg/property/at-property-23.mm index 2d704454199..009caf9fd2c 100644 --- a/gcc/testsuite/obj-c++.dg/property/at-property-23.mm +++ b/gcc/testsuite/obj-c++.dg/property/at-property-23.mm @@ -11,8 +11,8 @@ { Class isa; } -@property int a[8]; /* { dg-error "property can not be an array" } */ +@property int a[8]; /* { dg-error "property cannot be an array" } */ @property int b:8; /* { dg-error "expected" } */ -@property int c[]; /* { dg-error "property can not be an array" } */ +@property int c[]; /* { dg-error "property cannot be an array" } */ /* { dg-error "forbids flexible array member" "flexible array member" { target *-*-* } .-1 } */ @end diff --git a/gcc/testsuite/obj-c++.dg/property/dotsyntax-17.mm b/gcc/testsuite/obj-c++.dg/property/dotsyntax-17.mm index c28e11f484b..ce015982201 100644 --- a/gcc/testsuite/obj-c++.dg/property/dotsyntax-17.mm +++ b/gcc/testsuite/obj-c++.dg/property/dotsyntax-17.mm @@ -35,19 +35,19 @@ int main (void) { MyRootClass *object = [[MyRootClass alloc] init]; - object.count = 10; /* { dg-error "readonly property can not be set" } */ + object.count = 10; /* { dg-error "readonly property cannot be set" } */ if (object.count != 10) /* Ok */ abort (); /* Test errors when trying to change a readonly property using pre/post increment/decrement operators. */ - object.count++; /* { dg-error "readonly property can not be set" } */ + object.count++; /* { dg-error "readonly property cannot be set" } */ - ++object.count; /* { dg-error "readonly property can not be set" } */ + ++object.count; /* { dg-error "readonly property cannot be set" } */ - object.count--; /* { dg-error "readonly property can not be set" } */ + object.count--; /* { dg-error "readonly property cannot be set" } */ - --object.count; /* { dg-error "readonly property can not be set" } */ + --object.count; /* { dg-error "readonly property cannot be set" } */ /* Test errors when trying to change something using Objective-C 2.0 dot-syntax but there is a setter but no getter. */ diff --git a/gcc/testsuite/obj-c++.dg/property/property-neg-7.mm b/gcc/testsuite/obj-c++.dg/property/property-neg-7.mm index 4c3d5d7d366..245a807f448 100644 --- a/gcc/testsuite/obj-c++.dg/property/property-neg-7.mm +++ b/gcc/testsuite/obj-c++.dg/property/property-neg-7.mm @@ -13,8 +13,8 @@ void foo (NSArray *ans[], id pid, id apid[], int i) { NSArray *test; - test.count = 1; /* { dg-error "readonly property can not be set" } */ - ((NSArray *)pid).count = 1; /* { dg-error "readonly property can not be set" } */ - ((NSArray *)apid[i]).count = 1; /* { dg-error "readonly property can not be set" } */ - ans[i].count = 3; /* { dg-error "readonly property can not be set" } */ + test.count = 1; /* { dg-error "readonly property cannot be set" } */ + ((NSArray *)pid).count = 1; /* { dg-error "readonly property cannot be set" } */ + ((NSArray *)apid[i]).count = 1; /* { dg-error "readonly property cannot be set" } */ + ans[i].count = 3; /* { dg-error "readonly property cannot be set" } */ } diff --git a/gcc/testsuite/objc.dg/attributes/method-attribute-2.m b/gcc/testsuite/objc.dg/attributes/method-attribute-2.m index 90369cc66c0..06dfa202831 100644 --- a/gcc/testsuite/objc.dg/attributes/method-attribute-2.m +++ b/gcc/testsuite/objc.dg/attributes/method-attribute-2.m @@ -14,7 +14,7 @@ @end @implementation obj -- (int) depmth __attribute__((deprecated)) { return var; } /* { dg-warning "method attributes can not be specified in @implementation context" } */ +- (int) depmth __attribute__((deprecated)) { return var; } /* { dg-warning "method attributes cannot be specified in @implementation context" } */ - (int) depmtharg:(int) iarg { return var + iarg ; } - (int) unusedarg:(int) __attribute__((unused)) uarg { return var; } - (int) depunusedarg:(int) __attribute__((unused)) uarg { return var; } diff --git a/gcc/testsuite/objc.dg/exceptions-3.m b/gcc/testsuite/objc.dg/exceptions-3.m index 41f7b5c4d1e..5548a39a08c 100644 --- a/gcc/testsuite/objc.dg/exceptions-3.m +++ b/gcc/testsuite/objc.dg/exceptions-3.m @@ -51,7 +51,7 @@ int test (id object) } @try { @throw object; } - @catch (id x) /* { dg-error "@catch parameter can not be protocol-qualified" } */ + @catch (id x) /* { dg-error "@catch parameter cannot be protocol-qualified" } */ { dummy++; } @@ -63,7 +63,7 @@ int test (id object) } @try { @throw object; } - @catch (MyObject *x) /* { dg-error "@catch parameter can not be protocol-qualified" } */ + @catch (MyObject *x) /* { dg-error "@catch parameter cannot be protocol-qualified" } */ { dummy++; } @@ -87,7 +87,7 @@ int test (id object) } @try { @throw object; } - @catch (MyObjectTypedef *x) /* { dg-error "@catch parameter can not be protocol-qualified" } */ + @catch (MyObjectTypedef *x) /* { dg-error "@catch parameter cannot be protocol-qualified" } */ { dummy++; } diff --git a/gcc/testsuite/objc.dg/exceptions-4.m b/gcc/testsuite/objc.dg/exceptions-4.m index 51d000eb69e..5db60e34aca 100644 --- a/gcc/testsuite/objc.dg/exceptions-4.m +++ b/gcc/testsuite/objc.dg/exceptions-4.m @@ -44,7 +44,7 @@ int test (id object) dummy++; } @catch (id ) /* { dg-error "@catch parameter can not be protocol-qualified" } */ + @catch (id ) /* { dg-error "@catch parameter cannot be protocol-qualified" } */ { dummy++; } @@ -63,7 +63,7 @@ int test (id object) } @try { @throw object; } - @catch (MyObject *) /* { dg-error "@catch parameter can not be protocol-qualified" } */ + @catch (MyObject *) /* { dg-error "@catch parameter cannot be protocol-qualified" } */ { dummy++; } @@ -87,7 +87,7 @@ int test (id object) } @try { @throw object; } - @catch (MyObjectTypedef *) /* { dg-error "@catch parameter can not be protocol-qualified" } */ + @catch (MyObjectTypedef *) /* { dg-error "@catch parameter cannot be protocol-qualified" } */ { dummy++; } diff --git a/gcc/testsuite/objc.dg/param-1.m b/gcc/testsuite/objc.dg/param-1.m index e796a3b5107..9dbf6e3fcd9 100644 --- a/gcc/testsuite/objc.dg/param-1.m +++ b/gcc/testsuite/objc.dg/param-1.m @@ -9,11 +9,11 @@ @end @interface bar --(void) my_method:(foo) my_param; /* { dg-error "can not use an object as parameter to a method" } */ +-(void) my_method:(foo) my_param; /* { dg-error "cannot use an object as parameter to a method" } */ @end @implementation bar --(void) my_method:(foo) my_param /* { dg-error "can not use an object as parameter to a method" } */ +-(void) my_method:(foo) my_param /* { dg-error "cannot use an object as parameter to a method" } */ { } @end diff --git a/gcc/testsuite/objc.dg/property/at-property-23.m b/gcc/testsuite/objc.dg/property/at-property-23.m index c1fd29df4f3..3f6c6098df7 100644 --- a/gcc/testsuite/objc.dg/property/at-property-23.m +++ b/gcc/testsuite/objc.dg/property/at-property-23.m @@ -11,7 +11,7 @@ { Class isa; } -@property int a[8]; /* { dg-error "property can not be an array" } */ -@property int b:8; /* { dg-error "property can not be a bit-field" } */ -@property int c[]; /* { dg-error "property can not be an array" } */ +@property int a[8]; /* { dg-error "property cannot be an array" } */ +@property int b:8; /* { dg-error "property cannot be a bit-field" } */ +@property int c[]; /* { dg-error "property cannot be an array" } */ @end diff --git a/gcc/testsuite/objc.dg/property/dotsyntax-17.m b/gcc/testsuite/objc.dg/property/dotsyntax-17.m index c28e11f484b..ce015982201 100644 --- a/gcc/testsuite/objc.dg/property/dotsyntax-17.m +++ b/gcc/testsuite/objc.dg/property/dotsyntax-17.m @@ -35,19 +35,19 @@ int main (void) { MyRootClass *object = [[MyRootClass alloc] init]; - object.count = 10; /* { dg-error "readonly property can not be set" } */ + object.count = 10; /* { dg-error "readonly property cannot be set" } */ if (object.count != 10) /* Ok */ abort (); /* Test errors when trying to change a readonly property using pre/post increment/decrement operators. */ - object.count++; /* { dg-error "readonly property can not be set" } */ + object.count++; /* { dg-error "readonly property cannot be set" } */ - ++object.count; /* { dg-error "readonly property can not be set" } */ + ++object.count; /* { dg-error "readonly property cannot be set" } */ - object.count--; /* { dg-error "readonly property can not be set" } */ + object.count--; /* { dg-error "readonly property cannot be set" } */ - --object.count; /* { dg-error "readonly property can not be set" } */ + --object.count; /* { dg-error "readonly property cannot be set" } */ /* Test errors when trying to change something using Objective-C 2.0 dot-syntax but there is a setter but no getter. */ diff --git a/gcc/testsuite/objc.dg/property/property-neg-7.m b/gcc/testsuite/objc.dg/property/property-neg-7.m index 4c3d5d7d366..245a807f448 100644 --- a/gcc/testsuite/objc.dg/property/property-neg-7.m +++ b/gcc/testsuite/objc.dg/property/property-neg-7.m @@ -13,8 +13,8 @@ void foo (NSArray *ans[], id pid, id apid[], int i) { NSArray *test; - test.count = 1; /* { dg-error "readonly property can not be set" } */ - ((NSArray *)pid).count = 1; /* { dg-error "readonly property can not be set" } */ - ((NSArray *)apid[i]).count = 1; /* { dg-error "readonly property can not be set" } */ - ans[i].count = 3; /* { dg-error "readonly property can not be set" } */ + test.count = 1; /* { dg-error "readonly property cannot be set" } */ + ((NSArray *)pid).count = 1; /* { dg-error "readonly property cannot be set" } */ + ((NSArray *)apid[i]).count = 1; /* { dg-error "readonly property cannot be set" } */ + ans[i].count = 3; /* { dg-error "readonly property cannot be set" } */ }