Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/kern Print "end of special cases" only where special cas...



details:   https://anonhg.NetBSD.org/src/rev/57d8580f8310
branches:  trunk
changeset: 753945:57d8580f8310
user:      pooka <pooka%NetBSD.org@localhost>
date:      Wed Apr 14 12:19:50 2010 +0000

description:
Print "end of special cases" only where special cases end and not
a second time at the end of the file.  Adjust whitespace for the
sheer functional joy of it.

(i hope i didn't ruin someone's joke by missing a humorous implication
that all vnode operations are considered a little special)

diffstat:

 sys/kern/vnode_if.sh |  15 +++++----------
 1 files changed, 5 insertions(+), 10 deletions(-)

diffs (60 lines):

diff -r d1b9bc500e96 -r 57d8580f8310 sys/kern/vnode_if.sh
--- a/sys/kern/vnode_if.sh      Wed Apr 14 11:52:39 2010 +0000
+++ b/sys/kern/vnode_if.sh      Wed Apr 14 12:19:50 2010 +0000
@@ -29,7 +29,7 @@
  * SUCH DAMAGE.
  */
 "
-SCRIPT_ID='$NetBSD: vnode_if.sh,v 1.54 2010/04/10 19:41:54 pooka Exp $'
+SCRIPT_ID='$NetBSD: vnode_if.sh,v 1.55 2010/04/14 12:19:50 pooka Exp $'
 
 # Script to produce VFS front-end sugar.
 #
@@ -244,8 +244,8 @@
        arg0special="";
        vop_offset = 1; # start at 1, to count the 'default' op
 
-       printf("\n/* Special cases: */\nstruct buf;\n");
-       printf("#ifndef _KERNEL\n#include <stdbool.h>\n#endif\n\n");
+       printf("/* Special cases: */\n\nstruct buf;\n");
+       printf("#ifndef _KERNEL\n#include <stdbool.h>\n#endif\n");
 
        argc=1;
        argtype[0]="struct buf *";
@@ -254,7 +254,7 @@
        arg0special="->b_vp";
        name=rump "vop_bwrite";
        doit();
-       printf("/* End of special cases */\n");
+       printf("\n/* End of special cases */\n");
 }
 END    {
        printf("\n#define VNODE_OPS_COUNT\t%d\n", vop_offset);
@@ -262,8 +262,6 @@
 '"$awk_parser" | sed -e "$anal_retentive"
 
 # End stuff
-echo '
-/* End of special cases. */'
 echo ''
 echo "#endif /* !_${SYS}VNODE_IF_H_ */"
 }
@@ -439,8 +437,6 @@
 '"$awk_parser" | sed -e "$anal_retentive"
 
 # End stuff
-echo '
-/* End of special cases. */'
 
 # Add the vfs_op_descs array to the C file.
 # Begin stuff
@@ -459,8 +455,7 @@
 
 # End stuff
 echo ' NULL
-};
-'
+};'
 }
 do_cfile $out_c ''
 do_cfile $out_rumpc 'rump_'



Home | Main Index | Thread Index | Old Index