demo the c++ bind implementation