diff options
author | Jérémy Zurcher <jeremy.zurcher@heraeus.com> | 2011-04-18 10:51:24 +0200 |
---|---|---|
committer | Jérémy Zurcher <jeremy.zurcher@heraeus.com> | 2011-04-18 10:51:24 +0200 |
commit | b1da07fc80bb63e21ef38d3632f6175d7e623be0 (patch) | |
tree | 48e28d4a8c7f8d9344499d7e04185122245176c2 /tools | |
parent | 56af88aeceb10b0c66f4a26227e8980654c6c587 (diff) | |
download | ffi-efl-b1da07fc80bb63e21ef38d3632f6175d7e623be0.zip ffi-efl-b1da07fc80bb63e21ef38d3632f6175d7e623be0.tar.gz |
update sed-enums, add sed-calbacks
Diffstat (limited to 'tools')
-rw-r--r-- | tools/sed-callbacks | 1 | ||||
-rw-r--r-- | tools/sed-enums | 6 |
2 files changed, 4 insertions, 3 deletions
diff --git a/tools/sed-callbacks b/tools/sed-callbacks new file mode 100644 index 0000000..6fe6e5e --- /dev/null +++ b/tools/sed-callbacks @@ -0,0 +1 @@ +/^\s*typedef\s+([a-zA-Z0-9_\* ]+?)\s+(\(\*)?(\w+)\)?\s*\(.*\);\s*$/p diff --git a/tools/sed-enums b/tools/sed-enums index ea7c5f7..3b6c7a5 100644 --- a/tools/sed-enums +++ b/tools/sed-enums @@ -1,14 +1,14 @@ -s/.*(enum\s+[a-zA-Z0-9_]+).*$/typedef \1 { / +s/.*(enum\s+\w+).*$/typedef \1 { / T;h :attrs;n s/^\s*([A-Z0-9_]+).*$/\1, / T next;H;b attrs :next /^\s*\}/ ! b attrs -s/^\s*}\s*([a-zA-Z0-9_]+).*$/ } \1;/ +s/^\s*}\s*(\w+).*$/ } \1;/ t finish :close -s/^\s*typedef\s+enum\s+[a-zA-Z0-9_]+\s+([a-zA-Z0-9_]+)\s+;/ } \1/ +s/^\s*typedef\s+enum\s+\w+\s+(\w+)\s+;/ } \1/ t finish;n;T close :finish H;x |