Bug 934125 - 1/3: s/function \+(/function(/ . r=gene

RILDIRS="dom/cellbroadcast/ dom/icc/ dom/mobilemessage/ dom/network/ dom/telephony/ dom/voicemail/ dom/system/gonk/";
for f in `find $RILDIRS -type f -name \*.js -o -name \*.jsm`; do
  sed -i $f -e 's/function \+(/function(/';
done
Bug 934125 - 2.a/3: s/\(\w\+\): function \(\w\+\)(/\1: function(/

RILDIRS="dom/cellbroadcast/ dom/icc/ dom/mobilemessage/ dom/network/ dom/telephony/ dom/voicemail/ dom/system/gonk/";
for f in `find $RILDIRS -type f -name \*.js -o -name \*.jsm`; do
  sed -i $f -e '/\w\+:/ {N; s/\(\w\+\):\s*function \(\w\+\)(/\1: function(/g}';
done
grep -nRe '\w\+: function \w\+(' $RILDIRS
Bug 934125 - 2.b/3: fix alignment. r=gene

for f in `git show --name-only | grep ^dom/`; do
  [ -n "`grep -e '\w\+: function([^)]*\$' $f`" ] && echo $f;
done | xargs sh -c 'rvim "$@" </dev/tty' asdf
Bug 934125 - 3.a/3: correct ril_worker 'RIL[FOO] = function FOO()' as well.

sed -i dom/system/gonk/ril_worker.js -e '/^RIL\[\w\+\] =/ {N; s/RIL\[\(\w\+\)\] =\s*function \w\+(/RIL[\1] = function(/}'
Bug 934125 - 3.b/3: fix alignment. r=gene