Return-Path: X-Original-To: apmail-incubator-flex-dev-archive@minotaur.apache.org Delivered-To: apmail-incubator-flex-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id C2311E7A5 for ; Sat, 29 Dec 2012 12:38:22 +0000 (UTC) Received: (qmail 10418 invoked by uid 500); 29 Dec 2012 12:38:22 -0000 Delivered-To: apmail-incubator-flex-dev-archive@incubator.apache.org Received: (qmail 10395 invoked by uid 500); 29 Dec 2012 12:38:21 -0000 Mailing-List: contact flex-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: flex-dev@incubator.apache.org Delivered-To: mailing list flex-dev@incubator.apache.org Received: (qmail 10379 invoked by uid 99); 29 Dec 2012 12:38:21 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 29 Dec 2012 12:38:21 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [69.167.147.50] (HELO franklin.liquidweb.com) (69.167.147.50) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 29 Dec 2012 12:38:14 +0000 Received: from localhost ([127.0.0.1]:50389) by franklin.liquidweb.com with esmtpsa (TLSv1:DHE-RSA-AES256-SHA:256) (Exim 4.80) (envelope-from ) id 1Tovfj-0005Qo-Ed for flex-dev@incubator.apache.org; Sat, 29 Dec 2012 07:37:51 -0500 Received: from 72.92.129.142 ([72.92.129.142]) by franklin.liquidweb.com (Horde Framework) with HTTP; Sat, 29 Dec 2012 07:37:51 -0500 Message-ID: <20121229073751.20581a4w2iur982n@franklin.liquidweb.com> Date: Sat, 29 Dec 2012 07:37:51 -0500 From: Michael Schmalle To: flex-dev@incubator.apache.org Subject: Writable AST and Code generation for Falcon was: [Re: [jira] [Commented] (FLEX-33330) ... ) References: <20121228193142.91122vsuu8qkuga6@franklin.liquidweb.com> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; DelSp="Yes"; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: 7bit User-Agent: Dynamic Internet Messaging Program (DIMP) H3 (1.1.8) X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - franklin.liquidweb.com X-AntiAbuse: Original Domain - incubator.apache.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - teotigraphix.com X-Get-Message-Sender-Via: franklin.liquidweb.com: authenticated_id: teotigra/from_h X-Source: X-Source-Args: X-Source-Dir: X-Virus-Checked: Checked by ClamAV on apache.org Quoting Roland Zwaga : > On 29 December 2012 01:31, Michael Schmalle wrote: > >> Wow, Roland you didn't even tell me you were up to no good with asblocks! >> > > Well, it was Christmas time, so I didn't want to bother you :) > > >> I'm glad that freakin year of messing around produced something worth >> while! >> > > True, at least ONE app has been made using your library, that definitely > makes up for a year's worth of hard labour, doesn't it? :) > > >> BTW, in my laboratory of parser/compiler madness I am dreaming up a way to >> make Falcon have writable AST so it can act like jasblocks does and >> read-write ActionScript. Linked tokens from the parser/tokenizer is the >> first hurdle but, I could see some nice utility possibilities with a >> framework extension like that. >> > > A writeable AST would be absolutely a must if we would ever want to > implement any kind of compile-time AOP functionality. So if that could be > done eventually, I think this would GREATLY improve the possibilities of > the compiler. (Not just from an AOP perspective, all sorts of compile-time > code generation could be added, I'm pretty sure Michael Labriola has a few > ideas for this :)) > If somehow the compiler can be used through a ANE (AIR Native Extension) > than little apps like the one I made here with ASBlocks could become even > easier to build, plus the parsing times would become unnoticable. > I'll be happy to help out in these cases, so once you get around to it > let's brainstorm :) Why couldn't it? I was thinking about that yesterday. It would be the data exchange format that would have to be agreed upon, XML, binary? What do you think. It would have to be something that the framework in asblocks could easily decorate with it's existing API. Honestly, it seems like I'm in Apache Flex camp for a while so its the JS compiler, ASDoc and code generation that I'm going to work on. Like I said, when they designed Falcon they are not saving the token stream like my parsers did which makes this whole, read, write edit A LOT harder. Actually it's the edit that would be broken. With AOP (I'm not to versed on it) but it seems to me that would be easy to add. Since altering AST during compile is just managing API addition and updating. You are not worried about producing end product code that had the exact same formatting as the original source code did. Which is when editing is out of the question right now with the Falcon compiler. I'm going to do some experiments, I'll let you know. > >> Anyway Roland great job and I saw your pull request, I didn't get notified >> for it. >> > > I might have some more pull requests in the future for ASBlocks (I think > I'll add a addStatementAt(index:int, statement:IAStatement) method to the > IASMethod implementations for instance). I'll send you an email when I do, > if github refuses to notify you, I'll just do it manually :) > Right, I'm sure you won't break anything so I will just commit them. Mike -- Michael Schmalle - Teoti Graphix, LLC http://www.teotigraphix.com http://blog.teotigraphix.com