Package: astyle Version: 1.23-1 Severity: normal I wanted to use astyle to format my sources for the linux kernel. I noticed that it is really not what I would expect. For comparison use linux-2.6/scripts/Lindent.
I used `astyle --style=linux` for my tests which was described as "Also known as Kernel Normal Form (KNF) style, this is the style used in the Linux kernel." First thing I noticed is that astyle uses 8 spaces for indention instead of a tab which should have a with of 8 spaces in an editor. Adding `--indent=tab=8` didn't help. Also { after a function starts at the same line like the function header when the return type is a 'struct' like "struct list" - which isn't the style used in the kernel. It doesn't look like 80 line width is used like in indent. There are many other things I haven't completely understood yet. For example Lindent: if (NULL != (val = xmlNodeGetContent(cur_node->children))) { used_val = 0; astyle: if (NULL != (val = xmlNodeGetContent(cur_node->children))) { used_val = 0; --- System information. --- Architecture: amd64 Kernel: Linux 2.6.31-1-amd64 Debian Release: squeeze/sid 500 unstable ftp.debian.org --- Package information. --- Depends (Version) | Installed ===========================-+-============= libc6 (>= 2.2.5) | 2.10.2-2 libgcc1 (>= 1:4.1.1) | 1:4.4.2-6 libstdc++6 (>= 4.2.1) | 4.4.2-6 -- Robert Wohlrab -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org