database.h.in constify various TileTypeBitMask* data usages

This commit is contained in:
Darryl L. Miles 2025-01-31 19:46:43 +00:00 committed by R. Timothy Edwards
parent 6ec826fb8b
commit ef79d33dd4
3 changed files with 11 additions and 10 deletions

View File

@ -677,7 +677,7 @@ dbCellLabelSrFunc(scx, fp)
{
Label *lab;
Rect *r = &scx->scx_area;
TileTypeBitMask *mask = fp->tf_mask;
const TileTypeBitMask *mask = fp->tf_mask;
CellDef *def = scx->scx_use->cu_def;
char *tnext;
int result;

View File

@ -474,7 +474,7 @@ dbSrConnectFunc(tile, csa)
int i, pNum;
int result = 0;
bool callClient;
TileTypeBitMask *connectMask;
const TileTypeBitMask *connectMask;
TileType loctype, checktype;
PlaneMask planes;
@ -826,7 +826,7 @@ dbcConnectLabelFunc(scx, lab, tpath, csa2)
CellDef *orig_def = scx->scx_use->cu_def;
Label *slab;
int lidx = lab->lab_port;
TileTypeBitMask *connectMask;
const TileTypeBitMask *connectMask;
/* Check for equivalent ports. For any found, call */
/* DBTreeSrTiles recursively on the type and area */
@ -940,7 +940,8 @@ dbcConnectFunc(tile, cx)
{
struct conSrArg2 *csa2;
Rect tileArea, newarea;
TileTypeBitMask *connectMask, notConnectMask;
const TileTypeBitMask *connectMask;
TileTypeBitMask notConnectMask;
Rect *srArea;
SearchContext *scx = cx->tc_scx;
SearchContext scx2;
@ -1155,7 +1156,7 @@ DBTreeCopyConnect(scx, mask, xMask, connect, area, doLabels, destUse)
*/
{
struct conSrArg2 csa2;
TileTypeBitMask *newmask;
const TileTypeBitMask *newmask;
TileType newtype;
unsigned char searchtype;

View File

@ -647,7 +647,7 @@ typedef struct treeFilter
{
int (*tf_func)(); /* Client's filter function */
ClientData tf_arg; /* Client's argument to pass to filter */
TileTypeBitMask *tf_mask; /* Only process tiles with these types */
const TileTypeBitMask *tf_mask; /* Only process tiles with these types */
int tf_xmask; /* Expand mask */
PlaneMask tf_planes; /* Mask of planes which will be visited */
TileType tf_dinfo; /* Info for processing triangular areas */
@ -685,7 +685,7 @@ struct conSrArg
{
CellDef *csa_def; /* Definition being searched. */
int csa_pNum; /* Index of plane being searched */
TileTypeBitMask *csa_connect; /* Table indicating what connects
const TileTypeBitMask *csa_connect; /* Table indicating what connects
* to what.
*/
int (*csa_clientFunc)(); /* Client function to call. */
@ -700,19 +700,19 @@ struct conSrArg
typedef struct
{
Rect area; /* Area to process */
TileTypeBitMask *connectMask; /* Connection mask for search */
const TileTypeBitMask *connectMask; /* Connection mask for search */
TileType dinfo; /* Info about triangular search areas */
} conSrArea;
struct conSrArg2
{
CellUse *csa2_use; /* Destination use */
TileTypeBitMask *csa2_connect; /* Table indicating what connects
const TileTypeBitMask *csa2_connect;/* Table indicating what connects
* to what.
*/
SearchContext *csa2_topscx; /* Original top-level search context */
int csa2_xMask; /* Cell window mask for search */
Rect *csa2_bounds; /* Area that limits the search */
const Rect *csa2_bounds; /* Area that limits the search */
Stack *csa2_stack; /* Stack of full csa2_list entries */
conSrArea *csa2_list; /* List of areas to process */