1 ! RUN: %python %S/test_errors.py %s %flang_fc1
3 ! C730 The same type-attr-spec shall not appear more than once in a given
6 ! R727 derived-type-stmt ->
7 ! TYPE [[, type-attr-spec-list] ::] type-name [( type-param-name-list )]
8 ! type-attr-spec values are:
9 ! ABSTRACT, PUBLIC, PRIVATE, BIND(C), EXTENDS(parent-type-name)
10 !WARNING: Attribute 'ABSTRACT' cannot be used more than once
11 type, abstract
, public
, abstract
:: derived1
14 !WARNING: Attribute 'PUBLIC' cannot be used more than once
15 type, public
, abstract
, public
:: derived2
18 !WARNING: Attribute 'PRIVATE' cannot be used more than once
19 type, private
, abstract
, private
:: derived3
22 !ERROR: Attributes 'PUBLIC' and 'PRIVATE' conflict with each other
23 type, public
, abstract
, private
:: derived4
26 !WARNING: Attribute 'BIND(C)' cannot be used more than once
27 type, bind(c
), public
, bind(c
) :: derived5
30 type, public
:: derived6
33 !ERROR: Attribute 'EXTENDS' cannot be used more than once
34 type, extends(derived6
), public
, extends(derived6
) :: derived7