first part of #49 (& | ^ ~)
last tests for #49