Re: [IronPython] unsupported operand type(s) for & operator overloading.

2009-05-12 Thread 李兵
Thank Dino Viehland, Seo Sanghyeon. I have resolved. Code in the following: namespace TestLibrary { public class Foo { public string Value = "abc"; public static FooGroup operator &(Foo left, Foo right) { return new FooGroup(left, right); } } publ

[IronPython] Inspect Module

2009-05-12 Thread Davy Mitchell
Hi Folks, Is there a reason why Inspect is missing from the 2.6 msi? It is present in 2.01. Thanks, Davy Mitchell http://daftspaniel.blogspot.com ___ Users mailing list Users@lists.ironpython.com http://lists.ironpython.com/listinfo.cgi/users-ironpytho

Re: [IronPython] unsupported operand type(s) for & operator overloading.

2009-05-12 Thread Seo Sanghyeon
2009/5/13 李兵 : > IronPython expression like this ' A.Create("Audit") ==  A.Create("Test1") & > A.CreateProperty("Sum") == A.Create("Test2") ' This is a rare pitfall. In C (and C#), == has higher precedence than &, but in Python, & has higher precedence than ==. So IronPython is complaining that it

Re: [IronPython] unsupported operand type(s) for & operator overloading.

2009-05-12 Thread Dino Viehland
Can you include the hosting code which is evaluating the expression? If I do: Fooa.cs: namespace Baz { public class foo { public static void Main(string[] args) { } public static object operator &(foo left, foo right) { return 42; } } }

[IronPython] unsupported operand type(s) for & operator overloading.

2009-05-12 Thread 李兵
Hi, I implemented '&' operator overloading in C# class. But When I used ScriptRuntime compile the expression that use '&' operator, I got a exception 'unsupported operand type(s) for & operator overloading'. The following is C# code. public static Group operator &(Condition left, Condit

[IronPython] IronPython 2.6 CodePlex Source Update

2009-05-12 Thread merllab
This is an automated email letting you know that sources have recently been pushed out. You can download these newer sources directly from http://ironpython.codeplex.com/SourceControl/changeset/view/49967. ADDED SOURCES $/IronPython/IronPython_Main/Src/Tests/Modes $/IronPython/

Re: [IronPython] Scripting an unmanaged app with IronPython?

2009-05-12 Thread Steve Baer
Hi Mike, I did this by creating a C++/CLI DLL that wraps our C++ exported classes/functions for .NET. This way there is no .NET code in our core C++/MFC executable and you get the effect of IP being hosted in the application. Thanks, -Steve - Original Message - From: "Mike Krell"

Re: [IronPython] Scripting an unmanaged app with IronPython?

2009-05-12 Thread Mike Krell
On Tue, May 12, 2009 at 7:58 AM, Curt Hagenlocher wrote: > Is there any reason you wouldn't just do this with CPython? In a past life, > I had a lot of success embedding CPython into a C++ / MFC application. Yes, in fact, I've done a limited version of my approach #2 before using boost.python. T

Re: [IronPython] Scripting an unmanaged app with IronPython?

2009-05-12 Thread Curt Hagenlocher
Is there any reason you wouldn't just do this with CPython? In a past life, I had a lot of success embedding CPython into a C++ / MFC application. On Tue, May 12, 2009 at 7:48 AM, Mike Krell wrote: > I have an unmanaged app written in C++ / MFC that I'd like to script > in some capacity with Iro

[IronPython] Scripting an unmanaged app with IronPython?

2009-05-12 Thread Mike Krell
I have an unmanaged app written in C++ / MFC that I'd like to script in some capacity with IronPython. I can see perhaps three broad approaches to doing this: 1. Somehow hosting IP within the app. This would be the ideal, but I don't know if it's possible. It's clear that I would need to creat

Re: [IronPython] Silverlight Application Hosting IronPython

2009-05-12 Thread Michael Foord
Curt Hagenlocher wrote: I don't know hardly anything about Silverlight, but it might be useful to know what error message you're getting when you fail to load System.Windows. ImportError - exactly the same form of error as when you haven't added a reference to the assembly. Or if I misread and