bug in "git diff -w" output?

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

 



hi all

i'm not sure i understand the output of "git diff -w" in the example below.  
to my eye, it seems incorrect around lines 53 and 54.

this example was done using the git version which originally introduced the -w 
and -b flags to diff.  the "dirty" in the version is a modified prefix in 
Makefile. similar output is generated by the latest git version 
1.4.3.rc2.ge19ff.

     1	$ git version 1.4.1.rc1.g0d21e-dirty
     2	
     3	$ git init-db
     4	defaulting to local storage area

     5	$ cat <<EOF > x
     6	do {
     7	   nothing;
     8	} while (0);
     9	EOF

    10	$ git add x
    11	$ git commit -m "foo" x
    12	Committing initial tree 30cd2f91b2797cd3b657a5a03f3e7468253d8dce

    13	$ cat <<EOF > x
    14	do
    15	  {
    16	     nothing;
    17	}
    18	while (0);
    19	EOF

    20	$ git diff
    21	diff --git a/x b/x
    22	index adf3937..64671c6 100644
    23	--- a/x
    24	+++ b/x
    25	@@ -1,3 +1,5 @@
    26	-do {
    27	-   nothing;
    28	-} while (0);
    29	+do
    30	+  {
    31	+     nothing;
    32	+}
    33	+while (0);

    34	$ git diff -b
    35	diff --git a/x b/x
    36	index adf3937..64671c6 100644
    37	--- a/x
    38	+++ b/x
    39	@@ -1,3 +1,5 @@
    40	-do {
    41	+do
    42	+  {
    43	    nothing;
    44	-} while (0);
    45	+}
    46	+while (0);

    47	$ git diff -w
    48	diff --git a/x b/x
    49	index adf3937..64671c6 100644
    50	--- a/x
    51	+++ b/x
    52	@@ -1,3 +1,5 @@
    53	 do {
    54	+  {
    55	    nothing;
    56	-} while (0);
    57	+}
    58	+while (0);


ray
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]