arrayLengthConstant (TLStruct{ struct_name = sname, struct_fields = fields })
 = mapM_ arrayLengthConstant' fields
 where arrayLengthConstant' field
        = case field of
            StructField{ field_array = Scalar }
              -> return ()
            StructField{ field_name = fname, field_array = Fixed l }
              -> sayln' $ "#define " ++ arrayLenFixed sname fname ++ " " ++ show l
            StructField{ field_name = fname, field_array = Max l }
              -> sayln' $ "#define " ++ arrayLenMax sname fname ++ " " ++ show l
arrayLengthConstant (TLStruct{ struct_name = sname, struct_fields = fields })
 = mapM_ arrayLengthConstant' fields
 where arrayLengthConstant' field
        = case field of
            StructField{ field_array = Scalar }
              -> return ()
            StructField{ field_name = fname, field_array = Fixed l }
              -> sayln' $ "#define " ++ arrayLenFixed sname fname ++ " " ++ show l
            StructField{ field_name = fname, field_array = Max l }
              -> sayln' $ "#define " ++ arrayLenMax sname fname ++ " " ++ show l
arrayLengthConstant (TLStruct{ struct_name = sname, struct_fields = fields })
 = mapM_ arrayLengthConstant' fields
 where arrayLengthConstant' field
        = case field of
            StructField{ field_array = Scalar }
              -> return ()
            StructField{ field_name = fname, field_array = Fixed l }
              -> sayln' $ "#define " ++ arrayLenFixed sname fname ++ " " ++ show l
            StructField{ field_name = fname, field_array = Max l }
              -> sayln' $ "#define " ++ arrayLenMax sname fname ++ " " ++ show l