comp.lang.ada
 help / color / mirror / Atom feed
From: Reto Buerki <reet@codelabs.ch>
Subject: Re: Announce: D_Bus/Ada, talk with your desktop in Ada
Date: Mon, 5 Dec 2011 12:12:54 +0000 (UTC)
Date: 2011-12-05T12:12:54+00:00	[thread overview]
Message-ID: <slrnjdpda6.8ba.reet@fenrir.codelabs.ch> (raw)
In-Reply-To: op.v50ldhlcule2fv@douda-yannick

On 2011-12-05, Yannick Duchêne <yannick_duchene@yahoo.fr> wrote:
> Le Mon, 05 Dec 2011 12:17:30 +0100, Reto Buerki <reet@codelabs.ch> a écrit:
>> [2] - http://www.codelabs.ch/dbus-ada
> At the bottom of the above page, in section “Examples”, there's a
>
>
>      with D_Bus.Arguments.Basic;
>      with D_Bus.Arguments.Containers;
>
> Then later
>
>      pragma Unreferenced (D_Bus.Arguments.Basic);
>      pragma Unreferenced (D_Bus.Arguments.Containers);
>
>
> Do you withed both for initialization side effects ?

No. This is needed to make the basic and container types known to the
D_Bus/Ada type system. D_Bus/Ada uses generic dispatching to create
Arguments from low-level D-Bus message arguments.

The example does not use specific argument extensions, that's why both
packages are Unreferenced.

E.g. if you remove 'with D_Bus.Arguments.Containers' in this example
you'll get:

raised D_BUS.D_BUS_ERROR : Unknown type code 'a' in message

The type system does not know how to deserialize the D-Bus ARRAY(97)
type.

- reto



  reply	other threads:[~2011-12-05 12:12 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-05 11:17 Announce: D_Bus/Ada, talk with your desktop in Ada Reto Buerki
2011-12-05 11:40 ` Yannick Duchêne (Hibou57)
2011-12-05 12:12   ` Reto Buerki [this message]
2011-12-05 11:45 ` Yannick Duchêne (Hibou57)
2011-12-05 12:27   ` Reto Buerki
2011-12-05 19:43 ` Tero Koskinen
2011-12-06  8:02   ` Reto Buerki
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox