/trunk/Lib/attribute.i

# · Swig · 21 lines · 11 code · 4 blank · 6 comment · 0 complexity · 6f280df02db0b3e983dcad21ba6546bd MD5 · raw file

  1. /* -----------------------------------------------------------------------------
  2. * attribute.i
  3. *
  4. * SWIG library file for implementing attributes.
  5. * ----------------------------------------------------------------------------- */
  6. /* we use a simple exception warning here */
  7. %{
  8. #include <stdio.h>
  9. %}
  10. #define %attribute_exception(code,msg) printf("%s\n",msg)
  11. #ifndef %arg
  12. #define %arg(x) x
  13. #endif
  14. #ifndef %mangle
  15. #define %mangle(Type...) #@Type
  16. #endif
  17. %include <typemaps/attribute.swg>