samsmithnz Posted August 4, 2003 Posted August 4, 2003 (edited) Compiling Multiple Languages into One Assembly One of the main features Microsoft declared about VS.NET was that all the languages are now equal in respect to data types. The Main idea being was that you could write a specifically low level module of your application in C++, while the rest was in C# or VB. And because all the languages were compiled down to this common cls thingy, they are all equal (relatively) I know that VS.NET 2002 did not support this multiple language compiling. Something about the compiler not supporting it yet. I wanted to know if this is supported in VS.NET 2003 yet? Or is it just a impossible Microsoft dream.... Thanks Sam Edited August 4, 2003 by samsmithnz Quote Thanks Sam http://www.samsmith.co.nz
*Gurus* divil Posted August 4, 2003 *Gurus* Posted August 4, 2003 What they mean is that you can write one assembly in one language and one in another, and interop between them seamlessly, using the same types. You can even inherit a class written in one language with one written in another. The command-line tools also support compiling ONE assembly from sources in multiple languages, but Visual Studio doesn't support it so you'll have to do it manually using the assembly linker (al.exe) tool. Quote MVP, Visual Developer - .NET Now you see why evil will always triumph - because good is dumb. My free .NET Windows Forms Controls and Articles
samsmithnz Posted August 4, 2003 Author Posted August 4, 2003 Ahhhh thats it. I knew it was something like that. Do you happen to know of any online examples? I've just been reading MSDN, but its very heavy and seems to have a LOT of options! thanks Sam Quote Thanks Sam http://www.samsmith.co.nz
*Gurus* divil Posted August 4, 2003 *Gurus* Posted August 4, 2003 I'm sorry I don't. I haven't ever actually done it, but I think there's an option on the vbc and csc compilers (maybe the c one too) that generates a partial assembly instead of going all the way to exe. You can then link these modules with al.exe. Quote MVP, Visual Developer - .NET Now you see why evil will always triumph - because good is dumb. My free .NET Windows Forms Controls and Articles
samsmithnz Posted August 4, 2003 Author Posted August 4, 2003 OK thanks for your knowledge anyway. Anyone else out there who can help us? I've jsut had a look on Google, but I still can't find any specific examples... Quote Thanks Sam http://www.samsmith.co.nz
Administrators PlausiblyDamp Posted August 4, 2003 Administrators Posted August 4, 2003 IIRC the option is /target:module (for both vbc and csc) Quote Posting Guidelines FAQ Post Formatting Intellectuals solve problems; geniuses prevent them. -- Albert Einstein
samsmithnz Posted August 14, 2003 Author Posted August 14, 2003 I thought I'd post a follow up to what I've found, I'm sure someone will want to do this again in the future. The keywords here are: multifile assembly. Using these keywords you can find a wealth of information on the internet, including this MSDN article: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconbuildingmulti-fileassembly.asp Quote Thanks Sam http://www.samsmith.co.nz
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.