Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(rectangle) | :: | this | ||||
integer, | intent(in) | :: | length_x | |||
integer, | intent(in) | :: | length_y | |||
integer, | intent(in), | optional | :: | length_z |
subroutine set_length_rect(this, length_x, length_y, length_z)
class(rectangle) :: this
integer, intent(in) :: length_x, length_y
integer, intent(in), optional :: length_z
if (present(length_z)) then
unused_var(length_z)
end if
unused_var(length_z)
this%length(1) = length_x
this%length(2) = length_y
end subroutine set_length_rect