Re: flags_t

From: Jes Sorensen (jes@linuxcare.com)
Date: Wed Aug 23 2000 - 15:05:04 EST


>>>>> "Cesar" == Cesar Eduardo Barros <cesarb@nitnet.com.br> writes:

Cesar> I have always been annoyed by the fact that save/restore_flags
Cesar> save/restore the flags using an unsigned long variable. I think
Cesar> it would be clearer to use

Cesar> typedef struct { unsigned long _flags; } flags_t;

Cesar> or something like that.

No it wouldn't, on some architectures it is safe to do safe_flags() on
a short type, like a short which can then be used in the architecture
specific code.

typedef's for the sake of typedef's is not a good idea.

Jes
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Wed Aug 23 2000 - 21:00:09 EST