<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<id>tag:old.nabble.com,2006:forum-13995</id>
	<title>Nabble - Boo Lang</title>
	<updated>2009-12-06T08:38:09Z</updated>
	<link rel="self" type="application/atom+xml" href="http://old.nabble.com/Boo-Lang-f13995.xml" />
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Boo-Lang-f13995.html" />
	<subtitle type="html">Boo is a new object oriented statically typed programming language for the Common Language Infrastructure with a python inspired syntax and a special focus on language and compiler extensibility. Boo Lang home is &lt;a href=&quot;http://boo.codehaus.org/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;here&lt;/a&gt;.</subtitle>
	
<entry>
	<id>tag:old.nabble.com,2006:post-26666628</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-06T08:38:09Z</published>
	<updated>2009-12-06T08:38:09Z</updated>
	<author>
		<name>Andy Selvig</name>
	</author>
	<content type="html">Great, I'll give that a try. Thanks.
&lt;br&gt;&lt;br&gt;On Sun, Dec 6, 2009 at 10:33 AM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666628&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt; wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; I think with the newer versions of boo you can specify the platform, and if
&lt;br&gt;&amp;gt; you specify x86 specifically you should be able to attach a second instance
&lt;br&gt;&amp;gt; of SD (or VS) to the instance of your actual application. Since the macros
&lt;br&gt;&amp;gt; are user code the other IDE should be able to break on breakpoints in your
&lt;br&gt;&amp;gt; macros.
&lt;br&gt;&amp;gt; Also, you can put a System.Diagnostics.Debug.Break() in your macro and it
&lt;br&gt;&amp;gt; will prompt you to attach a debugger and you can then debug as usual from a
&lt;br&gt;&amp;gt; second instance.
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; On Sun, Dec 6, 2009 at 10:28 AM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666628&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; Wow, thanks Rodrigo! That did the trick. I'm now just messing around
&lt;br&gt;&amp;gt;&amp;gt; with the details of handling the method and property calls, but I
&lt;br&gt;&amp;gt;&amp;gt; think I have it under control.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; Thanks also to Justin and Daniel for the guidance. It's good to see
&lt;br&gt;&amp;gt;&amp;gt; that Boo has a welcoming and helpful community.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; On a mostly separate note (perhaps it belongs in a new thread), as
&lt;br&gt;&amp;gt;&amp;gt; I've been working through this I've felt that it would be helpful to
&lt;br&gt;&amp;gt;&amp;gt; have some more advanced debugging opportunities for the AST code. I'm
&lt;br&gt;&amp;gt;&amp;gt; using SharpDevelop and, since the code below actually executes at the
&lt;br&gt;&amp;gt;&amp;gt; compile time of the main code, I don't get any insight into what's
&lt;br&gt;&amp;gt;&amp;gt; happening (no print/debug statements, and definitely no debugging). If
&lt;br&gt;&amp;gt;&amp;gt; I'm lucky, the main compilation will fail with a helpful runtime
&lt;br&gt;&amp;gt;&amp;gt; exception from the AST code. What's the recommended practice for
&lt;br&gt;&amp;gt;&amp;gt; debugging this type of code? Should I be running booc on the command
&lt;br&gt;&amp;gt;&amp;gt; line with certain options so that I can at least see print statements?
&lt;br&gt;&amp;gt;&amp;gt; Is it at all possible to execute the main compilation process in a
&lt;br&gt;&amp;gt;&amp;gt; debugger? I feel like I'm driving blind with my current setup.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; Anyway, thanks again guys.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; On Fri, Dec 4, 2009 at 6:09 AM, Rodrigo B. de Oliveira
&lt;br&gt;&amp;gt;&amp;gt; &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666628&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;rodrigobamboo@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; On Thu, Dec 3, 2009 at 11:24 PM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666628&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; ...
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; Does anyone else have any more insight?
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; I would probably start with something like the following:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;        import Boo.Lang.Compiler
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;        import Boo.Lang.Compiler.Ast
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;        import Boo.Lang.Compiler.Steps
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;        import Boo.Lang.Compiler.TypeSystem
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;        import Boo.Lang.Compiler.MetaProgramming
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;        class ComponentAttribute(AbstractAstAttribute):
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                _interface as ReferenceExpression
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                _field as Field
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                _pipeline as CompilerPipeline
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                def constructor(interfaceRef as ReferenceExpression):
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        _interface = interfaceRef
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                override def Apply(node as Node):
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        _field = node
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        Pipeline.AfterStep += OnAfterStep
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                override def Dispose():
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        pass
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                def OnAfterStep(sender, args as CompilerStepEventArgs):
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        if not args.Step isa BindTypeMembers:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                                return
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        Pipeline.AfterStep -= OnAfterStep
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        ImplementInterface()
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                def ImplementInterface():
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        print _field, &amp;quot;=&amp;gt;&amp;quot;, _interface
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        enclosingTypeNode = _field.DeclaringType
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        enclosingTypeEntity =
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; GetEntity(enclosingTypeNode)
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;  NameResolutionService.EnterNamespace(enclosingTypeEntity)
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        try:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                                interfaceTypeRef =
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; TypeReference.Lift(_interface)
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;  NameResolutionService.ResolveTypeReference(interfaceTypeRef)
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                                interfaceTypeEntity as IType =
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; GetEntity(interfaceTypeRef)
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                                print
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; join(interfaceTypeEntity.GetMembers(), &amp;quot;\n&amp;quot;)
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        ensure:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                                NameResolutionService.LeaveNamespace()
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                Pipeline:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        get: return Parameters.Pipeline
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;        code = [|
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                namespace Test
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                interface IBar:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        def Ask(text as string) as bool
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                class Foo:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        [component(IBar)]
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        _bar = BarImpl()
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                class BarImpl(IBar):
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                        def Ask(text as string) as bool:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;                                return false
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;        |]
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;        print compile_(code,
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; typeof(ComponentAttribute).Assembly).CompileUnit.ToCodeString()
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; New code must be carefully introduced using CodeBuilder and family
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; methods.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; You received this message because you are subscribed to the Google
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666628&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666628&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; You received this message because you are subscribed to the Google Groups
&lt;br&gt;&amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666628&amp;i=6&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666628&amp;i=7&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; --
&lt;br&gt;&amp;gt; Justin Chase
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; --
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; You received this message because you are subscribed to the Google Groups
&lt;br&gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666628&amp;i=8&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666628&amp;i=9&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;
&lt;/div&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666628&amp;i=10&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666628&amp;i=11&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26666628.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26666581</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-06T08:33:32Z</published>
	<updated>2009-12-06T08:33:32Z</updated>
	<author>
		<name>Justin Chase-2</name>
	</author>
	<content type="html">I think with the newer versions of boo you can specify the platform, and if you specify x86 specifically you should be able to attach a second instance of SD (or VS) to the instance of your actual application. Since the macros are user code the other IDE should be able to break on breakpoints in your macros.&lt;div&gt;
&lt;br&gt;&lt;/div&gt;&lt;div&gt;Also, you can put a System.Diagnostics.Debug.Break() in your macro and it will prompt you to attach a debugger and you can then debug as usual from a second instance.&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;
On Sun, Dec 6, 2009 at 10:28 AM, Andy Selvig &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666581&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;&quot;&gt;
Wow, thanks Rodrigo! That did the trick. I&amp;#39;m now just messing around&lt;br&gt;
with the details of handling the method and property calls, but I&lt;br&gt;
think I have it under control.&lt;br&gt;
&lt;br&gt;
Thanks also to Justin and Daniel for the guidance. It&amp;#39;s good to see&lt;br&gt;
that Boo has a welcoming and helpful community.&lt;br&gt;
&lt;br&gt;
On a mostly separate note (perhaps it belongs in a new thread), as&lt;br&gt;
I&amp;#39;ve been working through this I&amp;#39;ve felt that it would be helpful to&lt;br&gt;
have some more advanced debugging opportunities for the AST code. I&amp;#39;m&lt;br&gt;
using SharpDevelop and, since the code below actually executes at the&lt;br&gt;
compile time of the main code, I don&amp;#39;t get any insight into what&amp;#39;s&lt;br&gt;
happening (no print/debug statements, and definitely no debugging). If&lt;br&gt;
I&amp;#39;m lucky, the main compilation will fail with a helpful runtime&lt;br&gt;
exception from the AST code. What&amp;#39;s the recommended practice for&lt;br&gt;
debugging this type of code? Should I be running booc on the command&lt;br&gt;
line with certain options so that I can at least see print statements?&lt;br&gt;
Is it at all possible to execute the main compilation process in a&lt;br&gt;
debugger? I feel like I&amp;#39;m driving blind with my current setup.&lt;br&gt;
&lt;br&gt;
Anyway, thanks again guys.&lt;br&gt;
&lt;div&gt;&lt;div&gt;&lt;/div&gt;&lt;div class=&quot;h5&quot;&gt;&lt;br&gt;
On Fri, Dec 4, 2009 at 6:09 AM, Rodrigo B. de Oliveira&lt;br&gt;
&amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666581&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;rodrigobamboo@...&lt;/a&gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt; On Thu, Dec 3, 2009 at 11:24 PM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666581&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt;&amp;gt; ...&lt;br&gt;
&amp;gt;&amp;gt; Does anyone else have any more insight?&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; I would probably start with something like the following:&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;        import Boo.Lang.Compiler&lt;br&gt;
&amp;gt;        import Boo.Lang.Compiler.Ast&lt;br&gt;
&amp;gt;        import Boo.Lang.Compiler.Steps&lt;br&gt;
&amp;gt;        import Boo.Lang.Compiler.TypeSystem&lt;br&gt;
&amp;gt;        import Boo.Lang.Compiler.MetaProgramming&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;        class ComponentAttribute(AbstractAstAttribute):&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                _interface as ReferenceExpression&lt;br&gt;
&amp;gt;                _field as Field&lt;br&gt;
&amp;gt;                _pipeline as CompilerPipeline&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                def constructor(interfaceRef as ReferenceExpression):&lt;br&gt;
&amp;gt;                        _interface = interfaceRef&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                override def Apply(node as Node):&lt;br&gt;
&amp;gt;                        _field = node&lt;br&gt;
&amp;gt;                        Pipeline.AfterStep += OnAfterStep&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                override def Dispose():&lt;br&gt;
&amp;gt;                        pass&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                def OnAfterStep(sender, args as CompilerStepEventArgs):&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                        if not args.Step isa BindTypeMembers:&lt;br&gt;
&amp;gt;                                return&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                        Pipeline.AfterStep -= OnAfterStep&lt;br&gt;
&amp;gt;                        ImplementInterface()&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                def ImplementInterface():&lt;br&gt;
&amp;gt;                        print _field, &amp;quot;=&amp;gt;&amp;quot;, _interface&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                        enclosingTypeNode = _field.DeclaringType&lt;br&gt;
&amp;gt;                        enclosingTypeEntity = GetEntity(enclosingTypeNode)&lt;br&gt;
&amp;gt;                        NameResolutionService.EnterNamespace(enclosingTypeEntity)&lt;br&gt;
&amp;gt;                        try:&lt;br&gt;
&amp;gt;                                interfaceTypeRef = TypeReference.Lift(_interface)&lt;br&gt;
&amp;gt;                                NameResolutionService.ResolveTypeReference(interfaceTypeRef)&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                                interfaceTypeEntity as IType = GetEntity(interfaceTypeRef)&lt;br&gt;
&amp;gt;                                print join(interfaceTypeEntity.GetMembers(), &amp;quot;\n&amp;quot;)&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                        ensure:&lt;br&gt;
&amp;gt;                                NameResolutionService.LeaveNamespace()&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                Pipeline:&lt;br&gt;
&amp;gt;                        get: return Parameters.Pipeline&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;        code = [|&lt;br&gt;
&amp;gt;                namespace Test&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                interface IBar:&lt;br&gt;
&amp;gt;                        def Ask(text as string) as bool&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                class Foo:&lt;br&gt;
&amp;gt;                        [component(IBar)]&lt;br&gt;
&amp;gt;                        _bar = BarImpl()&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;                class BarImpl(IBar):&lt;br&gt;
&amp;gt;                        def Ask(text as string) as bool:&lt;br&gt;
&amp;gt;                                return false&lt;br&gt;
&amp;gt;        |]&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;        print compile_(code,&lt;br&gt;
&amp;gt; typeof(ComponentAttribute).Assembly).CompileUnit.ToCodeString()&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; New code must be carefully introduced using CodeBuilder and family methods.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; --&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666581&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt; To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666581&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt; For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&lt;br&gt;
--&lt;br&gt;
&lt;br&gt;
You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666581&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666581&amp;i=6&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;&lt;/div&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;br clear=&quot;all&quot;&gt;&lt;br&gt;-- &lt;br&gt;Justin Chase &lt;br&gt;&lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;
&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;--&lt;/p&gt;

You received this message because you are subscribed to the Google Groups &quot;Boo Programming Language&quot; group.&lt;br /&gt;

To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666581&amp;i=7&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br /&gt;

To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666581&amp;i=8&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.&lt;br /&gt;

For more options, visit this group at http://groups.google.com/group/boolang?hl=en.&lt;br /&gt;

&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26666581.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26666537</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-06T08:28:58Z</published>
	<updated>2009-12-06T08:28:58Z</updated>
	<author>
		<name>Andy Selvig</name>
	</author>
	<content type="html">Wow, thanks Rodrigo! That did the trick. I'm now just messing around
&lt;br&gt;with the details of handling the method and property calls, but I
&lt;br&gt;think I have it under control.
&lt;br&gt;&lt;br&gt;Thanks also to Justin and Daniel for the guidance. It's good to see
&lt;br&gt;that Boo has a welcoming and helpful community.
&lt;br&gt;&lt;br&gt;On a mostly separate note (perhaps it belongs in a new thread), as
&lt;br&gt;I've been working through this I've felt that it would be helpful to
&lt;br&gt;have some more advanced debugging opportunities for the AST code. I'm
&lt;br&gt;using SharpDevelop and, since the code below actually executes at the
&lt;br&gt;compile time of the main code, I don't get any insight into what's
&lt;br&gt;happening (no print/debug statements, and definitely no debugging). If
&lt;br&gt;I'm lucky, the main compilation will fail with a helpful runtime
&lt;br&gt;exception from the AST code. What's the recommended practice for
&lt;br&gt;debugging this type of code? Should I be running booc on the command
&lt;br&gt;line with certain options so that I can at least see print statements?
&lt;br&gt;Is it at all possible to execute the main compilation process in a
&lt;br&gt;debugger? I feel like I'm driving blind with my current setup.
&lt;br&gt;&lt;br&gt;Anyway, thanks again guys.
&lt;br&gt;&lt;br&gt;On Fri, Dec 4, 2009 at 6:09 AM, Rodrigo B. de Oliveira
&lt;br&gt;&amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666537&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;rodrigobamboo@...&lt;/a&gt;&amp;gt; wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; On Thu, Dec 3, 2009 at 11:24 PM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666537&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt; ...
&lt;br&gt;&amp;gt;&amp;gt; Does anyone else have any more insight?
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; I would probably start with something like the following:
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;        import Boo.Lang.Compiler
&lt;br&gt;&amp;gt;        import Boo.Lang.Compiler.Ast
&lt;br&gt;&amp;gt;        import Boo.Lang.Compiler.Steps
&lt;br&gt;&amp;gt;        import Boo.Lang.Compiler.TypeSystem
&lt;br&gt;&amp;gt;        import Boo.Lang.Compiler.MetaProgramming
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;        class ComponentAttribute(AbstractAstAttribute):
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                _interface as ReferenceExpression
&lt;br&gt;&amp;gt;                _field as Field
&lt;br&gt;&amp;gt;                _pipeline as CompilerPipeline
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                def constructor(interfaceRef as ReferenceExpression):
&lt;br&gt;&amp;gt;                        _interface = interfaceRef
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                override def Apply(node as Node):
&lt;br&gt;&amp;gt;                        _field = node
&lt;br&gt;&amp;gt;                        Pipeline.AfterStep += OnAfterStep
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                override def Dispose():
&lt;br&gt;&amp;gt;                        pass
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                def OnAfterStep(sender, args as CompilerStepEventArgs):
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                        if not args.Step isa BindTypeMembers:
&lt;br&gt;&amp;gt;                                return
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                        Pipeline.AfterStep -= OnAfterStep
&lt;br&gt;&amp;gt;                        ImplementInterface()
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                def ImplementInterface():
&lt;br&gt;&amp;gt;                        print _field, &amp;quot;=&amp;gt;&amp;quot;, _interface
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                        enclosingTypeNode = _field.DeclaringType
&lt;br&gt;&amp;gt;                        enclosingTypeEntity = GetEntity(enclosingTypeNode)
&lt;br&gt;&amp;gt;                        NameResolutionService.EnterNamespace(enclosingTypeEntity)
&lt;br&gt;&amp;gt;                        try:
&lt;br&gt;&amp;gt;                                interfaceTypeRef = TypeReference.Lift(_interface)
&lt;br&gt;&amp;gt;                                NameResolutionService.ResolveTypeReference(interfaceTypeRef)
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                                interfaceTypeEntity as IType = GetEntity(interfaceTypeRef)
&lt;br&gt;&amp;gt;                                print join(interfaceTypeEntity.GetMembers(), &amp;quot;\n&amp;quot;)
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                        ensure:
&lt;br&gt;&amp;gt;                                NameResolutionService.LeaveNamespace()
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                Pipeline:
&lt;br&gt;&amp;gt;                        get: return Parameters.Pipeline
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;        code = [|
&lt;br&gt;&amp;gt;                namespace Test
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                interface IBar:
&lt;br&gt;&amp;gt;                        def Ask(text as string) as bool
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                class Foo:
&lt;br&gt;&amp;gt;                        [component(IBar)]
&lt;br&gt;&amp;gt;                        _bar = BarImpl()
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;                class BarImpl(IBar):
&lt;br&gt;&amp;gt;                        def Ask(text as string) as bool:
&lt;br&gt;&amp;gt;                                return false
&lt;br&gt;&amp;gt;        |]
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;        print compile_(code,
&lt;br&gt;&amp;gt; typeof(ComponentAttribute).Assembly).CompileUnit.ToCodeString()
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; New code must be carefully introduced using CodeBuilder and family methods.
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; --
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666537&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt; To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666537&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt; For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;/div&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666537&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26666537&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26666537.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26658787</id>
	<title>Re: Can I declare a list's type?</title>
	<published>2009-12-05T12:06:48Z</published>
	<updated>2009-12-05T12:06:48Z</updated>
	<author>
		<name>Geo-21</name>
	</author>
	<content type="html">Thank you very much guys!
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26658787&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26658787&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Can-I-declare-a-list%27s-type--tp26655219p26658787.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26658708</id>
	<title>Re: Can I declare a list's type?</title>
	<published>2009-12-05T11:59:06Z</published>
	<updated>2009-12-05T11:59:06Z</updated>
	<author>
		<name>A.M. Abdelaziz</name>
	</author>
	<content type="html">&lt;div dir=&quot;ltr&quot;&gt;&lt;div&gt;- u can just say &amp;quot;x as int&amp;quot; easier than &amp;quot;x as System.Int32&amp;quot;&lt;/div&gt;
&lt;div&gt;- place it in the declaration of x ==&amp;gt; after &amp;quot;for&amp;quot;&lt;/div&gt;
&lt;div&gt;so it becomes:&lt;/div&gt;
&lt;div&gt;&lt;b&gt;&lt;font color=&quot;#0000ff&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#0000ff&quot; size=&quot;2&quot;&gt;
&lt;p&gt;for &lt;/p&gt;&lt;/font&gt;&lt;/font&gt;&lt;/b&gt;&lt;font size=&quot;2&quot;&gt;item &lt;/font&gt;&lt;b&gt;&lt;font color=&quot;#0000ff&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#0000ff&quot; size=&quot;2&quot;&gt;in &lt;/font&gt;&lt;/font&gt;&lt;/b&gt;&lt;font color=&quot;#006400&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#006400&quot; size=&quot;2&quot;&gt;[&lt;/font&gt;&lt;/font&gt;&lt;font size=&quot;2&quot;&gt;x &lt;/font&gt;&lt;b&gt;&lt;font color=&quot;#0000ff&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#0000ff&quot; size=&quot;2&quot;&gt;for &lt;/font&gt;&lt;/font&gt;&lt;/b&gt;&lt;font size=&quot;2&quot;&gt;x &lt;/font&gt;&lt;b&gt;&lt;font color=&quot;#0000ff&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#0000ff&quot; size=&quot;2&quot;&gt;as &lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#800080&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#800080&quot; size=&quot;2&quot;&gt;int &lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#0000ff&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#0000ff&quot; size=&quot;2&quot;&gt;in &lt;/font&gt;&lt;/font&gt;&lt;/b&gt;&lt;font size=&quot;2&quot;&gt;vec &lt;/font&gt;&lt;b&gt;&lt;font color=&quot;#0000ff&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#0000ff&quot; size=&quot;2&quot;&gt;if&lt;/font&gt;&lt;/font&gt;&lt;/b&gt;&lt;font color=&quot;#006400&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#006400&quot; size=&quot;2&quot;&gt;(&lt;/font&gt;&lt;/font&gt;&lt;font size=&quot;2&quot;&gt;x &lt;/font&gt;&lt;font color=&quot;#006400&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#006400&quot; size=&quot;2&quot;&gt;% &lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#00008b&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#00008b&quot; size=&quot;2&quot;&gt;2&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#006400&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#006400&quot; size=&quot;2&quot;&gt;) == &lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#00008b&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#00008b&quot; size=&quot;2&quot;&gt;0&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#006400&quot; size=&quot;2&quot;&gt;&lt;font color=&quot;#006400&quot; size=&quot;2&quot;&gt;]&lt;/font&gt;&lt;/font&gt;&lt;font size=&quot;2&quot;&gt;:&lt;/font&gt;or better declare vec as list of ints as Rodrigo said&lt;br&gt;
&lt;br&gt;&lt;/div&gt;
&lt;div class=&quot;gmail_quote&quot;&gt;On Sat, Dec 5, 2009 at 2:17 PM, Geo &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26658708&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;george.opritescu@...&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;
&lt;blockquote style=&quot;BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex&quot; class=&quot;gmail_quote&quot;&gt;Hi guys!&lt;br&gt;&lt;br&gt;I was trying Boo to see how many of Python&amp;#39;s constructs it supports,&lt;br&gt;and I&amp;#39;m kind of stuck at the following code:&lt;br&gt;
&lt;br&gt;namespace bt1&lt;br&gt;&lt;br&gt;import System&lt;br&gt;&lt;br&gt;a = 20&lt;br&gt;b = 30&lt;br&gt;vec = []&lt;br&gt;for i in range(20):&lt;br&gt;       vec.Add(i)&lt;br&gt;for item in [x for x in vec if(x % 2) == 0]:&lt;br&gt;       print item&lt;br&gt;&lt;br&gt;When I compile this, I get this message &amp;quot;Operator &amp;#39;%&amp;#39; cannot be used&lt;br&gt;
with a left hand side of type &amp;#39;object&amp;#39; and a right hand side of type&lt;br&gt;&amp;#39;int&amp;#39;. (BCE0051)&amp;quot;. I assume that by declaring my vec list as [], it&lt;br&gt;will contain generic objects. I tried to replace the last for with&lt;br&gt;
this :&lt;br&gt;&lt;br&gt;for item in [x for x in vec if((x as System.Int32) % 2) == 0]:&lt;br&gt;       print item&lt;br&gt;&lt;br&gt;But I receive the &amp;quot;&amp;#39;int&amp;#39; is a value type. The &amp;#39;as&amp;#39; operator can only&lt;br&gt;be used with reference types.&amp;quot;. How would I get this snippet to work?&lt;br&gt;
Also, can I predeclare the type of values the list can hold?&lt;br&gt;&lt;br&gt;Thanks!&lt;br&gt;&lt;font color=&quot;#888888&quot;&gt;&lt;br&gt;--&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26658708&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26658708&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;/font&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;br clear=&quot;all&quot;&gt;&lt;br&gt;-- &lt;br&gt;
A.M. Abdelaziz&lt;br&gt;&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;--&lt;/p&gt;

You received this message because you are subscribed to the Google Groups &quot;Boo Programming Language&quot; group.&lt;br /&gt;

To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26658708&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br /&gt;

To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26658708&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.&lt;br /&gt;

For more options, visit this group at http://groups.google.com/group/boolang?hl=en.&lt;br /&gt;

&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Can-I-declare-a-list%27s-type--tp26655219p26658708.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26655592</id>
	<title>Re: Can I declare a list's type?</title>
	<published>2009-12-05T05:23:35Z</published>
	<updated>2009-12-05T05:23:35Z</updated>
	<author>
		<name>Rodrigo B. de Oliveira</name>
	</author>
	<content type="html">On Sat, Dec 5, 2009 at 10:17 AM, Geo &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26655592&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;george.opritescu@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt; ...
&lt;br&gt;&amp;gt; vec = []
&lt;br&gt;&lt;br&gt;vec = List of int()
&lt;br&gt;&lt;br&gt;Cheers!
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26655592&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26655592&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Can-I-declare-a-list%27s-type--tp26655219p26655592.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26655219</id>
	<title>Can I declare a list's type?</title>
	<published>2009-12-05T04:17:17Z</published>
	<updated>2009-12-05T04:17:17Z</updated>
	<author>
		<name>Geo-21</name>
	</author>
	<content type="html">Hi guys!
&lt;br&gt;&lt;br&gt;I was trying Boo to see how many of Python's constructs it supports,
&lt;br&gt;and I'm kind of stuck at the following code:
&lt;br&gt;&lt;br&gt;namespace bt1
&lt;br&gt;&lt;br&gt;import System
&lt;br&gt;&lt;br&gt;a = 20
&lt;br&gt;b = 30
&lt;br&gt;vec = []
&lt;br&gt;for i in range(20):
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; vec.Add(i)
&lt;br&gt;for item in [x for x in vec if(x % 2) == 0]:
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; print item
&lt;br&gt;&lt;br&gt;When I compile this, I get this message &amp;quot;Operator '%' cannot be used
&lt;br&gt;with a left hand side of type 'object' and a right hand side of type
&lt;br&gt;'int'. (BCE0051)&amp;quot;. I assume that by declaring my vec list as [], it
&lt;br&gt;will contain generic objects. I tried to replace the last for with
&lt;br&gt;this :
&lt;br&gt;&lt;br&gt;for item in [x for x in vec if((x as System.Int32) % 2) == 0]:
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; print item
&lt;br&gt;&lt;br&gt;But I receive the &amp;quot;'int' is a value type. The 'as' operator can only
&lt;br&gt;be used with reference types.&amp;quot;. How would I get this snippet to work?
&lt;br&gt;Also, can I predeclare the type of values the list can hold?
&lt;br&gt;&lt;br&gt;Thanks!
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26655219&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26655219&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Can-I-declare-a-list%27s-type--tp26655219p26655219.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26641726</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-04T04:09:35Z</published>
	<updated>2009-12-04T04:09:35Z</updated>
	<author>
		<name>Rodrigo B. de Oliveira</name>
	</author>
	<content type="html">On Thu, Dec 3, 2009 at 11:24 PM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26641726&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt; ...
&lt;br&gt;&amp;gt; Does anyone else have any more insight?
&lt;br&gt;&amp;gt;
&lt;br&gt;&lt;br&gt;I would probably start with something like the following:
&lt;br&gt;&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; import Boo.Lang.Compiler
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; import Boo.Lang.Compiler.Ast
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; import Boo.Lang.Compiler.Steps
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; import Boo.Lang.Compiler.TypeSystem
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; import Boo.Lang.Compiler.MetaProgramming
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; class ComponentAttribute(AbstractAstAttribute):
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; _interface as ReferenceExpression
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; _field as Field
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; _pipeline as CompilerPipeline
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; def constructor(interfaceRef as ReferenceExpression):
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; _interface = interfaceRef
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; override def Apply(node as Node):
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; _field = node
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Pipeline.AfterStep += OnAfterStep
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; override def Dispose():
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; pass	
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; def OnAfterStep(sender, args as CompilerStepEventArgs):
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if not args.Step isa BindTypeMembers:
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Pipeline.AfterStep -= OnAfterStep
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ImplementInterface()
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; def ImplementInterface():
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; print _field, &amp;quot;=&amp;gt;&amp;quot;, _interface
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; enclosingTypeNode = _field.DeclaringType
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; enclosingTypeEntity = GetEntity(enclosingTypeNode)
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; NameResolutionService.EnterNamespace(enclosingTypeEntity)
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; try:
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; interfaceTypeRef = TypeReference.Lift(_interface)
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; NameResolutionService.ResolveTypeReference(interfaceTypeRef)
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; interfaceTypeEntity as IType = GetEntity(interfaceTypeRef)
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; print join(interfaceTypeEntity.GetMembers(), &amp;quot;\n&amp;quot;)
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ensure:
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; NameResolutionService.LeaveNamespace()
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Pipeline:
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; get: return Parameters.Pipeline
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; code = [|
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; namespace Test
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; interface IBar:
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; def Ask(text as string) as bool
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; class Foo:
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; [component(IBar)]
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; _bar = BarImpl()
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; class BarImpl(IBar):
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; def Ask(text as string) as bool:
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return false
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; |]
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; print compile_(code,
&lt;br&gt;typeof(ComponentAttribute).Assembly).CompileUnit.ToCodeString()
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&lt;br&gt;New code must be carefully introduced using CodeBuilder and family methods.
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26641726&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26641726&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26641726.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26636496</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-03T17:24:09Z</published>
	<updated>2009-12-03T17:24:09Z</updated>
	<author>
		<name>Andy Selvig</name>
	</author>
	<content type="html">Thanks for the input, Daniel. There are two seemingly relevant methods
&lt;br&gt;in TypeSystemServices. GetEntity() : IEntity and GetType() : IType.
&lt;br&gt;&lt;br&gt;When I try to call either of these with the TypeReference node, I get
&lt;br&gt;an error saying that
&lt;br&gt;&lt;br&gt;&amp;quot;Node 'IBar' has not been correctly processed&amp;quot;
&lt;br&gt;&lt;br&gt;This suggests that I'm not executing this at the appropriate stage in
&lt;br&gt;the compilation process, since that node should be processed at some
&lt;br&gt;point.
&lt;br&gt;&lt;br&gt;Does anyone else have any more insight?
&lt;br&gt;&lt;br&gt;On Thu, Dec 3, 2009 at 6:20 PM, Daniel Grunwald
&lt;br&gt;&amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26636496&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;daniel@...&lt;/a&gt;&amp;gt; wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Andy Selvig wrote:
&lt;br&gt;&amp;gt;&amp;gt; Right, but there's an extra bit of information missing here. The
&lt;br&gt;&amp;gt;&amp;gt; compiler has already resolved IBar to a fully qualified type name and
&lt;br&gt;&amp;gt;&amp;gt; assembly. Simply iterating through the referenced assemblies to find
&lt;br&gt;&amp;gt;&amp;gt; the type isn't enough since there could be multiple assemblies with
&lt;br&gt;&amp;gt;&amp;gt; multiple types called IBar.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; Perhaps this is just something that's not easily doable, but it seems
&lt;br&gt;&amp;gt;&amp;gt; like it should be.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; I haven't written Boo macros in years, but I think you want to use the
&lt;br&gt;&amp;gt; &amp;quot;TypeSystemServices&amp;quot;.
&lt;br&gt;&amp;gt; Can you try and check what TypeSystemServices.GetEntity(typeReference)
&lt;br&gt;&amp;gt; returns? I think it might return an IType instance which has a
&lt;br&gt;&amp;gt; &amp;quot;GetMembers()&amp;quot; function.
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; Daniel
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;/div&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26636496&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26636496&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26636496.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26635707</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-03T16:20:56Z</published>
	<updated>2009-12-03T16:20:56Z</updated>
	<author>
		<name>Daniel Grunwald</name>
	</author>
	<content type="html">Andy Selvig wrote:
&lt;br&gt;&amp;gt; Right, but there's an extra bit of information missing here. The
&lt;br&gt;&amp;gt; compiler has already resolved IBar to a fully qualified type name and
&lt;br&gt;&amp;gt; assembly. Simply iterating through the referenced assemblies to find
&lt;br&gt;&amp;gt; the type isn't enough since there could be multiple assemblies with
&lt;br&gt;&amp;gt; multiple types called IBar.
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; Perhaps this is just something that's not easily doable, but it seems
&lt;br&gt;&amp;gt; like it should be.
&lt;br&gt;&amp;gt; &amp;nbsp; 
&lt;br&gt;&lt;br&gt;I haven't written Boo macros in years, but I think you want to use the
&lt;br&gt;&amp;quot;TypeSystemServices&amp;quot;.
&lt;br&gt;Can you try and check what TypeSystemServices.GetEntity(typeReference)
&lt;br&gt;returns? I think it might return an IType instance which has a
&lt;br&gt;&amp;quot;GetMembers()&amp;quot; function.
&lt;br&gt;&lt;br&gt;Daniel
&lt;br&gt;&lt;br&gt;&lt;br /&gt; &lt;div class=&quot;small&quot;&gt;&lt;br/&gt;&lt;img src=&quot;http://old.nabble.com/images/icon_attachment.gif&quot; &gt; &lt;strong&gt;signature.asc&lt;/strong&gt; (201 bytes) &lt;a href=&quot;http://old.nabble.com/attachment/26635707/0/signature.asc&quot; target=&quot;_top&quot;&gt;Download Attachment&lt;/a&gt;&lt;/div&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26635707.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26635701</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-03T16:19:28Z</published>
	<updated>2009-12-03T16:19:28Z</updated>
	<author>
		<name>Justin Chase-2</name>
	</author>
	<content type="html">Then you&amp;#39;ll need to find the import delcaration expressions first.&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;I&amp;#39;m really surprised there isn&amp;#39;t something to resolve those types already. At some point in the pipeline it will resolve those types obviously. Maybe its just a matter of waiting until the right step in the pipeline. Hopefully someone else in this group will be able to enlighten us.&lt;/div&gt;
&lt;div&gt;&lt;br&gt;&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;On Thu, Dec 3, 2009 at 6:16 PM, Andy Selvig &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;&quot;&gt;
&lt;div class=&quot;im&quot;&gt;&amp;gt; I see, so you&amp;#39;re wanting to get the members of the Type.&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;Exactly! The type that doesn&amp;#39;t necessarily &amp;quot;exist&amp;quot; at compile time but&lt;br&gt;
the members should be listed in the AST. Perhaps this is a bad&lt;br&gt;
assumption? From my understanding, the AST itself is fully assembled&lt;br&gt;
by the time the attribute&amp;#39;s Apply() method gets called.&lt;br&gt;
&lt;div class=&quot;im&quot;&gt;&lt;br&gt;
&amp;gt; But what you could probably do is to look at the parent of the node, all the way up to the Assembly level.&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;Yeah, that&amp;#39;s what I was thinking at first. But of course this would&lt;br&gt;
only work if IBar is declared in same assembly as Foo.&lt;br&gt;
&lt;div class=&quot;im&quot;&gt;&lt;br&gt;
&amp;gt; Otherwise you&amp;#39;ll have to use reflection into referenced assemblies to get the actual Type.&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;Right, but there&amp;#39;s an extra bit of information missing here. The&lt;br&gt;
compiler has already resolved IBar to a fully qualified type name and&lt;br&gt;
assembly. Simply iterating through the referenced assemblies to find&lt;br&gt;
the type isn&amp;#39;t enough since there could be multiple assemblies with&lt;br&gt;
multiple types called IBar.&lt;br&gt;
&lt;br&gt;
Perhaps this is just something that&amp;#39;s not easily doable, but it seems&lt;br&gt;
like it should be.&lt;br&gt;
&lt;div&gt;&lt;div&gt;&lt;/div&gt;&lt;div class=&quot;h5&quot;&gt;&lt;br&gt;
&lt;br&gt;
On Thu, Dec 3, 2009 at 5:33 PM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt; I see, so you&amp;#39;re wanting to get the members of the Type. I&amp;#39;m surprised you&lt;br&gt;
&amp;gt; can&amp;#39;t get that from the TypeExpression. But what you could probably do is to&lt;br&gt;
&amp;gt; look at the parent of the node, all the way up to the Assembly level. You&lt;br&gt;
&amp;gt; should be able to find a list of TypeDeclarations and references. Someone on&lt;br&gt;
&amp;gt; this forum might be able to tell you better if there is a shortcut for that.&lt;br&gt;
&amp;gt; But at the very least I believe if you look all the way up to the top most&lt;br&gt;
&amp;gt; Parent you should then be able to scan back down (with a visitor) to the&lt;br&gt;
&amp;gt; TypeDeclaration. Otherwise you&amp;#39;ll have to use reflection into referenced&lt;br&gt;
&amp;gt; assemblies to get the actual Type.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; On Thu, Dec 3, 2009 at 5:09 PM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; Right, the type may not (in fact, probably won&amp;#39;t) be visible in the&lt;br&gt;
&amp;gt;&amp;gt; context of the macro code since, as you said, it&amp;#39;s executing at&lt;br&gt;
&amp;gt;&amp;gt; compile time and the types haven&amp;#39;t been created yet. However, it seems&lt;br&gt;
&amp;gt;&amp;gt; like there should be a corresponding TypeDefinition node in the AST&lt;br&gt;
&amp;gt;&amp;gt; that contains a list of members for the type.&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; Basically, what I&amp;#39;m trying to do is inject code into classes by&lt;br&gt;
&amp;gt;&amp;gt; forcing them to implement interfaces. So, given an interface:&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; interface IBar:&lt;br&gt;
&amp;gt;&amp;gt;    Speak() as string:&lt;br&gt;
&amp;gt;&amp;gt;        pass&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; we could add an attribute to a field like this:&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; class Foo:&lt;br&gt;
&amp;gt;&amp;gt;    [Component(IBar)]&lt;br&gt;
&amp;gt;&amp;gt;    _bar as IBar&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; which would expand into something like:&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; class Foo (IBar):&lt;br&gt;
&amp;gt;&amp;gt;    _bar as IBar&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt;    Speak() as string:&lt;br&gt;
&amp;gt;&amp;gt;        return _bar.Speak()&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; So, at compile time, the attribute Apply() method determines what&lt;br&gt;
&amp;gt;&amp;gt; interface we&amp;#39;re trying to implement (this is the part I&amp;#39;m struggling&lt;br&gt;
&amp;gt;&amp;gt; with), then adds a proxy method/property to the parent class (Foo) for&lt;br&gt;
&amp;gt;&amp;gt; each method/property in the interface (I think I know how to do this&lt;br&gt;
&amp;gt;&amp;gt; fine).&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; Does this make sense?&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; On Thu, Dec 3, 2009 at 4:22 PM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; One thing you should know is that the macro is running during compile&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; time,&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; which means that the type you might be referencing here might not even&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; exist&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; yet. The TypeExpression should have the string name of the type&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; specified&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; and you can use that to generate code (AST Nodes) in the body of your&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; macro.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; Can you explain a bit more about what you want your macro to do?&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; On Thu, Dec 3, 2009 at 3:53 PM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; Thanks for the response. Yes, it currently gives me a&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; ReferenceExpression.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; If I interpret your response correctly, you&amp;#39;re suggesting that I&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; structure the attribute such that it is used like:&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; [Foo(typeof(IBar))]&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; So, instead of ReferenceExpression I now get a TypeofExpression. From&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; this I can get the TypeExpression that tells me it&amp;#39;s IBar, but I don&amp;#39;t&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; know how to take that and use it to get actual information about the&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; type.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; I can&amp;#39;t tell how I can do anything useful with an instance of&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; TypeExpression.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; On Thu, Dec 3, 2009 at 1:17 PM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; With that you&amp;#39;re probably getting a ReferenceExpression node. Try&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; doing&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; typeof(IBar)&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; On Tue, Dec 1, 2009 at 7:28 AM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=6&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; wrote:&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; Hi-&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; I&amp;#39;m writing an AST attribute and have been having some trouble using&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; the AST functionality to resolve type definitions. The attribute&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; accepts a type literal in it&amp;#39;s constructor:&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; [Foo(IBar)]&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; where IBar is an interface that is accessible within the scope of&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; where FooAttribute is used. In the Apply() method of the attribute,&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; I&amp;#39;d like to reflect on IBar and see what members it has. Presumably,&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; there should be a node (TypeDefinition) in the AST for IBar, but I&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; can&amp;#39;t figure out how to find it.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; Any help would be appreciated. Thanks.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; -Andy&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; --&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; You received this message because you are subscribed to the Google&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; Groups&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=7&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; To unsubscribe from this group, send email to&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=8&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; For more options, visit this group at&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; --&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; Justin Chase&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; --&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; You received this message because you are subscribed to the Google&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; Groups&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=9&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; To unsubscribe from this group, send email to&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=10&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; For more options, visit this group at&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; --&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; You received this message because you are subscribed to the Google&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; Groups&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=11&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; To unsubscribe from this group, send email to&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=12&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; For more options, visit this group at&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; --&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; Justin Chase&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; --&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; You received this message because you are subscribed to the Google&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; Groups&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=13&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; To unsubscribe from this group, send email to&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=14&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; For more options, visit this group at&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; --&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; You received this message because you are subscribed to the Google Groups&lt;br&gt;
&amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=15&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; To unsubscribe from this group, send email to&lt;br&gt;
&amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=16&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; For more options, visit this group at&lt;br&gt;
&amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; --&lt;br&gt;
&amp;gt; Justin Chase&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; --&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; You received this message because you are subscribed to the Google Groups&lt;br&gt;
&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=17&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt; To unsubscribe from this group, send email to&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=18&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt; For more options, visit this group at&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&lt;br&gt;
&lt;br&gt;
--&lt;br&gt;
&lt;br&gt;
You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=19&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=20&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;&lt;/div&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;br clear=&quot;all&quot;&gt;&lt;br&gt;-- &lt;br&gt;Justin Chase &lt;br&gt;&lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;
&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;--&lt;/p&gt;

You received this message because you are subscribed to the Google Groups &quot;Boo Programming Language&quot; group.&lt;br /&gt;

To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=21&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br /&gt;

To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635701&amp;i=22&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.&lt;br /&gt;

For more options, visit this group at http://groups.google.com/group/boolang?hl=en.&lt;br /&gt;

&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26635701.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26635680</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-03T16:16:00Z</published>
	<updated>2009-12-03T16:16:00Z</updated>
	<author>
		<name>Andy Selvig</name>
	</author>
	<content type="html">&amp;gt; I see, so you're wanting to get the members of the Type.
&lt;br&gt;&lt;br&gt;Exactly! The type that doesn't necessarily &amp;quot;exist&amp;quot; at compile time but
&lt;br&gt;the members should be listed in the AST. Perhaps this is a bad
&lt;br&gt;assumption? From my understanding, the AST itself is fully assembled
&lt;br&gt;by the time the attribute's Apply() method gets called.
&lt;br&gt;&lt;br&gt;&amp;gt; But what you could probably do is to look at the parent of the node, all the way up to the Assembly level.
&lt;br&gt;&lt;br&gt;Yeah, that's what I was thinking at first. But of course this would
&lt;br&gt;only work if IBar is declared in same assembly as Foo.
&lt;br&gt;&lt;br&gt;&amp;gt; Otherwise you'll have to use reflection into referenced assemblies to get the actual Type.
&lt;br&gt;&lt;br&gt;Right, but there's an extra bit of information missing here. The
&lt;br&gt;compiler has already resolved IBar to a fully qualified type name and
&lt;br&gt;assembly. Simply iterating through the referenced assemblies to find
&lt;br&gt;the type isn't enough since there could be multiple assemblies with
&lt;br&gt;multiple types called IBar.
&lt;br&gt;&lt;br&gt;Perhaps this is just something that's not easily doable, but it seems
&lt;br&gt;like it should be.
&lt;br&gt;&lt;br&gt;&lt;br&gt;On Thu, Dec 3, 2009 at 5:33 PM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt; wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; I see, so you're wanting to get the members of the Type. I'm surprised you
&lt;br&gt;&amp;gt; can't get that from the TypeExpression. But what you could probably do is to
&lt;br&gt;&amp;gt; look at the parent of the node, all the way up to the Assembly level. You
&lt;br&gt;&amp;gt; should be able to find a list of TypeDeclarations and references. Someone on
&lt;br&gt;&amp;gt; this forum might be able to tell you better if there is a shortcut for that.
&lt;br&gt;&amp;gt; But at the very least I believe if you look all the way up to the top most
&lt;br&gt;&amp;gt; Parent you should then be able to scan back down (with a visitor) to the
&lt;br&gt;&amp;gt; TypeDeclaration. Otherwise you'll have to use reflection into referenced
&lt;br&gt;&amp;gt; assemblies to get the actual Type.
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; On Thu, Dec 3, 2009 at 5:09 PM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; Right, the type may not (in fact, probably won't) be visible in the
&lt;br&gt;&amp;gt;&amp;gt; context of the macro code since, as you said, it's executing at
&lt;br&gt;&amp;gt;&amp;gt; compile time and the types haven't been created yet. However, it seems
&lt;br&gt;&amp;gt;&amp;gt; like there should be a corresponding TypeDefinition node in the AST
&lt;br&gt;&amp;gt;&amp;gt; that contains a list of members for the type.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; Basically, what I'm trying to do is inject code into classes by
&lt;br&gt;&amp;gt;&amp;gt; forcing them to implement interfaces. So, given an interface:
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; interface IBar:
&lt;br&gt;&amp;gt;&amp;gt;    Speak() as string:
&lt;br&gt;&amp;gt;&amp;gt;        pass
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; we could add an attribute to a field like this:
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; class Foo:
&lt;br&gt;&amp;gt;&amp;gt;    [Component(IBar)]
&lt;br&gt;&amp;gt;&amp;gt;    _bar as IBar
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; which would expand into something like:
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; class Foo (IBar):
&lt;br&gt;&amp;gt;&amp;gt;    _bar as IBar
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;    Speak() as string:
&lt;br&gt;&amp;gt;&amp;gt;        return _bar.Speak()
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; So, at compile time, the attribute Apply() method determines what
&lt;br&gt;&amp;gt;&amp;gt; interface we're trying to implement (this is the part I'm struggling
&lt;br&gt;&amp;gt;&amp;gt; with), then adds a proxy method/property to the parent class (Foo) for
&lt;br&gt;&amp;gt;&amp;gt; each method/property in the interface (I think I know how to do this
&lt;br&gt;&amp;gt;&amp;gt; fine).
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; Does this make sense?
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; On Thu, Dec 3, 2009 at 4:22 PM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; One thing you should know is that the macro is running during compile
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; time,
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; which means that the type you might be referencing here might not even
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; exist
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; yet. The TypeExpression should have the string name of the type
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; specified
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; and you can use that to generate code (AST Nodes) in the body of your
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; macro.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; Can you explain a bit more about what you want your macro to do?
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; On Thu, Dec 3, 2009 at 3:53 PM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; Thanks for the response. Yes, it currently gives me a
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; ReferenceExpression.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; If I interpret your response correctly, you're suggesting that I
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; structure the attribute such that it is used like:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; [Foo(typeof(IBar))]
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; So, instead of ReferenceExpression I now get a TypeofExpression. From
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; this I can get the TypeExpression that tells me it's IBar, but I don't
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; know how to take that and use it to get actual information about the
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; type.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; I can't tell how I can do anything useful with an instance of
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; TypeExpression.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; On Thu, Dec 3, 2009 at 1:17 PM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; With that you're probably getting a ReferenceExpression node. Try
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; doing
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; typeof(IBar)
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; On Tue, Dec 1, 2009 at 7:28 AM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; Hi-
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; I'm writing an AST attribute and have been having some trouble using
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; the AST functionality to resolve type definitions. The attribute
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; accepts a type literal in it's constructor:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; [Foo(IBar)]
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; where IBar is an interface that is accessible within the scope of
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; where FooAttribute is used. In the Apply() method of the attribute,
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; I'd like to reflect on IBar and see what members it has. Presumably,
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; there should be a node (TypeDefinition) in the AST for IBar, but I
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; can't figure out how to find it.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; Any help would be appreciated. Thanks.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; -Andy
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; You received this message because you are subscribed to the Google
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; Groups
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=6&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=7&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; Justin Chase
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; You received this message because you are subscribed to the Google
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; Groups
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=8&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=9&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; You received this message because you are subscribed to the Google
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; Groups
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=10&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=11&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; Justin Chase
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; You received this message because you are subscribed to the Google
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; Groups
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=12&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=13&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; You received this message because you are subscribed to the Google Groups
&lt;br&gt;&amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=14&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=15&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; --
&lt;br&gt;&amp;gt; Justin Chase
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; --
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; You received this message because you are subscribed to the Google Groups
&lt;br&gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=16&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=17&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;
&lt;/div&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=18&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635680&amp;i=19&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26635680.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26635165</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-03T15:33:13Z</published>
	<updated>2009-12-03T15:33:13Z</updated>
	<author>
		<name>Justin Chase-2</name>
	</author>
	<content type="html">I see, so you&amp;#39;re wanting to get the members of the Type. I&amp;#39;m surprised you can&amp;#39;t get that from the TypeExpression. But what you could probably do is to look at the parent of the node, all the way up to the Assembly level. You should be able to find a list of TypeDeclarations and references. Someone on this forum might be able to tell you better if there is a shortcut for that. But at the very least I believe if you look all the way up to the top most Parent you should then be able to scan back down (with a visitor) to the TypeDeclaration. Otherwise you&amp;#39;ll have to use reflection into referenced assemblies to get the actual Type.&lt;br&gt;
&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;On Thu, Dec 3, 2009 at 5:09 PM, Andy Selvig &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;&quot;&gt;
Right, the type may not (in fact, probably won&amp;#39;t) be visible in the&lt;br&gt;
context of the macro code since, as you said, it&amp;#39;s executing at&lt;br&gt;
compile time and the types haven&amp;#39;t been created yet. However, it seems&lt;br&gt;
like there should be a corresponding TypeDefinition node in the AST&lt;br&gt;
that contains a list of members for the type.&lt;br&gt;
&lt;br&gt;
Basically, what I&amp;#39;m trying to do is inject code into classes by&lt;br&gt;
forcing them to implement interfaces. So, given an interface:&lt;br&gt;
&lt;br&gt;
interface IBar:&lt;br&gt;
    Speak() as string:&lt;br&gt;
        pass&lt;br&gt;
&lt;br&gt;
we could add an attribute to a field like this:&lt;br&gt;
&lt;br&gt;
class Foo:&lt;br&gt;
    [Component(IBar)]&lt;br&gt;
    _bar as IBar&lt;br&gt;
&lt;br&gt;
which would expand into something like:&lt;br&gt;
&lt;br&gt;
class Foo (IBar):&lt;br&gt;
    _bar as IBar&lt;br&gt;
&lt;br&gt;
    Speak() as string:&lt;br&gt;
        return _bar.Speak()&lt;br&gt;
&lt;br&gt;
So, at compile time, the attribute Apply() method determines what&lt;br&gt;
interface we&amp;#39;re trying to implement (this is the part I&amp;#39;m struggling&lt;br&gt;
with), then adds a proxy method/property to the parent class (Foo) for&lt;br&gt;
each method/property in the interface (I think I know how to do this&lt;br&gt;
fine).&lt;br&gt;
&lt;br&gt;
Does this make sense?&lt;br&gt;
&lt;div&gt;&lt;div&gt;&lt;/div&gt;&lt;div class=&quot;h5&quot;&gt;&lt;br&gt;
On Thu, Dec 3, 2009 at 4:22 PM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt; One thing you should know is that the macro is running during compile time,&lt;br&gt;
&amp;gt; which means that the type you might be referencing here might not even exist&lt;br&gt;
&amp;gt; yet. The TypeExpression should have the string name of the type specified&lt;br&gt;
&amp;gt; and you can use that to generate code (AST Nodes) in the body of your macro.&lt;br&gt;
&amp;gt; Can you explain a bit more about what you want your macro to do?&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; On Thu, Dec 3, 2009 at 3:53 PM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; Thanks for the response. Yes, it currently gives me a ReferenceExpression.&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; If I interpret your response correctly, you&amp;#39;re suggesting that I&lt;br&gt;
&amp;gt;&amp;gt; structure the attribute such that it is used like:&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; [Foo(typeof(IBar))]&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; So, instead of ReferenceExpression I now get a TypeofExpression. From&lt;br&gt;
&amp;gt;&amp;gt; this I can get the TypeExpression that tells me it&amp;#39;s IBar, but I don&amp;#39;t&lt;br&gt;
&amp;gt;&amp;gt; know how to take that and use it to get actual information about the&lt;br&gt;
&amp;gt;&amp;gt; type.&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; I can&amp;#39;t tell how I can do anything useful with an instance of&lt;br&gt;
&amp;gt;&amp;gt; TypeExpression.&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; On Thu, Dec 3, 2009 at 1:17 PM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; With that you&amp;#39;re probably getting a ReferenceExpression node. Try doing&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; typeof(IBar)&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; On Tue, Dec 1, 2009 at 7:28 AM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; Hi-&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; I&amp;#39;m writing an AST attribute and have been having some trouble using&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; the AST functionality to resolve type definitions. The attribute&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; accepts a type literal in it&amp;#39;s constructor:&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; [Foo(IBar)]&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; where IBar is an interface that is accessible within the scope of&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; where FooAttribute is used. In the Apply() method of the attribute,&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; I&amp;#39;d like to reflect on IBar and see what members it has. Presumably,&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; there should be a node (TypeDefinition) in the AST for IBar, but I&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; can&amp;#39;t figure out how to find it.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; Any help would be appreciated. Thanks.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; -Andy&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; --&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; You received this message because you are subscribed to the Google&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; Groups&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; To unsubscribe from this group, send email to&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=6&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; For more options, visit this group at&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; --&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; Justin Chase&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; --&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; You received this message because you are subscribed to the Google&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; Groups&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=7&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; To unsubscribe from this group, send email to&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=8&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; For more options, visit this group at&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; --&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; You received this message because you are subscribed to the Google Groups&lt;br&gt;
&amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=9&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; To unsubscribe from this group, send email to&lt;br&gt;
&amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=10&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; For more options, visit this group at&lt;br&gt;
&amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; --&lt;br&gt;
&amp;gt; Justin Chase&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; --&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; You received this message because you are subscribed to the Google Groups&lt;br&gt;
&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=11&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt; To unsubscribe from this group, send email to&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=12&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt; For more options, visit this group at&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&lt;br&gt;
&lt;br&gt;
--&lt;br&gt;
&lt;br&gt;
You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=13&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=14&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;&lt;/div&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;br clear=&quot;all&quot;&gt;&lt;br&gt;-- &lt;br&gt;Justin Chase &lt;br&gt;&lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;--&lt;/p&gt;

You received this message because you are subscribed to the Google Groups &quot;Boo Programming Language&quot; group.&lt;br /&gt;

To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=15&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br /&gt;

To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26635165&amp;i=16&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.&lt;br /&gt;

For more options, visit this group at http://groups.google.com/group/boolang?hl=en.&lt;br /&gt;

&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26635165.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26634947</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-03T15:09:57Z</published>
	<updated>2009-12-03T15:09:57Z</updated>
	<author>
		<name>Andy Selvig</name>
	</author>
	<content type="html">Right, the type may not (in fact, probably won't) be visible in the
&lt;br&gt;context of the macro code since, as you said, it's executing at
&lt;br&gt;compile time and the types haven't been created yet. However, it seems
&lt;br&gt;like there should be a corresponding TypeDefinition node in the AST
&lt;br&gt;that contains a list of members for the type.
&lt;br&gt;&lt;br&gt;Basically, what I'm trying to do is inject code into classes by
&lt;br&gt;forcing them to implement interfaces. So, given an interface:
&lt;br&gt;&lt;br&gt;interface IBar:
&lt;br&gt;&amp;nbsp; &amp;nbsp; Speak() as string:
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; pass
&lt;br&gt;&lt;br&gt;we could add an attribute to a field like this:
&lt;br&gt;&lt;br&gt;class Foo:
&lt;br&gt;&amp;nbsp; &amp;nbsp; [Component(IBar)]
&lt;br&gt;&amp;nbsp; &amp;nbsp; _bar as IBar
&lt;br&gt;&lt;br&gt;which would expand into something like:
&lt;br&gt;&lt;br&gt;class Foo (IBar):
&lt;br&gt;&amp;nbsp; &amp;nbsp; _bar as IBar
&lt;br&gt;&lt;br&gt;&amp;nbsp; &amp;nbsp; Speak() as string:
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return _bar.Speak()
&lt;br&gt;&lt;br&gt;So, at compile time, the attribute Apply() method determines what
&lt;br&gt;interface we're trying to implement (this is the part I'm struggling
&lt;br&gt;with), then adds a proxy method/property to the parent class (Foo) for
&lt;br&gt;each method/property in the interface (I think I know how to do this
&lt;br&gt;fine).
&lt;br&gt;&lt;br&gt;Does this make sense?
&lt;br&gt;&lt;br&gt;On Thu, Dec 3, 2009 at 4:22 PM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt; wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; One thing you should know is that the macro is running during compile time,
&lt;br&gt;&amp;gt; which means that the type you might be referencing here might not even exist
&lt;br&gt;&amp;gt; yet. The TypeExpression should have the string name of the type specified
&lt;br&gt;&amp;gt; and you can use that to generate code (AST Nodes) in the body of your macro.
&lt;br&gt;&amp;gt; Can you explain a bit more about what you want your macro to do?
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; On Thu, Dec 3, 2009 at 3:53 PM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; Thanks for the response. Yes, it currently gives me a ReferenceExpression.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; If I interpret your response correctly, you're suggesting that I
&lt;br&gt;&amp;gt;&amp;gt; structure the attribute such that it is used like:
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; [Foo(typeof(IBar))]
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; So, instead of ReferenceExpression I now get a TypeofExpression. From
&lt;br&gt;&amp;gt;&amp;gt; this I can get the TypeExpression that tells me it's IBar, but I don't
&lt;br&gt;&amp;gt;&amp;gt; know how to take that and use it to get actual information about the
&lt;br&gt;&amp;gt;&amp;gt; type.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; I can't tell how I can do anything useful with an instance of
&lt;br&gt;&amp;gt;&amp;gt; TypeExpression.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; On Thu, Dec 3, 2009 at 1:17 PM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; With that you're probably getting a ReferenceExpression node. Try doing
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; typeof(IBar)
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; On Tue, Dec 1, 2009 at 7:28 AM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; Hi-
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; I'm writing an AST attribute and have been having some trouble using
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; the AST functionality to resolve type definitions. The attribute
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; accepts a type literal in it's constructor:
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; [Foo(IBar)]
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; where IBar is an interface that is accessible within the scope of
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; where FooAttribute is used. In the Apply() method of the attribute,
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; I'd like to reflect on IBar and see what members it has. Presumably,
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; there should be a node (TypeDefinition) in the AST for IBar, but I
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; can't figure out how to find it.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; Any help would be appreciated. Thanks.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; -Andy
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; You received this message because you are subscribed to the Google
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; Groups
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; Justin Chase
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; You received this message because you are subscribed to the Google
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; Groups
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=6&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=7&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; You received this message because you are subscribed to the Google Groups
&lt;br&gt;&amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=8&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=9&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; --
&lt;br&gt;&amp;gt; Justin Chase
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; --
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; You received this message because you are subscribed to the Google Groups
&lt;br&gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=10&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=11&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;
&lt;/div&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=12&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634947&amp;i=13&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26634947.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26634314</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-03T14:22:02Z</published>
	<updated>2009-12-03T14:22:02Z</updated>
	<author>
		<name>Justin Chase-2</name>
	</author>
	<content type="html">One thing you should know is that the macro is running during compile time, which means that the type you might be referencing here might not even exist yet. The TypeExpression should have the string name of the type specified and you can use that to generate code (AST Nodes) in the body of your macro. Can you explain a bit more about what you want your macro to do?&lt;div&gt;
&lt;br&gt;&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;On Thu, Dec 3, 2009 at 3:53 PM, Andy Selvig &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634314&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;&quot;&gt;
Thanks for the response. Yes, it currently gives me a ReferenceExpression.&lt;br&gt;
&lt;br&gt;
If I interpret your response correctly, you&amp;#39;re suggesting that I&lt;br&gt;
structure the attribute such that it is used like:&lt;br&gt;
&lt;br&gt;
[Foo(typeof(IBar))]&lt;br&gt;
&lt;br&gt;
So, instead of ReferenceExpression I now get a TypeofExpression. From&lt;br&gt;
this I can get the TypeExpression that tells me it&amp;#39;s IBar, but I don&amp;#39;t&lt;br&gt;
know how to take that and use it to get actual information about the&lt;br&gt;
type.&lt;br&gt;
&lt;br&gt;
I can&amp;#39;t tell how I can do anything useful with an instance of TypeExpression.&lt;br&gt;
&lt;div&gt;&lt;div&gt;&lt;/div&gt;&lt;div class=&quot;h5&quot;&gt;&lt;br&gt;
&lt;br&gt;
On Thu, Dec 3, 2009 at 1:17 PM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634314&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt; With that you&amp;#39;re probably getting a ReferenceExpression node. Try doing&lt;br&gt;
&amp;gt; typeof(IBar)&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; On Tue, Dec 1, 2009 at 7:28 AM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634314&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; Hi-&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; I&amp;#39;m writing an AST attribute and have been having some trouble using&lt;br&gt;
&amp;gt;&amp;gt; the AST functionality to resolve type definitions. The attribute&lt;br&gt;
&amp;gt;&amp;gt; accepts a type literal in it&amp;#39;s constructor:&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; [Foo(IBar)]&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; where IBar is an interface that is accessible within the scope of&lt;br&gt;
&amp;gt;&amp;gt; where FooAttribute is used. In the Apply() method of the attribute,&lt;br&gt;
&amp;gt;&amp;gt; I&amp;#39;d like to reflect on IBar and see what members it has. Presumably,&lt;br&gt;
&amp;gt;&amp;gt; there should be a node (TypeDefinition) in the AST for IBar, but I&lt;br&gt;
&amp;gt;&amp;gt; can&amp;#39;t figure out how to find it.&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; Any help would be appreciated. Thanks.&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; -Andy&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; --&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt; You received this message because you are subscribed to the Google Groups&lt;br&gt;
&amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634314&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; To unsubscribe from this group, send email to&lt;br&gt;
&amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634314&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt; For more options, visit this group at&lt;br&gt;
&amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; --&lt;br&gt;
&amp;gt; Justin Chase&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; --&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; You received this message because you are subscribed to the Google Groups&lt;br&gt;
&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634314&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
&amp;gt; To unsubscribe from this group, send email to&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634314&amp;i=6&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
&amp;gt; For more options, visit this group at&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&amp;gt;&lt;br&gt;
&lt;br&gt;
--&lt;br&gt;
&lt;br&gt;
You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634314&amp;i=7&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634314&amp;i=8&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;&lt;/div&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;br clear=&quot;all&quot;&gt;&lt;br&gt;-- &lt;br&gt;Justin Chase &lt;br&gt;&lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;
&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;--&lt;/p&gt;

You received this message because you are subscribed to the Google Groups &quot;Boo Programming Language&quot; group.&lt;br /&gt;

To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634314&amp;i=9&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br /&gt;

To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26634314&amp;i=10&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.&lt;br /&gt;

For more options, visit this group at http://groups.google.com/group/boolang?hl=en.&lt;br /&gt;

&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26634314.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26633890</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-03T13:53:39Z</published>
	<updated>2009-12-03T13:53:39Z</updated>
	<author>
		<name>Andy Selvig</name>
	</author>
	<content type="html">Thanks for the response. Yes, it currently gives me a ReferenceExpression.
&lt;br&gt;&lt;br&gt;If I interpret your response correctly, you're suggesting that I
&lt;br&gt;structure the attribute such that it is used like:
&lt;br&gt;&lt;br&gt;[Foo(typeof(IBar))]
&lt;br&gt;&lt;br&gt;So, instead of ReferenceExpression I now get a TypeofExpression. From
&lt;br&gt;this I can get the TypeExpression that tells me it's IBar, but I don't
&lt;br&gt;know how to take that and use it to get actual information about the
&lt;br&gt;type.
&lt;br&gt;&lt;br&gt;I can't tell how I can do anything useful with an instance of TypeExpression.
&lt;br&gt;&lt;br&gt;&lt;br&gt;On Thu, Dec 3, 2009 at 1:17 PM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26633890&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt; wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; With that you're probably getting a ReferenceExpression node. Try doing
&lt;br&gt;&amp;gt; typeof(IBar)
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; On Tue, Dec 1, 2009 at 7:28 AM, Andy Selvig &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26633890&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; Hi-
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; I'm writing an AST attribute and have been having some trouble using
&lt;br&gt;&amp;gt;&amp;gt; the AST functionality to resolve type definitions. The attribute
&lt;br&gt;&amp;gt;&amp;gt; accepts a type literal in it's constructor:
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; [Foo(IBar)]
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; where IBar is an interface that is accessible within the scope of
&lt;br&gt;&amp;gt;&amp;gt; where FooAttribute is used. In the Apply() method of the attribute,
&lt;br&gt;&amp;gt;&amp;gt; I'd like to reflect on IBar and see what members it has. Presumably,
&lt;br&gt;&amp;gt;&amp;gt; there should be a node (TypeDefinition) in the AST for IBar, but I
&lt;br&gt;&amp;gt;&amp;gt; can't figure out how to find it.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; Any help would be appreciated. Thanks.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; -Andy
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; You received this message because you are subscribed to the Google Groups
&lt;br&gt;&amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26633890&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26633890&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; --
&lt;br&gt;&amp;gt; Justin Chase
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; --
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; You received this message because you are subscribed to the Google Groups
&lt;br&gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26633890&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26633890&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;
&lt;/div&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26633890&amp;i=6&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26633890&amp;i=7&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26633890.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26631868</id>
	<title>Re: Is there a way to eval in boo</title>
	<published>2009-12-03T11:37:35Z</published>
	<updated>2009-12-03T11:37:35Z</updated>
	<author>
		<name>Jeffery Olson</name>
	</author>
	<content type="html">i have code to do this in a test harness for project of mine, here:
&lt;br&gt;&lt;a href=&quot;http://github.com/olsonjeffery/mercury/blob/master/Source/Mercury.Specs/CommonSpecBase.boo&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://github.com/olsonjeffery/mercury/blob/master/Source/Mercury.Specs/CommonSpecBase.boo&lt;/a&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;basically:
&lt;br&gt;&lt;br&gt;import System
&lt;br&gt;import System.Reflection
&lt;br&gt;import Boo.Lang.Compiler
&lt;br&gt;import Boo.Lang.Compiler.IO
&lt;br&gt;import Boo.Lang.Compiler.Ast
&lt;br&gt;import Boo.Lang.Compiler.Pipelines
&lt;br&gt;&lt;br&gt;def CompileCodeAndGetContext(code as string) as CompilerContext:
&lt;br&gt;&amp;nbsp; &amp;nbsp; booC = BooCompiler()
&lt;br&gt;&amp;nbsp; &amp;nbsp; booC.Parameters.Input.Add(StringInput(&amp;quot;name&amp;quot;,code))
&lt;br&gt;&amp;nbsp; &amp;nbsp; for i in AppDomain.CurrentDomain.GetAssemblies():
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; booC.Parameters.AddAssembly(i)
&lt;br&gt;&amp;nbsp; &amp;nbsp; booC.Parameters.Pipeline = CompileToMemory()
&lt;br&gt;&amp;nbsp; &amp;nbsp; booC.Parameters.Ducky = false
&lt;br&gt;&amp;nbsp; &amp;nbsp; compileContext = booC.Run()
&lt;br&gt;&amp;nbsp; &amp;nbsp; raise join(e for e in compileContext.Errors, &amp;quot;\n&amp;quot;) if
&lt;br&gt;compileContext.GeneratedAssembly is null
&lt;br&gt;&amp;nbsp; &amp;nbsp; return compileContext
&lt;br&gt;&lt;br&gt;from here, compileContext.GeneratedAssembly is going to have the
&lt;br&gt;assembly containing the types created by code string that was passed
&lt;br&gt;in to the function.
&lt;br&gt;&lt;br&gt;Hope this helps,
&lt;br&gt;Jeff
&lt;br&gt;&lt;br&gt;On Thu, Dec 3, 2009 at 11:20 AM, Justin Chase &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631868&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;justin.m.chase@...&lt;/a&gt;&amp;gt; wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; You could probably build a macro that does it. You'd have to create an
&lt;br&gt;&amp;gt; instance of the compiler and build a context based on what was above the
&lt;br&gt;&amp;gt; macro, method parameters and this. It could be pretty tricky but might be
&lt;br&gt;&amp;gt; possible.
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; On Thu, Dec 3, 2009 at 1:03 PM, jcline &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631868&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;jasonrcline@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; What I would like to do is something like this:
&lt;br&gt;&amp;gt;&amp;gt; myVar = &amp;quot;My Value&amp;quot;
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; eval(&amp;quot;myVar&amp;quot;) // return &amp;quot;My Value&amp;quot;
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; I have done a lot of searching but to no avail.  Outside of importing
&lt;br&gt;&amp;gt;&amp;gt; and using the Interpreter it seems like like something like this is
&lt;br&gt;&amp;gt;&amp;gt; impossible.  Even with the Interpreter I don't know that it assumes
&lt;br&gt;&amp;gt;&amp;gt; the boo context from which it was reference.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; --
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; You received this message because you are subscribed to the Google Groups
&lt;br&gt;&amp;gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631868&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631868&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; --
&lt;br&gt;&amp;gt; Justin Chase
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; --
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; You received this message because you are subscribed to the Google Groups
&lt;br&gt;&amp;gt; &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;&amp;gt; To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631868&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;&amp;gt; To unsubscribe from this group, send email to
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631868&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;&amp;gt; For more options, visit this group at
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&amp;gt;
&lt;/div&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631868&amp;i=6&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631868&amp;i=7&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Is-there-a-way-to-eval-in-boo-tp26631406p26631868.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26631600</id>
	<title>Re: Is there a way to eval in boo</title>
	<published>2009-12-03T11:20:37Z</published>
	<updated>2009-12-03T11:20:37Z</updated>
	<author>
		<name>Justin Chase-2</name>
	</author>
	<content type="html">You could probably build a macro that does it. You&amp;#39;d have to create an instance of the compiler and build a context based on what was above the macro, method parameters and this. It could be pretty tricky but might be possible.&lt;div&gt;
&lt;br&gt;&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;On Thu, Dec 3, 2009 at 1:03 PM, jcline &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631600&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;jasonrcline@...&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;&quot;&gt;
What I would like to do is something like this:&lt;br&gt;
myVar = &amp;quot;My Value&amp;quot;&lt;br&gt;
&lt;br&gt;
eval(&amp;quot;myVar&amp;quot;) // return &amp;quot;My Value&amp;quot;&lt;br&gt;
&lt;br&gt;
I have done a lot of searching but to no avail.  Outside of importing&lt;br&gt;
and using the Interpreter it seems like like something like this is&lt;br&gt;
impossible.  Even with the Interpreter I don&amp;#39;t know that it assumes&lt;br&gt;
the boo context from which it was reference.&lt;br&gt;
&lt;font color=&quot;#888888&quot;&gt;&lt;br&gt;
--&lt;br&gt;
&lt;br&gt;
You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631600&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631600&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;/font&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;br clear=&quot;all&quot;&gt;&lt;br&gt;-- &lt;br&gt;Justin Chase &lt;br&gt;&lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;
&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;--&lt;/p&gt;

You received this message because you are subscribed to the Google Groups &quot;Boo Programming Language&quot; group.&lt;br /&gt;

To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631600&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br /&gt;

To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631600&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.&lt;br /&gt;

For more options, visit this group at http://groups.google.com/group/boolang?hl=en.&lt;br /&gt;

&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Is-there-a-way-to-eval-in-boo-tp26631406p26631600.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26631657</id>
	<title>Re: Finding types in the AST</title>
	<published>2009-12-03T11:17:59Z</published>
	<updated>2009-12-03T11:17:59Z</updated>
	<author>
		<name>Justin Chase-2</name>
	</author>
	<content type="html">With that you&amp;#39;re probably getting a ReferenceExpression node. Try doing &lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;typeof(IBar)&lt;br&gt;&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;On Tue, Dec 1, 2009 at 7:28 AM, Andy Selvig &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631657&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;ajselvig@...&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;
&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;&quot;&gt;Hi-&lt;br&gt;
&lt;br&gt;
I&amp;#39;m writing an AST attribute and have been having some trouble using&lt;br&gt;
the AST functionality to resolve type definitions. The attribute&lt;br&gt;
accepts a type literal in it&amp;#39;s constructor:&lt;br&gt;
&lt;br&gt;
[Foo(IBar)]&lt;br&gt;
&lt;br&gt;
where IBar is an interface that is accessible within the scope of&lt;br&gt;
where FooAttribute is used. In the Apply() method of the attribute,&lt;br&gt;
I&amp;#39;d like to reflect on IBar and see what members it has. Presumably,&lt;br&gt;
there should be a node (TypeDefinition) in the AST for IBar, but I&lt;br&gt;
can&amp;#39;t figure out how to find it.&lt;br&gt;
&lt;br&gt;
Any help would be appreciated. Thanks.&lt;br&gt;
&lt;br&gt;
-Andy&lt;br&gt;
&lt;font color=&quot;#888888&quot;&gt;&lt;br&gt;
--&lt;br&gt;
&lt;br&gt;
You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631657&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631657&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;/font&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;br clear=&quot;all&quot;&gt;&lt;br&gt;-- &lt;br&gt;Justin Chase &lt;br&gt;&lt;a href=&quot;http://www.justnbusiness.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.justnbusiness.com&lt;/a&gt;&lt;br&gt;
&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;--&lt;/p&gt;

You received this message because you are subscribed to the Google Groups &quot;Boo Programming Language&quot; group.&lt;br /&gt;

To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631657&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br /&gt;

To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631657&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.&lt;br /&gt;

For more options, visit this group at http://groups.google.com/group/boolang?hl=en.&lt;br /&gt;

&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26631657.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26631490</id>
	<title>Re: Is there a way to eval in boo</title>
	<published>2009-12-03T11:13:14Z</published>
	<updated>2009-12-03T11:13:14Z</updated>
	<author>
		<name>Ayende Rahien-2</name>
	</author>
	<content type="html">&lt;div dir=&quot;ltr&quot;&gt;No, you have to use the intepreter&lt;br&gt;&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;On Thu, Dec 3, 2009 at 8:03 PM, jcline &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631490&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;jasonrcline@...&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;
&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;&quot;&gt;What I would like to do is something like this:&lt;br&gt;
myVar = &amp;quot;My Value&amp;quot;&lt;br&gt;
&lt;br&gt;
eval(&amp;quot;myVar&amp;quot;) // return &amp;quot;My Value&amp;quot;&lt;br&gt;
&lt;br&gt;
I have done a lot of searching but to no avail.  Outside of importing&lt;br&gt;
and using the Interpreter it seems like like something like this is&lt;br&gt;
impossible.  Even with the Interpreter I don&amp;#39;t know that it assumes&lt;br&gt;
the boo context from which it was reference.&lt;br&gt;
&lt;font color=&quot;#888888&quot;&gt;&lt;br&gt;
--&lt;br&gt;
&lt;br&gt;
You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631490&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631490&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;/font&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;--&lt;/p&gt;

You received this message because you are subscribed to the Google Groups &quot;Boo Programming Language&quot; group.&lt;br /&gt;

To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631490&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br /&gt;

To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631490&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.&lt;br /&gt;

For more options, visit this group at http://groups.google.com/group/boolang?hl=en.&lt;br /&gt;

&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Is-there-a-way-to-eval-in-boo-tp26631406p26631490.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26631406</id>
	<title>Is there a way to eval in boo</title>
	<published>2009-12-03T11:03:58Z</published>
	<updated>2009-12-03T11:03:58Z</updated>
	<author>
		<name>jcline</name>
	</author>
	<content type="html">What I would like to do is something like this:
&lt;br&gt;myVar = &amp;quot;My Value&amp;quot;
&lt;br&gt;&lt;br&gt;eval(&amp;quot;myVar&amp;quot;) // return &amp;quot;My Value&amp;quot;
&lt;br&gt;&lt;br&gt;I have done a lot of searching but to no avail. &amp;nbsp;Outside of importing
&lt;br&gt;and using the Interpreter it seems like like something like this is
&lt;br&gt;impossible. &amp;nbsp;Even with the Interpreter I don't know that it assumes
&lt;br&gt;the boo context from which it was reference.
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631406&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631406&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Is-there-a-way-to-eval-in-boo-tp26631406p26631406.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26631405</id>
	<title>Finding types in the AST</title>
	<published>2009-12-01T05:28:34Z</published>
	<updated>2009-12-01T05:28:34Z</updated>
	<author>
		<name>Andy Selvig</name>
	</author>
	<content type="html">Hi-
&lt;br&gt;&lt;br&gt;I'm writing an AST attribute and have been having some trouble using
&lt;br&gt;the AST functionality to resolve type definitions. The attribute
&lt;br&gt;accepts a type literal in it's constructor:
&lt;br&gt;&lt;br&gt;[Foo(IBar)]
&lt;br&gt;&lt;br&gt;where IBar is an interface that is accessible within the scope of
&lt;br&gt;where FooAttribute is used. In the Apply() method of the attribute,
&lt;br&gt;I'd like to reflect on IBar and see what members it has. Presumably,
&lt;br&gt;there should be a node (TypeDefinition) in the AST for IBar, but I
&lt;br&gt;can't figure out how to find it.
&lt;br&gt;&lt;br&gt;Any help would be appreciated. Thanks.
&lt;br&gt;&lt;br&gt;-Andy
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631405&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26631405&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Finding-types-in-the-AST-tp26631405p26631405.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26573322</id>
	<title>Re: Loading a XAML file via LoadComponent()</title>
	<published>2009-11-30T03:42:03Z</published>
	<updated>2009-11-30T03:42:03Z</updated>
	<author>
		<name>Andy Sy-2</name>
	</author>
	<content type="html">Ayende Rahien wrote:
&lt;br&gt;&amp;gt; Oh, are you using a Boo version complied for SL?
&lt;br&gt;&lt;br&gt;No, I'm not. &amp;nbsp;I'm just using
&lt;br&gt;&lt;br&gt;&lt;a href=&quot;http://dist.codehaus.org/boo/distributions/boo-0.9.2.3383-bin.zip&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://dist.codehaus.org/boo/distributions/boo-0.9.2.3383-bin.zip&lt;/a&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;It sounds like a Boo version compiled for SL would solve
&lt;br&gt;a lot of problems. &amp;nbsp;Is there such a thing available?
&lt;br&gt;&lt;br&gt;I'm looking at the C# version of a Hello World Silverlight
&lt;br&gt;app and the .xap file contains just a single application
&lt;br&gt;assembly. &amp;nbsp;Would something like that be doable with Boo?
&lt;br&gt;&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26573322&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26573322&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Loading-a-XAML-file-via-LoadComponent%28%29-tp26564594p26573322.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26571871</id>
	<title>Re: Loading a XAML file via LoadComponent()</title>
	<published>2009-11-30T01:51:16Z</published>
	<updated>2009-11-30T01:51:16Z</updated>
	<author>
		<name>Ayende Rahien-2</name>
	</author>
	<content type="html">&lt;div dir=&quot;ltr&quot;&gt;Oh, are you using a Boo version complied for SL?&lt;br&gt;&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;On Mon, Nov 30, 2009 at 8:20 AM, Andy Sy &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://andy.sy&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;andy.sy&lt;/a&gt;@&lt;a href=&quot;http://neotitans.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;neotitans.com&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;
&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;&quot;&gt;&lt;div class=&quot;im&quot;&gt;Ayende Rahien wrote:&lt;br&gt;
&amp;gt; Check all the references that you use, make sure they all use the&lt;br&gt;
&amp;gt; appropriate mscorlib&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;Hmm, I notice there are apparently 3 different mscorlib.dll files&lt;br&gt;
on my system:&lt;br&gt;
&lt;br&gt;
a smaller 1,460,032 mscorlib.dll for silverlight&lt;br&gt;
&lt;br&gt;
and two bigger 4,567,040 and 4,550,656 ones for&lt;br&gt;
32-bit and 64-bit .Net Framework respectively (I&amp;#39;m&lt;br&gt;
on x64).&lt;br&gt;
&lt;br&gt;
Could Boo.Lang.dll be referring to one of these&lt;br&gt;
bigger ones, while the assemblies that Silverlight&lt;br&gt;
uses (e.g. System.Windows.dll, system.dll,&lt;br&gt;
System.Windows.Controls.dll) be using the mscorlib.dll&lt;br&gt;
for Silverlight ?&lt;br&gt;
&lt;br&gt;
If this is the case, how do we fix this?&lt;br&gt;
&lt;div&gt;&lt;div&gt;&lt;/div&gt;&lt;div class=&quot;h5&quot;&gt;&lt;br&gt;
--&lt;br&gt;
&lt;br&gt;
You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26571871&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26571871&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;&lt;/div&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;--&lt;/p&gt;

You received this message because you are subscribed to the Google Groups &quot;Boo Programming Language&quot; group.&lt;br /&gt;

To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26571871&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br /&gt;

To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26571871&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.&lt;br /&gt;

For more options, visit this group at http://groups.google.com/group/boolang?hl=en.&lt;br /&gt;

&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Loading-a-XAML-file-via-LoadComponent%28%29-tp26564594p26571871.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26570607</id>
	<title>Re: Silverlight mscorlib.dll versus CLR mscorlib.dll</title>
	<published>2009-11-30T01:05:16Z</published>
	<updated>2009-11-30T01:05:16Z</updated>
	<author>
		<name>Andy Sy-2</name>
	</author>
	<content type="html">Andy Sy wrote:
&lt;br&gt;&lt;br&gt;&amp;gt; The section &amp;quot;Inside the CoreCLR Engine&amp;quot; has a very good
&lt;br&gt;&amp;gt; explanation of how/why MS made it possible to run both
&lt;br&gt;&amp;gt; CoreCLR and CLR side-by-side in a single process.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; So I guess in theory it is not forbidden to have Boo.Lang.dll
&lt;br&gt;&amp;gt; refer to one mscorlib.dll and Silverlight's
&lt;br&gt;&amp;gt; System.Windows.*.dll's to another?
&lt;br&gt;&lt;br&gt;But since Boo.Lang.dll references a different System.dll
&lt;br&gt;which in turn refers to assemblies that Silverlight's
&lt;br&gt;system.dll does not refer to (nor is provided by Silverlight's
&lt;br&gt;assembly cache), does this also mean that on systems
&lt;br&gt;where .NET Framework is not installed (e.g. Mac), Silverlight
&lt;br&gt;apps compiled with Boo will not work?
&lt;br&gt;&lt;br&gt;I've attached the dependency graphs (in SVG, you can just
&lt;br&gt;drag to Firefox to display) for Boo.Lang.dll and Silverlight's
&lt;br&gt;Windows.System.dll to illustrate this.
&lt;br&gt;&lt;br&gt;This seems like a serious impediment to being able to create true
&lt;br&gt;Silverlight-only apps for Boo.
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26570607&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26570607&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;br /&gt; &lt;br /&gt; &lt;div class=&quot;small&quot;&gt;&lt;br/&gt;&lt;img src=&quot;http://old.nabble.com/images/icon_attachment.gif&quot; &gt; &lt;strong&gt;System.Windows.dll.depgraph.svg&lt;/strong&gt; (8K) &lt;a href=&quot;http://old.nabble.com/attachment/26570607/0/System.Windows.dll.depgraph.svg&quot; target=&quot;_top&quot;&gt;Download Attachment&lt;/a&gt;&lt;br/&gt;&lt;img src=&quot;http://old.nabble.com/images/icon_attachment.gif&quot; &gt; &lt;strong&gt;Boo.Lang.dll.depgraph.svg&lt;/strong&gt; (8K) &lt;a href=&quot;http://old.nabble.com/attachment/26570607/1/Boo.Lang.dll.depgraph.svg&quot; target=&quot;_top&quot;&gt;Download Attachment&lt;/a&gt;&lt;/div&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Loading-a-XAML-file-via-LoadComponent%28%29-tp26564594p26570607.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26570789</id>
	<title>Re: Silverlight mscorlib.dll versus CLR mscorlib.dll</title>
	<published>2009-11-30T00:49:53Z</published>
	<updated>2009-11-30T00:49:53Z</updated>
	<author>
		<name>Andy Sy-2</name>
	</author>
	<content type="html">Ayende Rahien wrote:
&lt;br&gt;&amp;gt; Check all the references that you use, make sure they all use the 
&lt;br&gt;&amp;gt; appropriate mscorlib
&lt;br&gt;&lt;br&gt;I came across this article:
&lt;br&gt;&lt;br&gt;&lt;a href=&quot;http://msdn.microsoft.com/en-us/magazine/cc895632.aspx&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://msdn.microsoft.com/en-us/magazine/cc895632.aspx&lt;/a&gt;&lt;br&gt;&lt;br&gt;&amp;quot;Silverlight 2 does incorporate a CLR, but it's not the
&lt;br&gt;same CLR used by the other .NET applications and
&lt;br&gt;assemblies ... The main issue is with the mscorlib
&lt;br&gt;assembly. &amp;nbsp;Silverlight needs a much smaller set of
&lt;br&gt;functionality for its purposes—just the core stuff.
&lt;br&gt;Any .NET assembly, instead, links to the standard version
&lt;br&gt;of mscorlib, and this is where the trouble starts...&amp;quot;
&lt;br&gt;&lt;br&gt;which I guess is what you're talking about.
&lt;br&gt;&lt;br&gt;It also points to this article about CoreCLR (the
&lt;br&gt;minimized CLR variant used in Silverlight)
&lt;br&gt;&lt;br&gt;&lt;a href=&quot;http://msdn.microsoft.com/en-us/magazine/cc721609.aspx&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://msdn.microsoft.com/en-us/magazine/cc721609.aspx&lt;/a&gt;&lt;br&gt;&lt;br&gt;The section &amp;quot;Inside the CoreCLR Engine&amp;quot; has a very good
&lt;br&gt;explanation of how/why MS made it possible to run both
&lt;br&gt;CoreCLR and CLR side-by-side in a single process.
&lt;br&gt;&lt;br&gt;So I guess in theory it is not forbidden to have Boo.Lang.dll
&lt;br&gt;refer to one mscorlib.dll and Silverlight's
&lt;br&gt;System.Windows.*.dll's to another?
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26570789&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26570789&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Loading-a-XAML-file-via-LoadComponent%28%29-tp26564594p26570789.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26570080</id>
	<title>Re: Loading a XAML file via LoadComponent()</title>
	<published>2009-11-29T22:20:56Z</published>
	<updated>2009-11-29T22:20:56Z</updated>
	<author>
		<name>Andy Sy-2</name>
	</author>
	<content type="html">Ayende Rahien wrote:
&lt;br&gt;&amp;gt; Check all the references that you use, make sure they all use the 
&lt;br&gt;&amp;gt; appropriate mscorlib
&lt;br&gt;&lt;br&gt;Hmm, I notice there are apparently 3 different mscorlib.dll files
&lt;br&gt;on my system:
&lt;br&gt;&lt;br&gt;a smaller 1,460,032 mscorlib.dll for silverlight
&lt;br&gt;&lt;br&gt;and two bigger 4,567,040 and 4,550,656 ones for
&lt;br&gt;32-bit and 64-bit .Net Framework respectively (I'm
&lt;br&gt;on x64).
&lt;br&gt;&lt;br&gt;Could Boo.Lang.dll be referring to one of these
&lt;br&gt;bigger ones, while the assemblies that Silverlight
&lt;br&gt;uses (e.g. System.Windows.dll, system.dll,
&lt;br&gt;System.Windows.Controls.dll) be using the mscorlib.dll
&lt;br&gt;for Silverlight ?
&lt;br&gt;&lt;br&gt;If this is the case, how do we fix this?
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26570080&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26570080&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Loading-a-XAML-file-via-LoadComponent%28%29-tp26564594p26570080.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26570029</id>
	<title>Dependency flaws in Boo-compiled DLLs (was Re: Loading a XAML file via LoadComponent())</title>
	<published>2009-11-29T22:12:01Z</published>
	<updated>2009-11-29T22:12:01Z</updated>
	<author>
		<name>Andy Sy-2</name>
	</author>
	<content type="html">Ayende Rahien wrote:
&lt;br&gt;&amp;gt; Check all the references that you use, make sure they all use the 
&lt;br&gt;&amp;gt; appropriate mscorlib
&lt;br&gt;&lt;br&gt;While not directly related to my problem (which still
&lt;br&gt;remains unsolved), I noticed something that might
&lt;br&gt;not look right when I ran Dependency Analyser (from
&lt;br&gt;&lt;a href=&quot;http://www.drewnoakes.com/code/dependancyanalyser/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.drewnoakes.com/code/dependancyanalyser/&lt;/a&gt;&amp;nbsp;)
&lt;br&gt;on the successfully compiled silverlight assemblies
&lt;br&gt;from the projects in question.
&lt;br&gt;&lt;br&gt;In the Dependency Analyzer Messages tab you see the below:
&lt;br&gt;&lt;br&gt;Processing assembly: Hello, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
&lt;br&gt;Hello depends upon:
&lt;br&gt;- mscorlib
&lt;br&gt;----------------------------------------------------------------
&lt;br&gt;Processing assembly: mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
&lt;br&gt;mscorlib depends upon:
&lt;br&gt;- System.Windows
&lt;br&gt;Unable to load assembly: System.Windows, Version=2.0.5.0, Culture=neutral, 
&lt;br&gt;PublicKeyToken=7cec85d7bea7798e
&lt;br&gt;System.IO.FileNotFoundException: Could not load file or assembly 
&lt;br&gt;'file:///K:\Webprojs\Silverlight\SilverBoo\__temp__\System.Windows.EXE' or one of its dependencies. 
&lt;br&gt;The system cannot find the file specified.
&lt;br&gt;File name: 'file:///K:\Webprojs\Silverlight\SilverBoo\__temp__\System.Windows.EXE'
&lt;br&gt;&amp;nbsp; &amp;nbsp; at System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBase, Evidence 
&lt;br&gt;assemblySecurity, Assembly locationHint, StackCrawlMark&amp; stackMark, Boolean throwOnFileNotFound, 
&lt;br&gt;Boolean forIntrospection)
&lt;br&gt;&amp;nbsp; &amp;nbsp; at System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase, Evidence 
&lt;br&gt;assemblySecurity, Assembly locationHint, StackCrawlMark&amp; stackMark, Boolean throwOnFileNotFound, 
&lt;br&gt;Boolean forIntrospection)
&lt;br&gt;&amp;nbsp; &amp;nbsp; at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, 
&lt;br&gt;StackCrawlMark&amp; stackMark, Boolean forIntrospection)
&lt;br&gt;&amp;nbsp; &amp;nbsp; at System.Reflection.Assembly.InternalLoadFrom(String assemblyFile, Evidence securityEvidence, 
&lt;br&gt;Byte[] hashValue, AssemblyHashAlgorithm hashAlgorithm, Boolean forIntrospection, StackCrawlMark&amp; 
&lt;br&gt;stackMark)
&lt;br&gt;&amp;nbsp; &amp;nbsp; at System.Reflection.Assembly.LoadFrom(String assemblyFile)
&lt;br&gt;&amp;nbsp; &amp;nbsp; at Drew.DependencyPlotter.AssemblyAnalyser.LoadAssemblyFromAssemblyName(AssemblyName assemblyName)
&lt;br&gt;&amp;nbsp; &amp;nbsp; at Drew.DependencyPlotter.AssemblyAnalyser.ProcessAssembly(Assembly assembly)
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;Why is it trying to load System.Windows.EXE ? &amp;nbsp;Apparently though,
&lt;br&gt;this is not a problem because when run under the Silverlight
&lt;br&gt;plug-in the stuff gets found.
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26570029&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26570029&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Loading-a-XAML-file-via-LoadComponent%28%29-tp26564594p26570029.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26568177</id>
	<title>am i wasting my time trying to use generics</title>
	<published>2009-11-29T16:55:39Z</published>
	<updated>2009-11-29T16:55:39Z</updated>
	<author>
		<name>psi-3</name>
	</author>
	<content type="html">subject changed
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26568177&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26568177&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/unable-to-access-a-private-field-of-an-instance-passed-to-a-static--method-tp26343591p26568177.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26568146</id>
	<title>Re: unable to access a private field of an instance passed to a  static method</title>
	<published>2009-11-29T16:51:47Z</published>
	<updated>2009-11-29T16:51:47Z</updated>
	<author>
		<name>psi-3</name>
	</author>
	<content type="html">am i wasting my time trying to use generics?
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26568146&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26568146&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/unable-to-access-a-private-field-of-an-instance-passed-to-a-static--method-tp26343591p26568146.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26568134</id>
	<title>Re: unable to access a private field of an instance passed to a  static method</title>
	<published>2009-11-29T16:50:36Z</published>
	<updated>2009-11-29T16:50:36Z</updated>
	<author>
		<name>psi-3</name>
	</author>
	<content type="html">chose of overload for generic method different between class and
&lt;br&gt;imported class!
&lt;br&gt;&lt;br&gt;&lt;br&gt;import System
&lt;br&gt;import System.Collections
&lt;br&gt;import System.Collections.Generic
&lt;br&gt;&lt;br&gt;&lt;br&gt;class c():
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; pass
&lt;br&gt;&lt;br&gt;def m(i as IEnumerable):
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return &amp;quot;a&amp;quot;
&lt;br&gt;&lt;br&gt;def m(i as IEnumerable[of Uri]):
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return &amp;quot;b&amp;quot;
&lt;br&gt;&lt;br&gt;&lt;br&gt;def m1(i as IEnumerable):
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return &amp;quot;a&amp;quot;
&lt;br&gt;&lt;br&gt;def m1(i as IEnumerable[of c]):
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return &amp;quot;b&amp;quot;
&lt;br&gt;&lt;br&gt;&lt;br&gt;a = array[of Uri](3)
&lt;br&gt;print m(a)
&lt;br&gt;&lt;br&gt;a1 = array[of c](3)
&lt;br&gt;print m1(a1)
&lt;br&gt;/*
&lt;br&gt;# Output @ Sun Nov 22 16:55:09 GMT 2009
&lt;br&gt;b
&lt;br&gt;a
&lt;br&gt;# Used (interp) :0:00.75 real, 0.64 user, 0.00 Sys
&lt;br&gt;*/
&lt;br&gt;/*
&lt;br&gt;# Output @ Sun Nov 22 17:12:40 GMT 2009
&lt;br&gt;b
&lt;br&gt;a
&lt;br&gt;# Used (interp) :0:00.70 real, 0.62 user, 0.04 Sys
&lt;br&gt;*/
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26568134&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26568134&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/unable-to-access-a-private-field-of-an-instance-passed-to-a-static--method-tp26343591p26568134.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26568116</id>
	<title>Re: unable to access a private field of an instance passed to a  static method</title>
	<published>2009-11-29T16:47:44Z</published>
	<updated>2009-11-29T16:47:44Z</updated>
	<author>
		<name>psi-3</name>
	</author>
	<content type="html">dont seem to be able to make a generic comparer,(which i think is
&lt;br&gt;required to be able to use binarysearch on a generic array.)
&lt;br&gt;&lt;br&gt;import System
&lt;br&gt;import System.Collections.Generic
&lt;br&gt;&lt;br&gt;class coor():
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; public x as double
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; public y as double
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; public z as double
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; def ToString():
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return &amp;quot;(${x:n1},${y:n1},${z:n1})&amp;quot;
&lt;br&gt;&lt;br&gt;&lt;br&gt;class compx[of coor](IComparer[of coor]):
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; def Compare(c1 as coor,c2 as coor):
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return c1.x-c2.x
&lt;br&gt;/*
&lt;br&gt;# Output @ Mon Nov 30 00:44:20 GMT 2009
&lt;br&gt;comptst.boo(14,19): BCE0019: Boo.Lang.Compiler.CompilerError: 'x' is
&lt;br&gt;not a member of 'coor'.
&lt;br&gt;comptst.boo(14,24): BCE0019: Boo.Lang.Compiler.CompilerError: 'x' is
&lt;br&gt;not a member of 'coor'.
&lt;br&gt;&lt;br&gt;Command exited with non-zero status 127
&lt;br&gt;# Used (interp) :0:00.58 real, 0.51 user, 0.01 Sys
&lt;br&gt;*/
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26568116&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26568116&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/unable-to-access-a-private-field-of-an-instance-passed-to-a-static--method-tp26343591p26568116.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26567494</id>
	<title>Re: Loading a XAML file via LoadComponent()</title>
	<published>2009-11-29T15:20:56Z</published>
	<updated>2009-11-29T15:20:56Z</updated>
	<author>
		<name>Andy Sy-2</name>
	</author>
	<content type="html">Ayende Rahien wrote:
&lt;br&gt;&amp;gt; Check all the references that you use, make sure they all use the 
&lt;br&gt;&amp;gt; appropriate mscorlib
&lt;br&gt;&lt;br&gt;How do I go about this? &amp;nbsp;Use Dependency Walker?
&lt;br&gt;I don't see them loading mscorlib.dll though...
&lt;br&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26567494&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26567494&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Loading-a-XAML-file-via-LoadComponent%28%29-tp26564594p26567494.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26567138</id>
	<title>Re: Loading a XAML file via LoadComponent()</title>
	<published>2009-11-29T14:44:35Z</published>
	<updated>2009-11-29T14:44:35Z</updated>
	<author>
		<name>Ayende Rahien-2</name>
	</author>
	<content type="html">&lt;div dir=&quot;ltr&quot;&gt;Check all the references that you use, make sure they all use the appropriate mscorlib&lt;br&gt;&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;On Mon, Nov 30, 2009 at 12:50 AM, Andy Sy &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://andy.sy&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;andy.sy&lt;/a&gt;@&lt;a href=&quot;http://neotitans.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;neotitans.com&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;
&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;&quot;&gt;&lt;div class=&quot;im&quot;&gt;Ayende Rahien wrote:&lt;br&gt;
&lt;br&gt;
 &amp;gt; I think that the problem is with the references that you use.&lt;br&gt;
 &amp;gt; Probably the issue is the reference to System.Object is not the same,&lt;br&gt;
 &amp;gt; because you are using two different assemblies.&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;This sounds like a plausible reason, how do I fix this?  And&lt;br&gt;
which two different assemblies are you referring to?&lt;br&gt;
&lt;br&gt;
&amp;gt; Try building with --nostdlib&lt;br&gt;
&lt;br&gt;
Is this different from -nostdlib ?  (-nostdlib is already specified&lt;br&gt;
in the build command, see below)&lt;br&gt;
&lt;div class=&quot;im&quot;&gt;&lt;br&gt;
&lt;br&gt;
&amp;gt;         booc -nostdlib -target:library ^&lt;br&gt;
&amp;gt;              -lib:&amp;quot;C:\Program Files (x86)\Reference&lt;br&gt;
&amp;gt;         Assemblies\Microsoft\Framework\Silverlight\v3.0&amp;quot; ^&lt;br&gt;
&amp;gt;              -lib:&amp;quot;C:\Program Files (x86)\Microsoft&lt;br&gt;
&amp;gt;         SDKs\Silverlight\v3.0\Libraries\Client&amp;quot; ^&lt;br&gt;
&amp;gt;              -lib:lib ^&lt;br&gt;
&amp;gt;              -r:system.dll -r:System.Windows.dll&lt;br&gt;
&amp;gt;         -r:System.Windows.Controls.dll ^&lt;br&gt;
&amp;gt;              -o:__temp__\Hello.dll ^&lt;br&gt;
&amp;gt;              src\Hello.boo&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;/div&gt;&lt;div class=&quot;h5&quot;&gt;--&lt;br&gt;
&lt;br&gt;
You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.&lt;br&gt;
To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26567138&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br&gt;
To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26567138&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang%2Bunsubscribe@...&lt;/a&gt;.&lt;br&gt;
For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;&lt;/div&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;--&lt;/p&gt;

You received this message because you are subscribed to the Google Groups &quot;Boo Programming Language&quot; group.&lt;br /&gt;

To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26567138&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.&lt;br /&gt;

To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26567138&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.&lt;br /&gt;

For more options, visit this group at http://groups.google.com/group/boolang?hl=en.&lt;br /&gt;

&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Loading-a-XAML-file-via-LoadComponent%28%29-tp26564594p26567138.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26567120</id>
	<title>Re: Loading a XAML file via LoadComponent()</title>
	<published>2009-11-29T14:42:11Z</published>
	<updated>2009-11-29T14:42:11Z</updated>
	<author>
		<name>Andy Sy-2</name>
	</author>
	<content type="html">Ayende Rahien wrote:
&lt;br&gt;&lt;br&gt;&amp;nbsp;&amp;gt; I think that the problem is with the references that you use.
&lt;br&gt;&amp;nbsp;&amp;gt; Probably the issue is the reference to System.Object is not the same,
&lt;br&gt;&amp;nbsp;&amp;gt; because you are using two different assemblies.
&lt;br&gt;&lt;br&gt;This sounds like a plausible reason, how do I fix this? &amp;nbsp;And
&lt;br&gt;which two different assemblies are you referring to?
&lt;br&gt;&lt;br&gt;&amp;gt; Try building with --nostdlib
&lt;br&gt;&lt;br&gt;Is this different from -nostdlib ? &amp;nbsp;(-nostdlib is already specified
&lt;br&gt;in the build command, see below)
&lt;br&gt;&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; booc -nostdlib -target:library ^
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;-lib:&amp;quot;C:\Program Files (x86)\Reference
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Assemblies\Microsoft\Framework\Silverlight\v3.0&amp;quot; ^
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;-lib:&amp;quot;C:\Program Files (x86)\Microsoft
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; SDKs\Silverlight\v3.0\Libraries\Client&amp;quot; ^
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;-lib:lib ^
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;-r:system.dll -r:System.Windows.dll
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; -r:System.Windows.Controls.dll ^
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;-o:__temp__\Hello.dll ^
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;src\Hello.boo
&lt;/div&gt;&lt;br&gt;--
&lt;br&gt;&lt;br&gt;You received this message because you are subscribed to the Google Groups &amp;quot;Boo Programming Language&amp;quot; group.
&lt;br&gt;To post to this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26567120&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang@...&lt;/a&gt;.
&lt;br&gt;To unsubscribe from this group, send email to &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26567120&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;boolang+unsubscribe@...&lt;/a&gt;.
&lt;br&gt;For more options, visit this group at &lt;a href=&quot;http://groups.google.com/group/boolang?hl=en&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/boolang?hl=en&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Boo-Lang---Users-f13996.html&quot; embed=&quot;fixTarget[13996]&quot; target=&quot;_top&quot; &gt;Boo Lang - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Loading-a-XAML-file-via-LoadComponent%28%29-tp26564594p26567120.html" />
</entry>

</feed>
