<div dir="ltr">And how should I deal with the files, which has all the 3 functions in them? Should I add them in one of the 3 patches or should I add them in all the 3 patches?<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">
On Thu, Jun 6, 2013 at 12:24 AM, Kenneth Graunke <span dir="ltr"><<a href="mailto:kenneth@whitecape.org" target="_blank">kenneth@whitecape.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
This patch is really doing three related, but independent things:<br>
1. Renaming _mesa_lookup_prim_by_nr() to _mesa_prim_string()<br>
2. Renaming _mesa_lookup_enum_by_nr() to _mesa_enum_string()<br>
3. Renaming _mesa_lookup_enum_by_name() to _mesa_enum_value()<br>
<br>
Generally, a patch should only do one thing at a time.  This has a number of benefits:<br>
- Patches are smaller and easier for people to review.<br>
- If a reviewer doesn't like the way you did something (for example, prefers a different name), you can redo and resubmit that one part instead of the whole thing.  This is less work for you and also easier on reviewers.<br>

- If something breaks, people tracking it down via 'git bisect' will find a small, specific change that caused the problem rather than a large change that does many things.<br>
- Small patches are easier to revert, if there is something broken.<br>
<br>
I realize this is a bit pedantic for this particular patch, but I'd still prefer to see it as three separate patches:<br>
<br>
mesa: Rename _mesa_lookup_prim_by_nr() to _mesa_prim_string().<br>
mesa: Rename _mesa_lookup_enum_by_nr() to _mesa_enum_string().<br>
mesa: Rename _mesa_lookup_enum_by_name() to _mesa_enum_value().<br>
<br>
You'll also notice that our commit titles start with a prefix for the particular area of code they touch.  For example, src/glsl starts with "glsl: ", src/drivers/dri/i965 starts with "i965: ", and src/mesa/main (or generally anything not fitting a specific category) starts with "mesa: ".  If you're not sure what prefix to use, run 'git log' on a file to see what other people have done.<br>

<br>
--Ken<br>
</blockquote></div><br></div>