# on known length ffi array

  • From: Justin Cormack <justin@xxxxxxxxxxxxxxxxxxxxx>
  • To: luajit@xxxxxxxxxxxxx
  • Date: Sat, 9 Jun 2012 00:00:38 +0100

Would it be possible for the # operator to work on known length C arrays?
(not VLAs or cast pointers obviously). eg if I have a = ffi.new("int[8]")
then #a == 8.

It would make array returns a bit more array like in Lua (obviously 0
based).

Just a thought... probably reasons why not...

Justin

Other related posts: