use g++ to compile c++
added removeAttribute and listAttributes (incl basic test cases), implements #1