I took a look to the Topcased UML to C generator, it seems that the default behavior for unknown primitive types is to generate "void*". I didn't see a simple way to add your custom type to the type translation table.

You should try the new generator made by Obeo : http://www.acceleo.org/wiki/index.php/UML_2.1_to_C
This generator is still in incubation phase but in the future, it should replace the Topcased UML2C generator. In this generator, the name of unknown primitive types is taken to produce the generated code, it is up to you to provide the type definition by including your own external libraries.
Feel free to provide any feedbacks on this new generator.

Regards,
Gonzague.

[email protected] a écrit :

Hello Gonzague,

 

I’ve tried that for C. I’ve already look on the template “header”, where is called something like “getCtype()”. More I did not yet checked.

 

Best regards,

 

Richard

RG Mechatronics

 

 

Von: [email protected] [mailto:[email protected]] Im Auftrag von [email protected]
Gesendet: Mittwoch, 29. April 2009 13:52
An: [email protected]
Betreff: Re: [Topcased-users] Question about new primitive type

 

Hello Richard,

Can you precise which code generator you are using here?

Best regards,
Gonzague Reydet
Obeo

[email protected] a écrit :

I want to add a new type int16 and I want to generate also this type with Acceleo. What I’ve found in docu: “Create a new primitive type…”.

But I can’t find how to specify a generated code. It always return “void*”. Exists some documentation about it, or some other hints?

 

Thank you

 

Richard

 


  
 
_______________________________________________
Topcased-users mailing list
[email protected]
http://lists.gforge.enseeiht.fr/mailman/listinfo/topcased-users




-- 
Gonzague Reydet
Obeo
Model Driven Company

_______________________________________________ Topcased-users mailing list [email protected] http://lists.gforge.enseeiht.fr/mailman/listinfo/topcased-users


-- 
Gonzague Reydet
Obeo
Model Driven Company
begin:vcard
fn:Gonzague Reydet
n:Reydet;Gonzague
org:Obeo
adr:;;2, roue de la Noue BP76;Gif-sur-Yvette;;91193;France
email;internet:[email protected]
tel;work:+331 64 86 58 22
x-mozilla-html:TRUE
url:http://www.obeo.fr/
version:2.1
end:vcard

_______________________________________________
Topcased-users mailing list
[email protected]
http://lists.gforge.enseeiht.fr/mailman/listinfo/topcased-users

Reply via email to