Move IO::Compress from ext/ to cpan/
[p5sagit/p5-mst-13.2.git] / t / lib / h2ph.h
index 9fd535d..78429ca 100644 (file)
 #undef MAX
 #define MAX(a,b) ((a) > (b) ? (a) : (b))
 
+/* Test #undef'ining an existing constant function */
+#define NOTTRUE 0
+#undef NOTTRUE
+
 /* Test #ifdef */
 #ifdef __SOME_UNIMPORTANT_PROPERTY
 #define MIN(a,b) ((a) < (b) ? (a) : (b))
 #    define WHATEVER 1000
 #endif
 
+/* Test passing through the alien constructs (perlbug #34493) */
+#ifdef __LANGUAGE_PASCAL__
+function Tru64_Pascal(n: Integer): Integer;
+#endif
+
 /* 
  * Test #include, #import and #include_next
  * #include_next is difficult to test, it really depends on the actual
  *  with `use lib qw(/opt/perl5/lib/site_perl/i586-linux/linux);' or whatever
  *  your equivalent is...
  */
+#if 0
 #include <sys/socket.h>
 #import "sys/ioctl.h"
 #include_next <sys/fcntl.h>
+#endif
 
 /* typedefs should be ignored */
 typedef struct a_struct {
@@ -98,4 +109,38 @@ typedef enum _days_of_week { sun, mon, tue, wed, thu, fri, sat, Sun=0, Mon,
 ??= define SOMETHING_ELSE_TRIGRAPHIC_8 "??>"          /* | ??>|  }| */
        ??=endif
 
+// test C++-style comment
+
+#if 1
+typdef struct empty_struct {
+} // trailing C++-style comment should not force continuation
+#endif
+
+/* comments (that look like string) inside enums... */
+
+enum {
+   /* foo;
+     can't
+   */                        
+ };
+
+enum flimflam {
+  flim,
+   /* foo;
+     can't
+   */
+  flam                      
+ } flamflim;
+
+/* Handle multi-line quoted strings: */
+__asm__ __volatile__("
+    this
+    produces
+    no
+    output
+");
+
+#define multiline "multiline
+string"
+
 #endif /* _H2PH_H_ */