<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Argument checking in Fortran? in Intel® Fortran Compiler</title>
    <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/788999#M31607</link>
    <description>Great! But when I do this I get a lot of error on not maching types when I use LADDR defined as&lt;BR /&gt;&lt;BR /&gt; TYPE PTR&lt;BR /&gt; INTEGER*4, POINTER :: space(:)&lt;BR /&gt; INTEGER*4, POINTER :: p&lt;BR /&gt; INTEGER(ADDR_KIND) :: w&lt;BR /&gt; END TYPE PTR&lt;BR /&gt;&lt;BR /&gt; INTEGER(ADDR_KIND) :: MSPAC&lt;BR /&gt; INTEGER(ADDR_KIND) :: NSPAC&lt;BR /&gt; INTEGER*4, PARAMETER :: MxARRAY = 5999&lt;BR /&gt; INTEGER*4, PARAMETER :: LxDYNAM = 5001&lt;BR /&gt; INTEGER*4, PARAMETER :: MxTEMPO = 50&lt;BR /&gt;&lt;BR /&gt; &lt;B&gt;TYPE(PTR), DIMENSION(0:MxARRAY) :: LADDR&lt;/B&gt;&lt;BR /&gt; TYPE(PTR), DIMENSION(0:MxTEMPO) :: LADDT&lt;BR /&gt;&lt;BR /&gt;on lines were I use the %p&lt;BR /&gt;&lt;BR /&gt;error #8299: A scalar actual argument must be passed to a scalar dummy argument unless the actual argument is of type character or is an element of an array that is neither assumed shape nor pointer. [LNBEM]&lt;BR /&gt; CALL MKBCPTR (LADDR(LxLNBEM)%p,NNBEM&lt;BR /&gt;-----------^&lt;BR /&gt;&lt;BR /&gt;were MKBCPTR is defined as&lt;BR /&gt;&lt;BR /&gt; SUBROUTINE MKBCPTR (LNBEM,NNBEM,BCPTR&lt;BR /&gt; + ,NPOIN,NOVPT,LUTEW,IDEBG)&lt;BR /&gt;C&lt;BR /&gt; IMPLICIT NONE&lt;BR /&gt;C&lt;BR /&gt;C --- Arguments&lt;BR /&gt;C&lt;BR /&gt; INTEGER*4 LNBEM(*)&lt;BR /&gt; INTEGER*4 NNBEM&lt;BR /&gt; INTEGER*4 BCPTR(*)&lt;BR /&gt; INTEGER*4 NPOIN&lt;BR /&gt; INTEGER*4 NOVPT&lt;BR /&gt; INTEGER*4 LUTEW&lt;BR /&gt; INTEGER*4 IDEBG&lt;BR /&gt;&lt;BR /&gt;Anything I can do to get rid of these huge amount of errors?&lt;BR /&gt;</description>
    <pubDate>Tue, 29 Jun 2010 06:58:06 GMT</pubDate>
    <dc:creator>gert_massa</dc:creator>
    <dc:date>2010-06-29T06:58:06Z</dc:date>
    <item>
      <title>Argument checking in Fortran?</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/788995#M31603</link>
      <description>Is it possible to tell the compiler to check the number of argument of subroutines at compile or link time? It is really annoying to have crashes at run-time when you add an argument to some subroutine but forget to change the call statements at some locations. We used to have same errors at link time on windows 32bit because of the use of the Compaq compatibility flag. Unfortunately we had to remove this flag because of same issues with MKL libraries. Is it possible to have this check done anyway even on windows 64 bit?</description>
      <pubDate>Mon, 28 Jun 2010 15:43:06 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/788995#M31603</guid>
      <dc:creator>gert_massa</dc:creator>
      <dc:date>2010-06-28T15:43:06Z</dc:date>
    </item>
    <item>
      <title>Argument checking in Fortran?</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/788996#M31604</link>
      <description>Yes, and this is the default when you create a new project. If you migrated a project from CVF it would not be set. In the project properties, set Diagnostics &amp;gt; Check Routine Interfaces. This will check far more than argument count and will alert you to mismatched types and more.</description>
      <pubDate>Mon, 28 Jun 2010 16:14:16 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/788996#M31604</guid>
      <dc:creator>Steven_L_Intel1</dc:creator>
      <dc:date>2010-06-28T16:14:16Z</dc:date>
    </item>
    <item>
      <title>Argument checking in Fortran?</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/788997#M31605</link>
      <description>I'm using make files to build my project. Which copiler/linker flags do I need to add?</description>
      <pubDate>Tue, 29 Jun 2010 05:57:50 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/788997#M31605</guid>
      <dc:creator>gert_massa</dc:creator>
      <dc:date>2010-06-29T05:57:50Z</dc:date>
    </item>
    <item>
      <title>Argument checking in Fortran?</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/788998#M31606</link>
      <description>Add &lt;B&gt;/warn:interfaces&lt;/B&gt; to the compiler's command line. In versions prior to 11.1, you also need &lt;B&gt;/gen-interfaces&lt;/B&gt; (now, the former automatically switches on the latter).</description>
      <pubDate>Tue, 29 Jun 2010 06:36:01 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/788998#M31606</guid>
      <dc:creator>Jugoslav_Dujic</dc:creator>
      <dc:date>2010-06-29T06:36:01Z</dc:date>
    </item>
    <item>
      <title>Argument checking in Fortran?</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/788999#M31607</link>
      <description>Great! But when I do this I get a lot of error on not maching types when I use LADDR defined as&lt;BR /&gt;&lt;BR /&gt; TYPE PTR&lt;BR /&gt; INTEGER*4, POINTER :: space(:)&lt;BR /&gt; INTEGER*4, POINTER :: p&lt;BR /&gt; INTEGER(ADDR_KIND) :: w&lt;BR /&gt; END TYPE PTR&lt;BR /&gt;&lt;BR /&gt; INTEGER(ADDR_KIND) :: MSPAC&lt;BR /&gt; INTEGER(ADDR_KIND) :: NSPAC&lt;BR /&gt; INTEGER*4, PARAMETER :: MxARRAY = 5999&lt;BR /&gt; INTEGER*4, PARAMETER :: LxDYNAM = 5001&lt;BR /&gt; INTEGER*4, PARAMETER :: MxTEMPO = 50&lt;BR /&gt;&lt;BR /&gt; &lt;B&gt;TYPE(PTR), DIMENSION(0:MxARRAY) :: LADDR&lt;/B&gt;&lt;BR /&gt; TYPE(PTR), DIMENSION(0:MxTEMPO) :: LADDT&lt;BR /&gt;&lt;BR /&gt;on lines were I use the %p&lt;BR /&gt;&lt;BR /&gt;error #8299: A scalar actual argument must be passed to a scalar dummy argument unless the actual argument is of type character or is an element of an array that is neither assumed shape nor pointer. [LNBEM]&lt;BR /&gt; CALL MKBCPTR (LADDR(LxLNBEM)%p,NNBEM&lt;BR /&gt;-----------^&lt;BR /&gt;&lt;BR /&gt;were MKBCPTR is defined as&lt;BR /&gt;&lt;BR /&gt; SUBROUTINE MKBCPTR (LNBEM,NNBEM,BCPTR&lt;BR /&gt; + ,NPOIN,NOVPT,LUTEW,IDEBG)&lt;BR /&gt;C&lt;BR /&gt; IMPLICIT NONE&lt;BR /&gt;C&lt;BR /&gt;C --- Arguments&lt;BR /&gt;C&lt;BR /&gt; INTEGER*4 LNBEM(*)&lt;BR /&gt; INTEGER*4 NNBEM&lt;BR /&gt; INTEGER*4 BCPTR(*)&lt;BR /&gt; INTEGER*4 NPOIN&lt;BR /&gt; INTEGER*4 NOVPT&lt;BR /&gt; INTEGER*4 LUTEW&lt;BR /&gt; INTEGER*4 IDEBG&lt;BR /&gt;&lt;BR /&gt;Anything I can do to get rid of these huge amount of errors?&lt;BR /&gt;</description>
      <pubDate>Tue, 29 Jun 2010 06:58:06 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/788999#M31607</guid>
      <dc:creator>gert_massa</dc:creator>
      <dc:date>2010-06-29T06:58:06Z</dc:date>
    </item>
    <item>
      <title>Argument checking in Fortran?</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789000#M31608</link>
      <description>See &lt;A href="http://software.intel.com/en-us/blogs/2009/03/31/doctor-fortran-in-ive-come-here-for-an-argument/"&gt;I've Come Here For An Argument &lt;/A&gt;- the section on Sequence Associaton. You're passing a scalar p to an array LNBEM, which the language doesn't allow. Even if p was an array, it would be disallowed because it's a pointer. Your code is not legal Fortran and the compiler now caught you at it. (This is from the "Be Careful Of What You Wish For" department...)&lt;BR /&gt;&lt;BR /&gt;What is the intention here? Does MKBCPTR know that only one element is being passed? What is in p?&lt;BR /&gt;</description>
      <pubDate>Tue, 29 Jun 2010 12:05:58 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789000#M31608</guid>
      <dc:creator>Steven_L_Intel1</dc:creator>
      <dc:date>2010-06-29T12:05:58Z</dc:date>
    </item>
    <item>
      <title>Argument checking in Fortran?</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789001#M31609</link>
      <description>No, MKBCPTR is using all the elements in the array of LNBEM. This way of coding dates back from the moment we started using fortran 95 and reworked our code to use dynamic allocation but we still use a kind of memory manager which associates each allocated array to some integer id. LADDR(number)%p is then used to transform then integer number to a pointer and the subroutine call will make sure to cast it to the correct type.

How can I get this code working without errors? Or can I disable these kind of errors?</description>
      <pubDate>Thu, 01 Jul 2010 14:20:14 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789001#M31609</guid>
      <dc:creator>gert_massa</dc:creator>
      <dc:date>2010-07-01T14:20:14Z</dc:date>
    </item>
    <item>
      <title>Argument checking in Fortran?</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789002#M31610</link>
      <description>Try adding:&lt;BR /&gt;&lt;BR /&gt;!DEC$ ATTRIBUTES NO_ARG_CHECK :: LNBEM &lt;BR /&gt;&lt;BR /&gt;after its declaration in MKBCPTR. That may do it. You may need a similar fix anywhere you break the rules this way.</description>
      <pubDate>Thu, 01 Jul 2010 14:38:13 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789002#M31610</guid>
      <dc:creator>Steven_L_Intel1</dc:creator>
      <dc:date>2010-07-01T14:38:13Z</dc:date>
    </item>
    <item>
      <title>Argument checking in Fortran?</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789003#M31611</link>
      <description>You really don't want to know how many times we break the rules in our code :(((&lt;BR /&gt;Can I not filter all the error this type?</description>
      <pubDate>Thu, 01 Jul 2010 14:44:03 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789003#M31611</guid>
      <dc:creator>gert_massa</dc:creator>
      <dc:date>2010-07-01T14:44:03Z</dc:date>
    </item>
    <item>
      <title>Argument checking in Fortran?</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789004#M31612</link>
      <description>Turn off argument checking. You get all of it or none of it. Since you break the rules, you can't use the compiler's diagnostics for following the rules.</description>
      <pubDate>Thu, 01 Jul 2010 17:00:01 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789004#M31612</guid>
      <dc:creator>Steven_L_Intel1</dc:creator>
      <dc:date>2010-07-01T17:00:01Z</dc:date>
    </item>
    <item>
      <title>Argument checking in Fortran?</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789005#M31613</link>
      <description>&lt;DIV id="tiny_quote"&gt;
                &lt;DIV style="margin-left: 2px; margin-right: 2px;"&gt;Quoting &lt;A rel="/en-us/services/profile/quick_profile.php?is_paid=&amp;amp;user_id=453097" class="basic" href="https://community.intel.com/en-us/profile/453097/"&gt;gert.massa&lt;/A&gt;&lt;/DIV&gt;
                &lt;DIV style="background-color: #e5e5e5; padding: 5px; border: 1px inset; margin-left: 2px; margin-right: 2px;"&gt;&lt;I&gt;We used to have same errors at link time on windows 32bit because of the use of the Compaq compatibility flag. Unfortunately we had to remove this flag because of same issues with MKL libraries. &lt;BR /&gt;&lt;/I&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Since we're back to square one: I don't know which issues with MKL you had. At least in theory, MKL should work with CVF calling convention, as long as you link with &lt;B&gt;mkl_intel_s.lib&lt;/B&gt;. See the first note at the end of &lt;A href="http://software.intel.com/en-us/articles/intel-mkl-link-line-advisor/"&gt;MKL Advisor page&lt;/A&gt;.&lt;/P&gt;</description>
      <pubDate>Fri, 02 Jul 2010 09:46:44 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789005#M31613</guid>
      <dc:creator>Jugoslav_Dujic</dc:creator>
      <dc:date>2010-07-02T09:46:44Z</dc:date>
    </item>
    <item>
      <title>Argument checking in Fortran?</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789006#M31614</link>
      <description>Indeed, in theory it should but for the blacs ans scalapack libs some on the sysbols are missing. I reportred this issue to intel support but they decided not to fix it.</description>
      <pubDate>Fri, 02 Jul 2010 09:57:27 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Argument-checking-in-Fortran/m-p/789006#M31614</guid>
      <dc:creator>gert_massa</dc:creator>
      <dc:date>2010-07-02T09:57:27Z</dc:date>
    </item>
  </channel>
</rss>

