Re: [Vala] [PATCH] GType is a IntegerType + SimpleType



On Thu, 2009-06-25 at 16:09 +0800, Yu Feng wrote:
Refer to Sam's email on Jun 24th Switch statement on GType.

The reason why GType is not supported in switch statements is because
typeof expressions are not considered constant expressions. While there
are a few basic GTypes that are constants in C, this is not true for
types defined outside GLib.

If we apply your patch, valac will generate invalid C code if you use
typeof expressions that are not constant in C.

Jürg




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]