- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Got a lesson today: IFX and IFORT have different treatments on the string length when using a string type dummy parameter in calling a subroutine in which the string parameter is intent(out). Special attention shoud be paid especially when the string length defined in the subroutine is different than that defined in the caller. With IFORT, the length of the string will be truncated to the defined length in the caller when it is returned from the subroutine in case its length defined in the subroutine is longer. However, with IFX, the length will changed to the length defined in the subroutine thus if the length defined in the caller is smaller, the string will occupy the space of adjacent variables, which will lead to error!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
An incorrect program does not have predictable results. "If a present scalar dummy argument is of type character with default kind or C character kind, the length len of the dummy argument shall be less than or equal to the length of the actual argument."
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
An incorrect program does not have predictable results. "If a present scalar dummy argument is of type character with default kind or C character kind, the length len of the dummy argument shall be less than or equal to the length of the actual argument."
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page