subroutineset_typeprivate
subroutine set_type(v, t)
Copy a parsed type to variable v.
Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
| v | type(entity_t) | inout | the variable | |
| t | type(parsed_type_t) | in | the type |
Source
Show the code
subroutine set_type(v, t)
type(entity_t), intent(inout) :: v !! the variable
type(parsed_type_t), intent(in) :: t !! the type
v%vartype = t%vartype
if (allocated(t%kind)) v%type_kind = t%kind
if (allocated(t%strlen)) v%strlen = t%strlen
if (allocated(t%proto)) v%proto = t%proto
end subroutine set_type