lkml.org 
[lkml]   [2012]   [Feb]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH v3] Input: Add EVIOC mechanism for MT slots
Hi Chase,

> > +#define INPUT_MT_REQUEST(num_slots) \
> > + { \
> > + __u32 code; \
> > + __s32 values[num_slots]; \
>
> I think this assumes a userspace C compiler that can handle variable
> length arrays. This would require only compiling in C source code at the
> C99 standard or later. It looks like C++ doesn't even allow variable
> length arrays, though gcc handles it. According to:
>
> http://www.cplusplus.com/forum/beginner/1601/
>
> it looks like Borland c++ compilers may not be able to compile this :(.

This is resolved on the preprocessor level, so C99 or not does not
enter the problem. Compile-time constant, as you can see in the code
example in the patch summary.

Thanks,
Henrik


\
 
 \ /
  Last update: 2012-02-03 08:29    [W:0.063 / U:0.140 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site