forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitfe797b4
committed
Fix hard-coded relkind constants in pg_dump.c.
Although it's reasonable to expect that most of these constants willnever change, that does not make it good programming style to hard-codethe value rather than using the RELKIND_FOO macros. There were onlya few such violations, and all relatively new AFAICT.Existing style is mostly to inject relkind values into constructedquery strings using %c. I did not bother to touch places that did itlike that, but really a better technique is to stringify the RELKINDmacro, at least in places where you'd want single quotes around thecode character. That avoids any runtime effort and keeps the RELKINDsymbol close to where it's used.Discussion:https://postgr.es/m/11145.1488931324@sss.pgh.pa.us1 parent9cfc4de commitfe797b4
1 file changed
+13
-9
lines changedLines changed: 13 additions & 9 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2208 | 2208 |
| |
2209 | 2209 |
| |
2210 | 2210 |
| |
2211 |
| - | |
2212 |
| - | |
| 2211 | + | |
| 2212 | + | |
2213 | 2213 |
| |
2214 | 2214 |
| |
2215 | 2215 |
| |
2216 | 2216 |
| |
2217 |
| - | |
| 2217 | + | |
| 2218 | + | |
2218 | 2219 |
| |
2219 | 2220 |
| |
2220 | 2221 |
| |
| |||
2224 | 2225 |
| |
2225 | 2226 |
| |
2226 | 2227 |
| |
2227 |
| - | |
| 2228 | + | |
| 2229 | + | |
2228 | 2230 |
| |
2229 | 2231 |
| |
2230 | 2232 |
| |
2231 |
| - | |
| 2233 | + | |
2232 | 2234 |
| |
2233 | 2235 |
| |
2234 | 2236 |
| |
| |||
5466 | 5468 |
| |
5467 | 5469 |
| |
5468 | 5470 |
| |
5469 |
| - | |
| 5471 | + | |
| 5472 | + | |
5470 | 5473 |
| |
5471 | 5474 |
| |
5472 | 5475 |
| |
| |||
6174 | 6177 |
| |
6175 | 6178 |
| |
6176 | 6179 |
| |
6177 |
| - | |
| 6180 | + | |
| 6181 | + | |
6178 | 6182 |
| |
6179 | 6183 |
| |
6180 | 6184 |
| |
| |||
14835 | 14839 |
| |
14836 | 14840 |
| |
14837 | 14841 |
| |
14838 |
| - | |
| 14842 | + | |
14839 | 14843 |
| |
14840 | 14844 |
| |
14841 | 14845 |
| |
| |||
14867 | 14871 |
| |
14868 | 14872 |
| |
14869 | 14873 |
| |
14870 |
| - | |
| 14874 | + | |
14871 | 14875 |
| |
14872 | 14876 |
| |
14873 | 14877 |
| |
|
0 commit comments
Comments
(0)