OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc2/] [gcc/] [testsuite/] [gfortran.dg/] [char_result_9.f90] - Diff between revs 302 and 384

Only display areas with differences | Details | Blame | View Log

Rev 302 Rev 384
! { dg-do compile }
! { dg-do compile }
! PR 18883: Fake result variables of non-constant length, in module
! PR 18883: Fake result variables of non-constant length, in module
module foo
module foo
contains
contains
    function s_to_c(chars)
    function s_to_c(chars)
        character, pointer :: chars(:)
        character, pointer :: chars(:)
        character(len=len(chars)) :: s_to_c
        character(len=len(chars)) :: s_to_c
        s_to_c = 'a'
        s_to_c = 'a'
    end function s_to_c
    end function s_to_c
end module foo
end module foo
program huj
program huj
    use foo
    use foo
    implicit none
    implicit none
    character, pointer :: c(:)
    character, pointer :: c(:)
    character(3) :: s
    character(3) :: s
    allocate(c(5))
    allocate(c(5))
    c = (/"a", "b", "c" /)
    c = (/"a", "b", "c" /)
    s = s_to_c(c)
    s = s_to_c(c)
end program huj
end program huj
! { dg-final { cleanup-modules "foo" } }
! { dg-final { cleanup-modules "foo" } }
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.