You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by Aron Sogor <bi...@gmail.com> on 2010/06/07 21:51:22 UTC

Language support question.. Did anyone had to implement traversing the parsed data to create imports b4?

In other words:

has anyone implemented importing and using the FQ classname for any
OOO language?

The as3 port copies the java code generator. Makes sense since the
syntax is a lot like.

One gotcha in Java you do not need to use imports if you use the fully
qualified classname like:

some.thing.stuff mystuff= null;


Well AS3 does not like only:

Var mystuff:some.thing.stuff = null;


It seems it still needs the import if stuff is not in the same package.

like:

Import some.thing.stuff

Var mystuff:some.thing.stuff = null;



Did anyone had to implement traversing the parsed data to create imports b4?

Is there a nice piece of code we can borrow?

Aron

Re: Language support question.. Did anyone had to implement traversing the parsed data to create imports b4?

Posted by Aron Sogor <bi...@gmail.com>.
Well I guess that is what we will do :)

On Mon, Jun 7, 2010 at 1:35 PM, Bryan Duxbury <br...@rapleaf.com> wrote:
> Hm, interesting. I don't know of anywhere else that has this problem, but I
> can't imagine it being all that difficult to implement. If you make a really
> nice helper, be sure to put it somewhere that other generators could take
> advantage of.
>
> On Mon, Jun 7, 2010 at 12:51 PM, Aron Sogor <bi...@gmail.com> wrote:
>
>> In other words:
>>
>> has anyone implemented importing and using the FQ classname for any
>> OOO language?
>>
>> The as3 port copies the java code generator. Makes sense since the
>> syntax is a lot like.
>>
>> One gotcha in Java you do not need to use imports if you use the fully
>> qualified classname like:
>>
>> some.thing.stuff mystuff= null;
>>
>>
>> Well AS3 does not like only:
>>
>> Var mystuff:some.thing.stuff = null;
>>
>>
>> It seems it still needs the import if stuff is not in the same package.
>>
>> like:
>>
>> Import some.thing.stuff
>>
>> Var mystuff:some.thing.stuff = null;
>>
>>
>>
>> Did anyone had to implement traversing the parsed data to create imports
>> b4?
>>
>> Is there a nice piece of code we can borrow?
>>
>> Aron
>>
>

Re: Language support question.. Did anyone had to implement traversing the parsed data to create imports b4?

Posted by Bryan Duxbury <br...@rapleaf.com>.
Hm, interesting. I don't know of anywhere else that has this problem, but I
can't imagine it being all that difficult to implement. If you make a really
nice helper, be sure to put it somewhere that other generators could take
advantage of.

On Mon, Jun 7, 2010 at 12:51 PM, Aron Sogor <bi...@gmail.com> wrote:

> In other words:
>
> has anyone implemented importing and using the FQ classname for any
> OOO language?
>
> The as3 port copies the java code generator. Makes sense since the
> syntax is a lot like.
>
> One gotcha in Java you do not need to use imports if you use the fully
> qualified classname like:
>
> some.thing.stuff mystuff= null;
>
>
> Well AS3 does not like only:
>
> Var mystuff:some.thing.stuff = null;
>
>
> It seems it still needs the import if stuff is not in the same package.
>
> like:
>
> Import some.thing.stuff
>
> Var mystuff:some.thing.stuff = null;
>
>
>
> Did anyone had to implement traversing the parsed data to create imports
> b4?
>
> Is there a nice piece of code we can borrow?
>
> Aron
>