You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
549 B

  1. from __future__ import print_function
  2. import sys
  3. sys.path.append('.')
  4. from example import StringList, print_opaque_list
  5. from example import return_void_ptr, print_void_ptr
  6. from example import return_null_str, print_null_str
  7. from example import return_unique_ptr
  8. l = StringList()
  9. l.push_back("Element 1")
  10. l.push_back("Element 2")
  11. print_opaque_list(l)
  12. print("Back element is %s" % l.back())
  13. l.pop_back()
  14. print_opaque_list(l)
  15. print_void_ptr(return_void_ptr())
  16. print(return_null_str())
  17. print_null_str(return_null_str())
  18. print(return_unique_ptr())