Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] RFC: Templates preprocessor syntax proposal

I'm currently studying how to refurbish the templates mechanism, aiming for a more elaborate GNU ARM Eclipse wizard, based on components.

The current CDT templates engine provides only simple substitution capabilities.

My needs include scripting, to implement conditional and possibly iterative code.

To cut a long story short, the proposal is to encode in the template files both JavaScript and the application code (in my case C/C++).

Processing the templates should be done in two steps:

- an Eclipse plug-in will convert the template into a plain JavaScript code
- a JS runtime will run the JS code in the environment of the template, with different selections from the wizard

The long story is available from http://xcdl.github.io/work/preprocessor/.

Any comments on this approach?

Regards,

Liviu


p.s. Personally I'm slowly moving my projects away from XML and closer to JSON and JavaScript.












Back to the top