From 9f37ba849c7401840526dcb109747eca5ee73b24 Mon Sep 17 00:00:00 2001 From: nhkeni Date: Sat, 16 Mar 2024 16:41:09 -0400 Subject: [PATCH] code_style.txt: Document staticfn and NEARDATA. --- DEVEL/code_style.txt | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/DEVEL/code_style.txt b/DEVEL/code_style.txt index 593f0a9fc..574af2cc8 100644 --- a/DEVEL/code_style.txt +++ b/DEVEL/code_style.txt @@ -170,6 +170,19 @@ Variable names to avoid processors with segmented architectures may treat those as keywords. It is safest to just avoid them. + NEARDATA Some data is marked with this define; the Amiga port uses + it to mark data items to be used with a short addressing mode. + You don't need to use this. + +static vs staticfn +------------------ + +The staticfn macro evaluates to either "static" or to nothing (see config.h). +If possible, functions in src/*.c that would otherwise be marked static should +be marked staticfn so platforms that do not name static functions in their +stack traces can be forced to do so; this means function names cannot be +reused. Never use staticfn with data. + Spaces in Expressions --------------------- @@ -240,7 +253,6 @@ the final newline for every file, prior to release if not always maintained day-to-day. The name at the end can still be worthwhile when editing or browsing multiple files. - Vim Configuration =================