forked from enlightenment/efl
eolian gen: automatically uppercase names for vars/constants
This commit is contained in:
parent
02aed9a043
commit
930af741b9
|
@ -153,6 +153,7 @@ _var_generate(const Eolian_Variable *vr, Eina_Bool legacy)
|
|||
while ((p = strchr(fn, '.')))
|
||||
*p = '_';
|
||||
}
|
||||
eina_str_toupper(&fn);
|
||||
if (!buf) buf = eina_strbuf_new();
|
||||
else eina_strbuf_append_char(buf, '\n');
|
||||
const Eolian_Type *vt = eolian_variable_base_type_get(vr);
|
||||
|
@ -262,6 +263,7 @@ void eo_gen_types_source_gen(const char *eof, Eina_Strbuf *buf)
|
|||
char *fn = strdup(eolian_variable_full_name_get(vr));
|
||||
for (char *p = strchr(fn, '.'); p; p = strchr(p, '.'))
|
||||
*p = '_';
|
||||
eina_str_toupper(&fn);
|
||||
|
||||
const Eolian_Type *vt = eolian_variable_base_type_get(vr);
|
||||
Eina_Stringshare *ct = eolian_type_c_type_get(vt);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
float Bar = 10.300000f;
|
||||
float BAR = 10.300000f;
|
||||
|
||||
Eina_Bool _class_simple_a_set(Eo *obj, Evas_Simple_Data *pd, int value);
|
||||
|
||||
|
|
|
@ -11,25 +11,25 @@ typedef Eo Class_Simple;
|
|||
#ifndef _CLASS_SIMPLE_EO_TYPES
|
||||
#define _CLASS_SIMPLE_EO_TYPES
|
||||
|
||||
#ifndef Foo
|
||||
#ifndef FOO
|
||||
/** doc for constant
|
||||
*
|
||||
* @ingroup Foo
|
||||
*/
|
||||
#define Foo 5
|
||||
#define FOO 5
|
||||
#endif
|
||||
|
||||
/** doc for global
|
||||
*
|
||||
* @ingroup Bar
|
||||
*/
|
||||
extern float Bar;
|
||||
extern float BAR;
|
||||
|
||||
/** in header but not in source
|
||||
*
|
||||
* @ingroup Baz
|
||||
*/
|
||||
extern long Baz;
|
||||
extern long BAZ;
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -11,25 +11,25 @@ typedef Eo Class_Simple;
|
|||
#ifndef _CLASS_SIMPLE_EO_TYPES
|
||||
#define _CLASS_SIMPLE_EO_TYPES
|
||||
|
||||
#ifndef Foo
|
||||
#ifndef FOO
|
||||
/** doc for constant
|
||||
*
|
||||
* @ingroup Foo
|
||||
*/
|
||||
#define Foo 5
|
||||
#define FOO 5
|
||||
#endif
|
||||
|
||||
/** doc for global
|
||||
*
|
||||
* @ingroup Bar
|
||||
*/
|
||||
extern float Bar;
|
||||
extern float BAR;
|
||||
|
||||
/** in header but not in source
|
||||
*
|
||||
* @ingroup Baz
|
||||
*/
|
||||
extern long Baz;
|
||||
extern long BAZ;
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -60,7 +60,7 @@ typedef Bar Alias;
|
|||
*
|
||||
* @ingroup pants
|
||||
*/
|
||||
extern int pants;
|
||||
extern int PANTS;
|
||||
|
||||
/** Opaque struct docs. See @ref Foo for another struct.
|
||||
*
|
||||
|
|
|
@ -60,7 +60,7 @@ typedef Bar Alias;
|
|||
*
|
||||
* @ingroup pants
|
||||
*/
|
||||
extern int pants;
|
||||
extern int PANTS;
|
||||
|
||||
/** Opaque struct docs. See @ref Foo for another struct.
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue