make conses thread safe

@radumereuta please review
Can't you just make this one synchronized? I have no preference for what number I get in the end.