Is Boo 100% C# compatible?
Asked Answered
A

4

5

Boo seems like a very cool language. Is it 100% C# compatible? I mean: can I use any C# DLL/class? Could I make use of the XNA framework?

Agiotage answered 17/7, 2009 at 19:40 Comment(2)
If it runs on top of .NET, it should be.Matelot
Yup, i think i got a serviceable implementation of XNA working with F#.Interval
D
6

As far as I know, Boo has an implementation on top of the .NET CLR - which implies that it should be able to both consume, and be consumed by C# code. The syntax may not always be pretty when consuming Boo from C# - but the opposite should be quite elegant, given Boo's syntax.

Also, all of the classes in the .NET BCL should be available to you in Boo.

Discommon answered 17/7, 2009 at 19:42 Comment(0)
S
2

Yes Boo is easily consumed by C# and vice versa. Most of the best features of Boo don't carry over to C#, such as syntactic macros, for obvious reasons, but you can create Macros in C# and consume them in Boo. Additionally Boo has the nice feature of being able to create Modules, which is something you can't do in C#.

They both can create extension methods. Boo has 'duck' typing while C# now has the "dynamic" keyword. While they're both functionally equivalent you might end up seeing the two merge eventually.

Boo currently has known issues with generics, but the feature will be completely supported once they are all ironed out. I suspect there will have to be some extra work done to support the new Co/Contra-variance features in .NET 4 as well.

Salleysalli answered 21/7, 2009 at 22:40 Comment(0)
Z
1

It would be no different than using VB.NET with C#. Currently the only big different between the two (functionally) is Boo does not have pointers... but there are ways to handle that.

PS: Boo IS a wonderful language.

Zinovievsk answered 17/7, 2009 at 19:44 Comment(0)
F
1

IIRC, any language which compiles into IL (Intermediate Language, .NET's version of Java's bytecode) can work with any other language which does the same. So you can mix C#, F#, ASP.NET, VB.NET, and if Boo does the same, you should be able to use with with C# as well.

Featherbedding answered 17/7, 2009 at 19:44 Comment(1)
Not exactly. It is possible to create constructs in certain languages that can't be consumed by other languages. Example: codebetter.com/blogs/matthew.podwysocki/archive/2008/09/10/…Samoyedic

© 2022 - 2024 — McMap. All rights reserved.