git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Darcs and git: plan of action

From
THTupshin Harper <tupshin@tupshin.com>
Date
Apr 19, 2005, 23:32 UTC
Message-ID
<426594F9.4090002@tupshin.com>
In-Reply-To
<1113951972.29444.42.camel@orca.madrabbit.org>
Ray Lee wrote:
Show 9 quoted lines
> I'm still not communicating well.
>
>Give me a case where assuming it's a replace will do the wrong thing,
>for C code, where it's a variable or function name.
>
>Ray
>
>-
>
I think you are communicating fine, but not fully understanding darcs.

try this: initial patch creates hello.c #include <stdio.h>

int main(int argc, char *argv[])
{
  printf("Hello world!\n");
  return 0;
}

second patch: replace ./hello.c [A-Za-z_0-9] world universe

third patch, for conceptual clarity, created in another repository that 
had seen the first patch, but not the second (adds function wide_world):
hunk ./hello.c 3
+void wide_world()
+{
+  printf("Hello wide world\n");
+}
+
hunk ./hello.c 11
+  wide_world();
}

If patch2 was a replace patch, then the result of running the combined 3 patch version would be: Hello universe! Hello wide universe

but if patch2 was a non-replace patch, then the result would be: Hello universe! Hello wide world

-Tupshin
Previous: Ray LeeNext: Ray Lee
Message 13 of 18 in “Re: [darcs-devel] Darcs and git: plan of action”
  1. linux@horizon.comApr 18, 2005
  2. Ray LeeApr 19, 2005
  3. Kevin SmithApr 19, 2005
  4. Ray LeeApr 19, 2005
  5. Kevin SmithApr 19, 2005
  6. Patrick McFarlandApr 19, 2005
  7. Ray LeeApr 19, 2005
  8. Tupshin HarperApr 19, 2005
  9. Ray LeeApr 19, 2005
  10. Tupshin HarperApr 19, 2005
  11. Kevin SmithApr 19, 2005
  12. Ray LeeApr 19, 2005
  13. Tupshin HarperApr 19, 2005
  14. Ray LeeApr 20, 2005
  15. Juliusz ChroboczekApr 20, 2005
  16. David RoundyApr 20, 2005
  17. Ralph CorderoyApr 20, 2005
  18. David RoundyApr 19, 2005

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.