- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi there,
Is the sizeof inquiry instrinsic function standard fortran? (I can't find it my trusty Metcalf/Reid/Cohen)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I see that gfortran has sizeof too, with the following documentation, and I'm wondering whether this also describes the behaviour of sizeof as implemented by ifort, specifically with regards to arguments which are derived types with pointer components.
The return value is of type integer and of the system-dependent kind C_SIZE_T (from the ISO_C_BINDING module). Its value is the number of bytes occupied by the argument. If the argument has the
POINTER
attribute, the number of bytes of the storage area pointed to is returned. If the argument is of a derived type withPOINTER
orALLOCATABLE
components, the return value doesn't account for the sizes of the data pointed to by these components.
PS. I'm sorry if this seems a lazy question, but I thought it'd take less time for one of you experienced users to recall this information than it would me to test it myself
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page