Why is lib/modules so much better than module.pmod.in?
/ Martin Nilsson (saturator)
Previous text:
2003-09-24 09:25: Subject: foo
Nilsson, did you have any good way of inserting Regexp.PCRE?
I want to write the glue in lib/modules, but I'm getting fuzzed by the compilation orders (again). Is it supposed to work like this?
- I moved Regexp (the c+pike glue) to Regexp.Builtin,
using MODULE_INIT() location setting
- I make Regexp.pmod/module.pmod inherit Regexp.Builtin,
and then this happens:
| > Regexp("["); | Cannot call undefined lfun `(). | > indices(Regexp); | (1) Result: ({ /* 11 elements */ | "`()", ...and the rest that should be there... | "Builtin", | "module", | "___Builtin", | }) | > Regexp["`()"]("hej"); | (2) Result: Regexp.SimpleRegexp(hej)
There's nothing magical about the old Regexp module,
| SimpleRegexp `()(void|string regexp) { return SimpleRegexp(regexp); }
so what's going on? Why does `[] work but not `->?
/ Mirar