everything except theorem works