I think Vala is missing some minor features related to type declarations
(such as structs and enums) that both C and C++ have and are really
useful.
For example, if you are to declare a single struct in C or C++, you can
just do:
---
struct {
int id;
float mass;
} Object;
Wolter Hellmund wrote:
I think Vala is missing some minor features related to type declarations
(such as structs and enums) that both C and C++ have and are really
useful.
For example, if you are to declare a single struct in C or C++, you can
just do:
---
struct {
int id;
To get some of these tricks to work it would be helpful to be able to pass the
C type underlying the vala type as a macro parameter.
I've a bug with patches that does this using typeof() to emit the C typesymbol
but it doesn't meet Juerg's syntax expactations.
As interfacing with c macros is
I don't see the benefit of these forms versus
struct Object {
int id;
float mass;
}
respectively
enum Process {
CONSTRUCT,
RUN,
DESTROY
}
or did you miss that these are available?
Oh, I totally missed that! I thought those were typedef kind of
Wolter Hellmund wrote:
I don't see the benefit of these forms versus
struct Object {
int id;
float mass;
}
respectively
enum Process {
CONSTRUCT,
RUN,
DESTROY
}
or did you miss that these are available?
Oh, I totally missed that! I thought those were
On Mon, 2009-11-02 at 21:16 +0100, Frederik wrote:
They are type definitions. I don't think this is what you meant.
struct MyStruct {
// ...
}
...
MyStruct my_struct = ...
I think you wanted to define a variable of an anonymous struct/enum type
(i.e. without naming
Pascal lets you have a bitwise set from an enum using
Set of ENUMTYPE
Sam
-Original Message-
From: pancake panc...@youterm.com
Sent: 02 November 2009 18:42
To: Vala ML vala-list@gnome.org
Subject: Re: [Vala] Minor features request (about structs and enums)
Michael 'Mickey' Lauer
we will probably use that syntax in Genie as thats what Delphi does as
well although i may just use:
Flags
flag1
flag2
etc
jamie
On Mon, 2009-11-02 at 21:34 +, Sam Liddicott wrote:
Pascal lets you have a bitwise set from an enum using
Set of ENUMTYPE
Sam
import themwith Pragmas
On Nov 2, 2009 2:03 PM, Sam Liddicott s...@liddicott.com wrote:
To get some of these tricks to work it would be helpful to be able to pass
the C type underlying the vala type as a macro parameter.
I've a bug with patches that does this using typeof() to emit the C