[DGD] Bugz
Felix A. Croes
felix at dworkin.nl
Wed Apr 24 23:04:01 CEST 2013
Blain <blain20 at gmail.com> wrote:
> Error 1:
> [Compile] /sys/lib/user/api/io[18]: syntax error
>
> Error 2:
> [Compile] /sys/lib/user/api/io[20]: undeclared variable INHERITABLE_SUBDIR
>
>
> Error 1 isn't very helpful, to say the least.
That's what you get when playing with macros. That said, I knew I should
never have made the subdirs configurable with macros. :(
> I stumbled upon error 2
> while working with Shentino to figure out what the syntax error was exactly.
A perfectly reasonable errormessage.
> After fixing that, I get a second problem that is a bit more important. I
> can't set an object to this type-forced object. I can work around it by
> checking inheritance outside of the funcspec, though.
>
> Test 1:
> #include <config.h>
> #include <kernel/user.h>
>
> private object user;
>
> void start(object LIB_USER new_user)
> if(user && new_user != user) (<< line 22)
>
> Error 1:
> [Compile] /sys/lib/user/api/io[22]: incompatible types for equality
> (object, object)
This is a genuine problem. However, you can just declare the global
variable in the same way:
private void object LIB_USER user;
Regards,
Felix Croes
More information about the DGD
mailing list