[Gsoc] 2013/07/19 Meeting Absence
marion.zepf at gmail.com
Fri Jul 19 18:24:01 EDT 2013
Sorry I couldn't make the meeting today. Here is my update:
This week, I wrote Primitive objects for the 'repeat' and 'start' block.
And I finally implemented the actual python export functionality. That
is, I added a module similar to the one for the Logo export tool. It takes
a stack of blocks, extracts their primitives and converts them into ASTs.
Then it glues the ASTs together in the same way the blocks were combined.
E.g., argument blocks become argument ASTs etc. Finally, it uses codegen
to transform the ASTs into python code.
I decided to use the 'codegen' module, since it lets me get the python code
as a string. (The 'unparse' module would write it directly to a file.) I
also added a menu item for the python export tool to the GNOME version of
I can now export a little block program that draws a square. Though, the
exported code doesn't work yet, since I haven't yet implemented special
handling of loops. (At the moment, a loop is just a call to a loop
function.) That's a task for next week.
If you want to take a look at my work, it's in the branch primitive-class of
Feedback and comments are welcome!
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the GSoC