use_6.f90
来自「用于进行gcc测试」· F90 代码 · 共 46 行
F90
46 行
! { dg-do compile }! { dg-options "-std=f95" }! Renaming of operatorsmodule z interface operator(.addfive.) module procedure sub2 end interfacecontainsfunction sub2(x) integer :: sub integer,intent(in) :: x sub2 = x + 5end function sub2end module zmodule y interface operator(.addfive.) module procedure sub end interfacecontainsfunction sub(x) integer :: sub integer,intent(in) :: x sub = x + 15end function subend module ymodule x interface operator(.addfive.) module procedure sub end interfacecontainsfunction sub(x) integer :: sub integer,intent(in) :: x sub = x + 25end function subend module xuse x, only : operator(.bar.) => operator(.addfive.) ! { dg-error "Fortran 2003: Renaming operators in USE statements" }use y, operator(.my.) => operator(.addfive.) ! { dg-error "Fortran 2003: Renaming operators in USE statements" }use zend! { dg-final { cleanup-modules "x y z" } }
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?