Issue 23758 - Basic : impossible to call subroutine with same module name
Summary: Basic : impossible to call subroutine with same module name
Status: CLOSED WONT_FIX
Alias: None
Product: udk
Classification: Code
Component: code (show other issues)
Version: OOo 1.1
Hardware: All All
: P3 Trivial (vote)
Target Milestone: ---
Assignee: ab
QA Contact: issues@udk
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-12-21 10:47 UTC by bmarcelly
Modified: 2005-01-25 15:45 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
Simple example demonstrating the bug (7.30 KB, application/octet-stream)
2003-12-21 10:49 UTC, bmarcelly
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description bmarcelly 2003-12-21 10:47:09 UTC
Bug with Basic
It is impossible to call from another module a subroutine having the same name 
as the module it belongs. See a simple example in next attachment.
Comment 1 bmarcelly 2003-12-21 10:49:37 UTC
Created attachment 12046 [details]
Simple example demonstrating the bug
Comment 2 ooo 2004-01-06 14:09:27 UTC
StarBASIC runtime, not API
Comment 3 rblackeagle 2004-01-07 01:17:30 UTC
This issue is being reported as two issues on the newsgroup (udk-issues and
api-issues).  Please remove the inappropriate issue as double reporting simply
makes a mess of the newsgroup.
Comment 4 ab 2004-01-22 11:25:47 UTC
The reason for this: The modules are accessible as objects using their names.
So subs in other modules can be called explicitely:

' Module1
Sub main
	Module2.Test
End Sub

' Module2
Sub Test
	print "Test"
End sub

So of course it's not possible to use the name of Modules as variable names.
This cannot be changed any more to stay compatible with existing Basic pro-
grams that might use this feature.
Comment 5 ab 2005-01-25 15:45:20 UTC
-> Closed