Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit e8bdea5

Browse files
committed
Fix message style
Mark one message not for translation, and prefer "cannot" over "may not", per commentary from Robert Haas. Discussion: https://postgr.es/m/20190430145813.GA29872@alvherre.pgsql
1 parent 438e519 commit e8bdea5

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

src/backend/access/heap/heapam.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -1301,7 +1301,7 @@ heap_getnext(TableScanDesc sscan, ScanDirection direction)
13011301
if (unlikely(sscan->rs_rd->rd_tableam != GetHeapamTableAmRoutine()))
13021302
ereport(ERROR,
13031303
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
1304-
errmsg("only heap AM is supported")));
1304+
errmsg_internal("only heap AM is supported")));
13051305

13061306
/* Note: no locking manipulations needed */
13071307

src/backend/access/table/tableamapi.c

+2-1
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,8 @@ check_default_table_access_method(char **newval, void **extra, GucSource source)
106106
{
107107
if (**newval == '\0')
108108
{
109-
GUC_check_errdetail("default_table_access_method may not be empty.");
109+
GUC_check_errdetail("%s cannot be empty.",
110+
"default_table_access_method");
110111
return false;
111112
}
112113

src/test/regress/expected/create_am.out

+1-1
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ NOTICE: drop cascades to index grect2ind2
110110
-- prevent empty values
111111
SET default_table_access_method = '';
112112
ERROR: invalid value for parameter "default_table_access_method": ""
113-
DETAIL: default_table_access_method may not be empty.
113+
DETAIL: default_table_access_method cannot be empty.
114114
-- prevent nonexistant values
115115
SET default_table_access_method = 'I do not exist AM';
116116
ERROR: invalid value for parameter "default_table_access_method": "I do not exist AM"

0 commit comments

Comments
 (0)