FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Code reuse

 
Post new topic   Reply to topic     Forum Index -> Tutorials
View previous topic :: View next topic  
Author Message
mikeB



Joined: 08 Nov 2004
Posts: 2

PostPosted: Mon Nov 08, 2004 8:47 pm    Post subject: Code reuse Reply with quote

hi all, i would really appreciate some help regarding reusing compiled code.
I want to write a class, compile it, then use the compiled .obj file in another project without the originial source code. How do i achieve this in D?

thanks in advance
Back to top
View user's profile Send private message MSN Messenger
jcc7



Joined: 22 Feb 2004
Posts: 657
Location: Muskogee, OK, USA

PostPosted: Mon Nov 08, 2004 9:52 pm    Post subject: Re: Code reuse Reply with quote

mikeB wrote:
I want to write a class, compile it, then use the compiled .obj file in another project without the originial source code. How do i achieve this in D?
I'm not 100? sure that's possible, but this might help you out: D/25939 (part of a much larger discussion). I'm sure you'll at least need to a provide a "stripped header" (a D source file that describes the interfaces for the functions).

Hope that helps.
Back to top
View user's profile Send private message AIM Address
mikeB



Joined: 08 Nov 2004
Posts: 2

PostPosted: Tue Nov 09, 2004 5:52 pm    Post subject: re: code reuse Reply with quote

thankyou that was exactly what i was looking for!

Now i understand how you have 2 module files, 1 for the interface and 1 for the implementation.

I am all for open source, but for things like ADT programming etc. some people take 'intellectual property' very seriously.
Back to top
View user's profile Send private message MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> Tutorials All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group