Permalink
Browse files

headerizer now runs on PMC files

git-svn-id: https://svn.parrot.org/parrot/trunk@45219 d31e2699-5ff4-0310-a27c-f18f2fbe73fe
  • Loading branch information...
1 parent f3faadb commit 6bdd5f99ed1907d9fd54110a73af2671c724696a @petdance petdance committed Mar 28, 2010
Showing with 1,620 additions and 143 deletions.
  1. +4 −0 src/pmc/addrregistry.pmc
  2. +4 −0 src/pmc/arrayiterator.pmc
  3. +186 −3 src/pmc/bigint.pmc
  4. +575 −50 src/pmc/bignum.pmc
  5. +2 −0 src/pmc/boolean.pmc
  6. +78 −0 src/pmc/callcontext.pmc
  7. +4 −0 src/pmc/capture.pmc
  8. +49 −0 src/pmc/class.pmc
  9. +4 −0 src/pmc/codestring.pmc
  10. +20 −3 src/pmc/complex.pmc
  11. +4 −0 src/pmc/continuation.pmc
  12. +13 −0 src/pmc/coroutine.pmc
  13. +65 −18 src/pmc/default.pmc
  14. +5 −0 src/pmc/env.pmc
  15. +22 −0 src/pmc/eval.pmc
  16. +5 −0 src/pmc/eventhandler.pmc
  17. +4 −0 src/pmc/exception.pmc
  18. +4 −0 src/pmc/exceptionhandler.pmc
  19. +4 −0 src/pmc/exporter.pmc
  20. +4 −0 src/pmc/file.pmc
  21. +4 −0 src/pmc/filehandle.pmc
  22. +11 −0 src/pmc/fixedbooleanarray.pmc
  23. +4 −0 src/pmc/fixedfloatarray.pmc
  24. +4 −0 src/pmc/fixedintegerarray.pmc
  25. +4 −0 src/pmc/fixedpmcarray.pmc
  26. +4 −0 src/pmc/fixedstringarray.pmc
  27. +4 −0 src/pmc/float.pmc
  28. +4 −0 src/pmc/handle.pmc
  29. +4 −0 src/pmc/hash.pmc
  30. +4 −0 src/pmc/hashiterator.pmc
  31. +4 −0 src/pmc/hashiteratorkey.pmc
  32. +45 −0 src/pmc/imageio.pmc
  33. +4 −0 src/pmc/imageiosize.pmc
  34. +17 −0 src/pmc/integer.pmc
  35. +4 −0 src/pmc/iterator.pmc
  36. +4 −0 src/pmc/key.pmc
  37. +4 −0 src/pmc/lexinfo.pmc
  38. +4 −0 src/pmc/lexpad.pmc
  39. +4 −0 src/pmc/managedstruct.pmc
  40. +4 −0 src/pmc/multisub.pmc
  41. +49 −1 src/pmc/namespace.pmc
  42. +8 −4 src/pmc/nci.pmc
  43. +13 −0 src/pmc/null.pmc
  44. +33 −0 src/pmc/object.pmc
  45. +4 −0 src/pmc/opcode.pmc
  46. +4 −0 src/pmc/oplib.pmc
  47. +4 −0 src/pmc/orderedhash.pmc
  48. +4 −0 src/pmc/orderedhashiterator.pmc
  49. +4 −0 src/pmc/os.pmc
  50. +4 −0 src/pmc/packfile.pmc
  51. +4 −0 src/pmc/packfileannotation.pmc
  52. +4 −0 src/pmc/packfileannotations.pmc
  53. +4 −0 src/pmc/packfileconstanttable.pmc
  54. +4 −0 src/pmc/packfiledirectory.pmc
  55. +4 −0 src/pmc/packfilefixupentry.pmc
  56. +4 −0 src/pmc/packfilefixuptable.pmc
  57. +4 −0 src/pmc/packfilerawsegment.pmc
  58. +4 −0 src/pmc/packfilesegment.pmc
  59. +11 −4 src/pmc/parrotinterpreter.pmc
  60. +4 −0 src/pmc/parrotlibrary.pmc
  61. +4 −0 src/pmc/parrotrunningthread.pmc
  62. +9 −0 src/pmc/parrotthread.pmc
  63. +4 −0 src/pmc/pmcproxy.pmc
  64. +4 −0 src/pmc/pointer.pmc
  65. +4 −0 src/pmc/resizablebooleanarray.pmc
  66. +4 −0 src/pmc/resizablefloatarray.pmc
  67. +4 −0 src/pmc/resizableintegerarray.pmc
  68. +4 −0 src/pmc/resizablepmcarray.pmc
  69. +4 −0 src/pmc/resizablestringarray.pmc
  70. +4 −0 src/pmc/retcontinuation.pmc
  71. +14 −1 src/pmc/role.pmc
  72. +4 −0 src/pmc/scalar.pmc
  73. +4 −0 src/pmc/scheduler.pmc
  74. +4 −0 src/pmc/schedulermessage.pmc
  75. +4 −0 src/pmc/sockaddr.pmc
  76. +4 −0 src/pmc/socket.pmc
  77. +4 −0 src/pmc/string.pmc
  78. +14 −3 src/pmc/stringhandle.pmc
  79. +4 −0 src/pmc/stringiterator.pmc
  80. +12 −0 src/pmc/sub.pmc
  81. +4 −0 src/pmc/task.pmc
  82. +4 −0 src/pmc/timer.pmc
  83. +4 −0 src/pmc/undef.pmc
  84. +87 −27 src/pmc/unmanagedstruct.pmc
  85. +37 −29 tools/build/headerizer.pl
@@ -28,6 +28,10 @@ C<Parrot_register_pmc> if it isn't visible to Parrot.
#include "parrot/hash.h"
#include "pmc/pmc_hash.h"
+/* HEADERIZER HFILE: none */
+/* HEADERIZER BEGIN: static */
+/* HEADERIZER END: static */
+
pmclass AddrRegistry extends Hash provides hash auto_attrs {
/*
@@ -51,6 +51,10 @@ to avoid this caveat.
*/
+/* HEADERIZER HFILE: none */
+/* HEADERIZER BEGIN: static */
+/* HEADERIZER END: static */
+
pmclass ArrayIterator extends Iterator no_ro auto_attrs {
ATTR PMC *array; /* the array which this Iterator iterates */
ATTR INTVAL pos; /* Current position of iterator for forward iterator */
View
@@ -14,9 +14,9 @@ C<BigInt> provides arbitrary precision integer mathematic functions.
=over 4
-=item C<static void bigint_set_long(Interp*, PMC *, long value)>
+=item C<static void bigint_set_long(PARROT_INTERP, PMC *self, long value)>
-=item C<static void bigint_set_double(Interp*, PMC *, double value)>
+=item C<static void bigint_set_double(PARROT_INTERP, PMC *self, double value)>
=cut
@@ -35,6 +35,187 @@ typedef struct BIGINT {
} BIGINT;
+/* HEADERIZER BEGIN: static */
+/* Don't modify between HEADERIZER BEGIN / HEADERIZER END. Your changes will be lost. */
+
+static void bigint_abs(PARROT_INTERP, PMC *self, PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_add_bigint(PARROT_INTERP,
+ PMC *self,
+ PMC *value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_add_bigint_int(PARROT_INTERP,
+ PMC *self,
+ INTVAL value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_clear(PARROT_INTERP, PMC *self)
+ __attribute__nonnull__(1);
+
+static INTVAL bigint_cmp(PARROT_INTERP, PMC *self, PMC *value)
+ __attribute__nonnull__(1);
+
+static INTVAL bigint_cmp_int(PARROT_INTERP, PMC *self, INTVAL value)
+ __attribute__nonnull__(1);
+
+static void bigint_div_bigint(PARROT_INTERP,
+ PMC *self,
+ PMC *value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_div_bigint_int(PARROT_INTERP,
+ PMC *self,
+ INTVAL value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_fdiv_bigint(PARROT_INTERP,
+ PMC *self,
+ PMC *value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_fdiv_bigint_int(PARROT_INTERP,
+ PMC *self,
+ INTVAL value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+static double bigint_get_double(PARROT_INTERP, PMC *self)
+ __attribute__nonnull__(1);
+
+static long bigint_get_long(PARROT_INTERP, PMC *self)
+ __attribute__nonnull__(1);
+
+static BIGINT* bigint_get_self(PARROT_INTERP, PMC *self)
+ __attribute__nonnull__(1);
+
+static char * bigint_get_string(PARROT_INTERP, PMC *self, int base)
+ __attribute__nonnull__(1);
+
+static void bigint_mod_bigint(PARROT_INTERP,
+ PMC *self,
+ PMC *value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_mod_bigint_int(PARROT_INTERP,
+ PMC *self,
+ INTVAL value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_mul_bigint(PARROT_INTERP,
+ PMC *self,
+ PMC *value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_mul_bigint_int(PARROT_INTERP,
+ PMC *self,
+ INTVAL value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_neg(PARROT_INTERP, PMC *self, PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_pow_bigint_int(PARROT_INTERP,
+ PMC *self,
+ INTVAL value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_set(PARROT_INTERP, PMC *dest, PMC *src)
+ __attribute__nonnull__(1);
+
+static void bigint_set_double(PARROT_INTERP, PMC *self, double value)
+ __attribute__nonnull__(1);
+
+static void bigint_set_long(PARROT_INTERP, PMC *self, long value)
+ __attribute__nonnull__(1);
+
+static void bigint_set_self(PARROT_INTERP, PMC *self, BIGINT *value)
+ __attribute__nonnull__(1);
+
+static void bigint_set_str(PARROT_INTERP, PMC *self, char *value, int base)
+ __attribute__nonnull__(1);
+
+static void bigint_sub_bigint(PARROT_INTERP,
+ PMC *self,
+ PMC *value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+static void bigint_sub_bigint_int(PARROT_INTERP,
+ PMC *self,
+ INTVAL value,
+ PMC *dest)
+ __attribute__nonnull__(1);
+
+#define ASSERT_ARGS_bigint_abs __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_add_bigint __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_add_bigint_int __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_clear __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_cmp __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_cmp_int __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_div_bigint __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_div_bigint_int __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_fdiv_bigint __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_fdiv_bigint_int __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_get_double __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_get_long __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_get_self __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_get_string __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_mod_bigint __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_mod_bigint_int __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_mul_bigint __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_mul_bigint_int __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_neg __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_pow_bigint_int __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_set __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_set_double __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_set_long __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_set_self __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_set_str __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_sub_bigint __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+#define ASSERT_ARGS_bigint_sub_bigint_int __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+ PARROT_ASSERT_ARG(interp))
+/* Don't modify between HEADERIZER BEGIN / HEADERIZER END. Your changes will be lost. */
+/* HEADERIZER END: static */
+/* HEADERIZER HFILE: none */
+
static void
bigint_init(PARROT_INTERP, PMC *self) {
BIGINT * const bi = mem_gc_allocate_zeroed_typed(interp, BIGINT);
@@ -323,6 +504,8 @@ bigint_neg(PARROT_INTERP, PMC *self, PMC *dest) {
mpz_neg(bi_dest->b, bi_self->b);
}
+/* HEADERIZER STOP */
+
#else /* ifdef PARROT_HAS_GMP */
typedef struct BIGINT {
@@ -389,7 +572,7 @@ bigint_get_long(PARROT_INTERP, PMC *self) {
"no bigint lib loaded");
}
-static long
+static int
bigint_get_bool(PARROT_INTERP, PMC *self) {
Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_LIBRARY_ERROR,
"no bigint lib loaded");
Oops, something went wrong.

0 comments on commit 6bdd5f9

Please sign in to comment.