- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Tried building the following snip:
INTEGER(4) FUNCTION UTL_TIME_ADD_SEC_F ( FIRST, SECOND, RESULT )
!DEC$ ATTRIBUTES DEFAULT, DLLEXPORT :: UTL_TIME_ADD_SEC_F
IMPLICIT NONE
INCLUDE 'utl_structs.inc'
INCLUDE 'utl_time.inc'
*
* Calling Arguments
*
RECORD /timeStamp/ FIRST
RECORD /timeStamp/ SECOND
RECORD /timeStamp/ RESULT
*
* Declare the interface to the 'C' routine
*
INTERFACE
INTEGER(4) FUNCTION utl_time_add_sec(
+ first,
+ second,
+ result)
!DEC$ ATTRIBUTES DEFAULT, DLLEXPORT :: UTL_TIME_ADD_SEC_F
IMPLICIT NONE
INCLUDE 'utl_structs.inc'
INCLUDE 'utl_time.inc'
*
* Calling Arguments
*
RECORD /timeStamp/ FIRST
RECORD /timeStamp/ SECOND
RECORD /timeStamp/ RESULT
*
* Declare the interface to the 'C' routine
*
INTERFACE
INTEGER(4) FUNCTION utl_time_add_sec(
+ first,
+ second,
+ result)
INCLUDE 'utl_structs.inc'
RECORD /timeStamp/ first
RECORD /timeStamp/ second
RECORD /timeStamp/ result
RECORD /timeStamp/ second
RECORD /timeStamp/ result
!DEC$ ATTRIBUTES STDCALL,DLLIMPORT :: utl_time_add_sec
!DEC$ ATTRIBUTES REFERENCE :: first
!DEC$ ATTRIBUTES REFERENCE :: second
!DEC$ ATTRIBUTES REFERENCE :: result
END FUNCTION
END INTERFACE
*
*********************************
* Start of executable code
*********************************
*
!DEC$ ATTRIBUTES REFERENCE :: first
!DEC$ ATTRIBUTES REFERENCE :: second
!DEC$ ATTRIBUTES REFERENCE :: result
END FUNCTION
END INTERFACE
*
*********************************
* Start of executable code
*********************************
*
*
* Call 'C' routine
*
UTL_TIME_ADD_SEC_F = utl_time_add_sec(FIRST, SECOND, RESULT)
* Call 'C' routine
*
UTL_TIME_ADD_SEC_F = utl_time_add_sec(FIRST, SECOND, RESULT)
RETURN
END
END
I get the following error:
Z:onlineutlutl_libsrcutl_time_f.for(64) : Error: This symbol has multiply declared DEC$ ATTRIBUTES DEFAULT attribute. [UTL_TIME_ADD_SEC_F]
!DEC$ ATTRIBUTES DEFAULT,DLLEXPORT::UTL_TIME_ADD_SEC_F
!DEC$ ATTRIBUTES DEFAULT,DLLEXPORT::UTL_TIME_ADD_SEC_F
I removed the DEFAULT attribute and it built fine.
I removed the DLLEXPORT attribute and got the same error.
Is DEC$ ATTRIBUTES DEFAULT not supported in CVF 6.6c?
This compiled fine in CVF 6.6b, although I got a link error. An earlier post indicated a workaround to the link error using a .DEF file, but I'm trying to avoid adding this to all of my projects. I was hoping the link error was fixed in 6.6c.
Is DEC$ ATTRIBUTES DEFAULT not supported in CVF 6.6c?
Link Copied
2 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The DEFAULT attribute is supported. I can't compile your example as-is (don't have the include files), but if I reduce it some, it compiles ok for me.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
My problem was that I had the DEFAULT argument used for the same symbol in the .inc and the .for file. Previous versions of CVF did not flag this error.

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