Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/xlint/lint1 provide __arraycount() if not there.
details: https://anonhg.NetBSD.org/src/rev/5532254ee198
branches: trunk
changeset: 761758:5532254ee198
user: christos <christos%NetBSD.org@localhost>
date: Mon Feb 07 00:26:27 2011 +0000
description:
provide __arraycount() if not there.
diffstat:
usr.bin/xlint/lint1/mkops | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diffs (20 lines):
diff -r 7759f4869ebf -r 5532254ee198 usr.bin/xlint/lint1/mkops
--- a/usr.bin/xlint/lint1/mkops Sun Feb 06 23:25:16 2011 +0000
+++ b/usr.bin/xlint/lint1/mkops Mon Feb 07 00:26:27 2011 +0000
@@ -1,5 +1,5 @@
#!/bin/sh -
-# $NetBSD: mkops,v 1.6 2011/02/06 23:03:02 pooka Exp $
+# $NetBSD: mkops,v 1.7 2011/02/07 00:26:27 christos Exp $
#
# Copyright (c) 2011 The NetBSD Foundation, Inc.
# All rights reserved.
@@ -67,6 +67,9 @@
printf("#include <sys/types.h>\n");
printf("#include \"op.h\"\n");
printf("#include \"param.h\"\n");
+ printf("#ifndef __arraycount\n");
+ printf("#define __arraycount(a) (sizeof(a) / sizeof(a[0]))\n");
+ printf("#endif /* __arraycount */\n");
printf("mod_t modtab[NOPS];\n");
printf("static const struct {\n");
printf("\tmod_t\tm;\n");
Home |
Main Index |
Thread Index |
Old Index