Fix demangling.

* remove some reasons why import could crash
* use case ignoring RE instead of plain .replace
  (cache those REs)