5 Jul 2022 9:13
#29145
I was rather perplexed by this one, and one for others to be aware of. It's all explained in the documentation for 'size'.
program test
implicit none
character(len=17), parameter :: armour_layers(3) = (/'Single wire layer',&
'Double wire layer',&
'Solid '/)
integer :: armour_layers_selected = 1
integer iw
!
! Fails when compiled with x64 if the kind specifier for SIZE is absent
!
iw = winio@('Armouring%ta%`bg[white]%`ls', armour_layers, &
size(armour_layers,kind=3), &
armour_layers_selected)
end