Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

minor SUBMODULE bug

andrew_4619
Honored Contributor III
580 Views
module WhatLineIsTheError
    implicit none
    interface  
    module function thing(it)
        implicit none
        integer             :: thing
        integer, intent(in) :: it
    end function
    end interface
end module WhatLineIsTheError
    
submodule(WhatLineIsTheError) subm1_WhatLineIsTheError
    implicit none
    
    contains
    module function thing(it)
        implicit none
        integer             :: thing
        integer, intent(in) :: it
    end function   
end submodule subm1_WhatLineIsTheError
Compiling with Intel(R) Visual Fortran Compiler 17.0.4.210 [IA-32]...
warning #6178: The return value of this FUNCTION has not been defined.   [THING]

It is but a minor problem. The error has no line association to the source so clicking it takes you to line 1. There have been other errors in SUBMODULE of this type that have been fixed, I suspect there are possibly a number of similar errors of the same class.  

0 Kudos
7 Replies
andrew_4619
Honored Contributor III
580 Views

BTW, The syntax highlighter for in Fortran windows posts misses some keywords e.g. the word SUBMODULE is post #1. I suspect this maybe some third party feature that you have no control over, but if not.....

Yours pedantically, Andrew 

0 Kudos
Kevin_D_Intel
Employee
580 Views

The incorrect VS editor focus when clicking on the warning was reproduced and reported to Development under the internal tracking id noted. The lack of SUBMODULE keyword coloring was reported to the IDZ Forum developers. Thank you.

(Internal tracking id: CMPLRS-43270)

0 Kudos
FortranFan
Honored Contributor III
580 Views

Kevin D (Intel) wrote:

.. The lack of SUBMODULE keyword coloring was reported to the IDZ Forum developers. ..

Kevin,

Fyi on a similar request made a couple of years ago that is pending: https://software.intel.com/en-us/forums/intel-visual-fortran-compiler-for-windows/topic/542008​

 

0 Kudos
andrew_4619
Honored Contributor III
580 Views

My word time flies, 2+ years. I remember that post, that must be where I (correctly) had the idea in my head that the  syntax was a third party tool. Thanks Kevin, maybe you should log that as a defect. OK is might not get fixed in a hurry but it is a defect and at least it is on a do list that hopefully gets continuous review......

0 Kudos
Kevin_D_Intel
Employee
580 Views

From what I'm finding Steve took action on that earlier report FortranFan.

Andrew, it was filed as defect earlier w/our Forum developers who are reviewing the file. I had included the suggestion of continual review by Fortran developers also so hopefully that can be done. Thank you.

0 Kudos
Steve_Lionel
Honored Contributor III
580 Views

A year ago or so I provided to the forum developers a revised syntax coloring script that should be more up to date. I don't recall if they ever deployed it. 

0 Kudos
Norman_K_
New Contributor I
580 Views

As a bizarre twist on the above, please let me share this message:

------ Build started: Project: common_v10.0, Configuration: Debug|x64 ------
Compiling with Intel(R) Visual Fortran Compiler 17.0.7.272 [Intel(R) 64]...
STUDENT_T_VARIATE.f90
C:\Users\ces1nk\AppData\Local\Temp\783213.i90: warning #6178: The return value of this FUNCTION has not been defined.   [ASA^NIBETA]
Build log written to  "file://C:\Users\ces1nk\Dropbox\Shuttlebackup\Dept\Research\Programs\Common\v10.0\common_v10.0\common_v10.0\x64\Debug\BuildLog.htm"
common_v10.0 - 0 error(s), 1 warning(s)

The problem in the above is [ASA^NIBETA]

There is a module called ASA and the module that was compiled to generate the above message (STUDENT_T_VARIATE) does USE ASA. But I have no idea what NIBETA is.  A simple search for the characters (not whole word) NIBETA yields nothing independent of case.  And I am pretty sure that all the functions in module ASA are assigned return values.

STUDENT_T_VARIATE does not have any submodules, not does ASA

Everything seems to run OK

Over several hundred other modules I have a few other similar examples of Warning 6178, none has been traced back to a 'real' problem. Each warning points to a different missing function, each in a different module.

Norman

0 Kudos
Reply