Safer string handling and enriched string API