From c434dbe0995b4976b1e64f2456f5e7f94a20d710 Mon Sep 17 00:00:00 2001 From: Thomas Walker Lynch Date: Mon, 13 Oct 2025 03:27:22 +0000 Subject: [PATCH] no more pencils --- .../Python/fill_template | 0 .../Python/make_N_constants.py | 0 .../Python/template_N.py | 0 .../Python/template_conversion.py | 0 "developer/cc\360\237\226\211/Core.lib.c" | 241 --------------- .../ParameterConnector.lib.c" | 77 ----- "developer/cc\360\237\226\211/TM.lib.c" | 143 --------- .../cc\360\237\226\211/TM\302\267Array.lib.c" | 244 --------------- .../TM\302\267SingletonCircle.lib.c" | 182 ----------- .../TM\302\267SingletonSegment.lib.c" | 178 ----------- .../TM\302\267ZeroLength.lib.c" | 180 ----------- "developer/cc\360\237\226\211/cpp_ext.c" | 19 -- "developer/cc\360\237\226\211/cpp_ext_0.c" | 290 ------------------ "developer/cc\360\237\226\211/cpp_ext_1.c" | 195 ------------ "developer/cc\360\237\226\211/scratch.c" | 7 - .../deprecated/.githolder | 0 .../deprecated/2025-03-29/N16.lib.c | 0 .../deprecated/2025-03-29/N32.lib.c | 0 .../deprecated/2025-03-29/N64.lib.c | 0 .../deprecated/2025-03-29/N8.lib.c | 0 .../deprecated/2025-03-29/TM_scratch.c | 0 .../deprecated/2025-03-29/environment.h | 0 .../deprecated/2025-03-29/test_setup.cli.c | 0 .../deprecated/2025-03-29/update.lib.c | 0 .../deprecated/About_Python_templates.org | 0 .../deprecated/Copy.lib.c | 0 .../deprecated/Copy.lib_2.c | 0 .../deprecated/Core_with_tableau.lib.c | 0 .../deprecated/Map.lib.c | 0 .../deprecated/Map2.lib.c | 0 .../deprecated/NN_Count_Digit.lib.c | 0 .../deprecated/N_32_test.cli.c | 0 .../deprecated/Natural_32.lib.c | 0 .../deprecated/Natural_32_0.lib.c | 0 .../deprecated/adding_new_N_types.org | 0 .../deprecated/copy.lib.c | 0 .../deprecated/scatch.c | 0 .../deprecated/test_Natural_32_0.cli.c | 0 .../document/.githolder | 0 .../document/Binding.org | 0 .../document/C_features_needed.org | 0 .../Copy.org" => developer/document/Copy.org | 0 .../document/FG_tables.org | 0 .../document/TapeMachine_howto.org | 0 .../document/alignment.org | 0 .../document/build.org | 0 .../document/coffee.txt | 0 .../document/cpp_gothyas.txt | 0 .../document/cpp_grammar.org | 0 .../document/cpp_macro_expansion.org | 0 .../document/parameterized_functions.org | 0 .../document/set_list.org | 0 .../document/source_file_sectioins.org | 0 .../document/template_in_C.org | 0 .../todo.org" => developer/document/todo.org | 0 .../clean" => developer/tool/clean | 0 .../env" => developer/tool/env | 0 .../make" => developer/tool/make | 0 .../makefile" => developer/tool/makefile | 0 .../release" => developer/tool/release | 0 .../tool/release_clean | 0 .../#Model.org#" => document/#Model.org# | 0 .../#temp.txt#" => document/#temp.txt# | 0 .../.githolder" => document/.githolder | 0 .../Abstracting_Type_in_C.org | 0 .../Inclusive_Exclusive_interval_bounds.org | 0 .../Model.org" => document/Model.org | 0 .../RT_C_namespace.org | 0 .../RT_C_tableau_methhod.org | 0 .../RT_cli_c_file.org | 0 .../RT_lib_c_file.org | 0 .../User_manual.org | 0 .../continuations.org | 0 .../emacs_keys.el" => document/emacs_keys.el | 0 .../temp.txt" => document/temp.txt | 0 .../unicode_character_use.org | 0 .../cc/cc/environment.h | 0 .../cc/cc/test_Copy_0.cli.c | 0 .../cc/cc/test_setup.cli.c | 0 .../deprecated/test_N32.cli.c | 0 .../document/build_procedure.org | 0 .../clean" => tester/tool/clean | 0 .../env" => tester/tool/env | 0 .../make" => tester/tool/make | 0 .../makefile" => tester/tool/makefile | 0 .../release_pull" => tester/tool/release_pull | 0 .../tool/release_remove | 0 .../add_git_holder" => tool/add_git_holder | 0 "tool\360\237\226\211/env" => tool/env | 0 .../env" => tool_shared/bespoke/env | 0 .../version" => tool_shared/bespoke/version | 0 .../document/install.txt | 0 92 files changed, 1756 deletions(-) rename "developer/Python\360\237\226\211/fill_template" => developer/Python/fill_template (100%) rename "developer/Python\360\237\226\211/make_N_constants.py" => developer/Python/make_N_constants.py (100%) rename "developer/Python\360\237\226\211/template_N.py" => developer/Python/template_N.py (100%) rename "developer/Python\360\237\226\211/template_conversion.py" => developer/Python/template_conversion.py (100%) delete mode 100644 "developer/cc\360\237\226\211/Core.lib.c" delete mode 100644 "developer/cc\360\237\226\211/ParameterConnector.lib.c" delete mode 100644 "developer/cc\360\237\226\211/TM.lib.c" delete mode 100644 "developer/cc\360\237\226\211/TM\302\267Array.lib.c" delete mode 100644 "developer/cc\360\237\226\211/TM\302\267SingletonCircle.lib.c" delete mode 100644 "developer/cc\360\237\226\211/TM\302\267SingletonSegment.lib.c" delete mode 100644 "developer/cc\360\237\226\211/TM\302\267ZeroLength.lib.c" delete mode 100644 "developer/cc\360\237\226\211/cpp_ext.c" delete mode 100644 "developer/cc\360\237\226\211/cpp_ext_0.c" delete mode 100644 "developer/cc\360\237\226\211/cpp_ext_1.c" delete mode 100644 "developer/cc\360\237\226\211/scratch.c" rename "developer/deprecated\360\237\226\211/.githolder" => developer/deprecated/.githolder (100%) rename "developer/deprecated\360\237\226\211/2025-03-29/N16.lib.c" => developer/deprecated/2025-03-29/N16.lib.c (100%) rename "developer/deprecated\360\237\226\211/2025-03-29/N32.lib.c" => developer/deprecated/2025-03-29/N32.lib.c (100%) rename "developer/deprecated\360\237\226\211/2025-03-29/N64.lib.c" => developer/deprecated/2025-03-29/N64.lib.c (100%) rename "developer/deprecated\360\237\226\211/2025-03-29/N8.lib.c" => developer/deprecated/2025-03-29/N8.lib.c (100%) rename "developer/deprecated\360\237\226\211/2025-03-29/TM_scratch.c" => developer/deprecated/2025-03-29/TM_scratch.c (100%) rename "developer/deprecated\360\237\226\211/2025-03-29/environment.h" => developer/deprecated/2025-03-29/environment.h (100%) rename "developer/deprecated\360\237\226\211/2025-03-29/test_setup.cli.c" => developer/deprecated/2025-03-29/test_setup.cli.c (100%) rename "developer/deprecated\360\237\226\211/2025-03-29/update.lib.c" => developer/deprecated/2025-03-29/update.lib.c (100%) rename "developer/deprecated\360\237\226\211/About_Python_templates.org" => developer/deprecated/About_Python_templates.org (100%) rename "developer/deprecated\360\237\226\211/Copy.lib.c" => developer/deprecated/Copy.lib.c (100%) rename "developer/deprecated\360\237\226\211/Copy.lib_2.c" => developer/deprecated/Copy.lib_2.c (100%) rename "developer/deprecated\360\237\226\211/Core_with_tableau.lib.c" => developer/deprecated/Core_with_tableau.lib.c (100%) rename "developer/deprecated\360\237\226\211/Map.lib.c" => developer/deprecated/Map.lib.c (100%) rename "developer/deprecated\360\237\226\211/Map2.lib.c" => developer/deprecated/Map2.lib.c (100%) rename "developer/deprecated\360\237\226\211/NN_Count_Digit.lib.c" => developer/deprecated/NN_Count_Digit.lib.c (100%) rename "developer/deprecated\360\237\226\211/N_32_test.cli.c" => developer/deprecated/N_32_test.cli.c (100%) rename "developer/deprecated\360\237\226\211/Natural_32.lib.c" => developer/deprecated/Natural_32.lib.c (100%) rename "developer/deprecated\360\237\226\211/Natural_32_0.lib.c" => developer/deprecated/Natural_32_0.lib.c (100%) rename "developer/deprecated\360\237\226\211/adding_new_N_types.org" => developer/deprecated/adding_new_N_types.org (100%) rename "developer/deprecated\360\237\226\211/copy.lib.c" => developer/deprecated/copy.lib.c (100%) rename "developer/deprecated\360\237\226\211/scatch.c" => developer/deprecated/scatch.c (100%) rename "developer/deprecated\360\237\226\211/test_Natural_32_0.cli.c" => developer/deprecated/test_Natural_32_0.cli.c (100%) rename "developer/document\360\237\226\211/.githolder" => developer/document/.githolder (100%) rename "developer/document\360\237\226\211/Binding.org" => developer/document/Binding.org (100%) rename "developer/document\360\237\226\211/C_features_needed.org" => developer/document/C_features_needed.org (100%) rename "developer/document\360\237\226\211/Copy.org" => developer/document/Copy.org (100%) rename "developer/document\360\237\226\211/FG_tables.org" => developer/document/FG_tables.org (100%) rename "developer/document\360\237\226\211/TapeMachine_howto.org" => developer/document/TapeMachine_howto.org (100%) rename "developer/document\360\237\226\211/alignment.org" => developer/document/alignment.org (100%) rename "developer/document\360\237\226\211/build.org" => developer/document/build.org (100%) rename "developer/document\360\237\226\211/coffee.txt" => developer/document/coffee.txt (100%) rename "developer/document\360\237\226\211/cpp_gothyas.txt" => developer/document/cpp_gothyas.txt (100%) rename "developer/document\360\237\226\211/cpp_grammar.org" => developer/document/cpp_grammar.org (100%) rename "developer/document\360\237\226\211/cpp_macro_expansion.org" => developer/document/cpp_macro_expansion.org (100%) rename "developer/document\360\237\226\211/parameterized_functions.org" => developer/document/parameterized_functions.org (100%) rename "developer/document\360\237\226\211/set_list.org" => developer/document/set_list.org (100%) rename "developer/document\360\237\226\211/source_file_sectioins.org" => developer/document/source_file_sectioins.org (100%) rename "developer/document\360\237\226\211/template_in_C.org" => developer/document/template_in_C.org (100%) rename "developer/document\360\237\226\211/todo.org" => developer/document/todo.org (100%) rename "developer/tool\360\237\226\211/clean" => developer/tool/clean (100%) rename "developer/tool\360\237\226\211/env" => developer/tool/env (100%) rename "developer/tool\360\237\226\211/make" => developer/tool/make (100%) rename "developer/tool\360\237\226\211/makefile" => developer/tool/makefile (100%) rename "developer/tool\360\237\226\211/release" => developer/tool/release (100%) rename "developer/tool\360\237\226\211/release_clean" => developer/tool/release_clean (100%) rename "document\360\237\226\211/#Model.org#" => document/#Model.org# (100%) rename "document\360\237\226\211/#temp.txt#" => document/#temp.txt# (100%) rename "document\360\237\226\211/.githolder" => document/.githolder (100%) rename "document\360\237\226\211/Abstracting_Type_in_C.org" => document/Abstracting_Type_in_C.org (100%) rename "document\360\237\226\211/Inclusive_Exclusive_interval_bounds.org" => document/Inclusive_Exclusive_interval_bounds.org (100%) rename "document\360\237\226\211/Model.org" => document/Model.org (100%) rename "document\360\237\226\211/RT_C_namespace.org" => document/RT_C_namespace.org (100%) rename "document\360\237\226\211/RT_C_tableau_methhod.org" => document/RT_C_tableau_methhod.org (100%) rename "document\360\237\226\211/RT_cli_c_file.org" => document/RT_cli_c_file.org (100%) rename "document\360\237\226\211/RT_lib_c_file.org" => document/RT_lib_c_file.org (100%) rename "document\360\237\226\211/User_manual.org" => document/User_manual.org (100%) rename "document\360\237\226\211/continuations.org" => document/continuations.org (100%) rename "document\360\237\226\211/emacs_keys.el" => document/emacs_keys.el (100%) rename "document\360\237\226\211/temp.txt" => document/temp.txt (100%) rename "document\360\237\226\211/unicode_character_use.org" => document/unicode_character_use.org (100%) rename "tester/cc\360\237\226\211/environment.h" => tester/cc/cc/environment.h (100%) rename "tester/cc\360\237\226\211/test_Copy_0.cli.c" => tester/cc/cc/test_Copy_0.cli.c (100%) rename "tester/cc\360\237\226\211/test_setup.cli.c" => tester/cc/cc/test_setup.cli.c (100%) rename "tester/deprecated\360\237\226\211/test_N32.cli.c" => tester/deprecated/test_N32.cli.c (100%) rename "tester/document\360\237\226\211/build_procedure.org" => tester/document/build_procedure.org (100%) rename "tester/tool\360\237\226\211/clean" => tester/tool/clean (100%) rename "tester/tool\360\237\226\211/env" => tester/tool/env (100%) rename "tester/tool\360\237\226\211/make" => tester/tool/make (100%) rename "tester/tool\360\237\226\211/makefile" => tester/tool/makefile (100%) rename "tester/tool\360\237\226\211/release_pull" => tester/tool/release_pull (100%) rename "tester/tool\360\237\226\211/release_remove" => tester/tool/release_remove (100%) rename "tool\360\237\226\211/add_git_holder" => tool/add_git_holder (100%) rename "tool\360\237\226\211/env" => tool/env (100%) rename "tool_shared/bespoke\360\237\226\211/env" => tool_shared/bespoke/env (100%) rename "tool_shared/bespoke\360\237\226\211/version" => tool_shared/bespoke/version (100%) rename "tool_shared/document\360\237\226\211/install.txt" => tool_shared/document/install.txt (100%) diff --git "a/developer/Python\360\237\226\211/fill_template" b/developer/Python/fill_template similarity index 100% rename from "developer/Python\360\237\226\211/fill_template" rename to developer/Python/fill_template diff --git "a/developer/Python\360\237\226\211/make_N_constants.py" b/developer/Python/make_N_constants.py similarity index 100% rename from "developer/Python\360\237\226\211/make_N_constants.py" rename to developer/Python/make_N_constants.py diff --git "a/developer/Python\360\237\226\211/template_N.py" b/developer/Python/template_N.py similarity index 100% rename from "developer/Python\360\237\226\211/template_N.py" rename to developer/Python/template_N.py diff --git "a/developer/Python\360\237\226\211/template_conversion.py" b/developer/Python/template_conversion.py similarity index 100% rename from "developer/Python\360\237\226\211/template_conversion.py" rename to developer/Python/template_conversion.py diff --git "a/developer/cc\360\237\226\211/Core.lib.c" "b/developer/cc\360\237\226\211/Core.lib.c" deleted file mode 100644 index ec6a658..0000000 --- "a/developer/cc\360\237\226\211/Core.lib.c" +++ /dev/null @@ -1,241 +0,0 @@ -/* - Core - core memory operations. - - Abbreviations used in comments: - - 'ATP' `At This Point' in the code. Acronym used in comments usually before pointing - out certain values variables must have. - - 'AToW' - At Time of Writing ,also used in comments. - - Abbreviations used in identifiers: - - `AU` `Addressable Unit for the machine`. The C standard leaves this open to definition by the architecture and calls it `char`. On most all machines today it is uint8_t; - - We use structs to group functions into a namespace. When all the functions that have a specific type of given argument are group together ,we call the table a 'Functions Given Type X table' ,or 'PFT table' for short. A specific instance of an PFT table is an `pft` table. - -*/ - -/*-------------------------------------------------------------------------------- - Interface ---------------------------------------------------------------------------------*/ -#ifndef Core·FACE -#define Core·FACE - - #define Core·DEBUG - #ifdef PFT·DEBUG - #include - #endif - - #include - #include - #include - #include - #include "cpp_ext.c" - - //---------------------------------------- - // memory interface - - // extent is the maximum index in an address space ,tape or area ,the doted - // unit is the cell type. - typedef size_t extent_t·AU; - #define extent_of·AU(x) (sizeof(x) - 1) - // Funny ,we seldom check for this ,perhaps that matters on some tiny machine. - #define extent_of·AU_address_space ~(uintptr)0; - - // addressable unit for the machine - // C language standard left this undefined. AToW industry uses uint8_t. - typedef uint8_t AU ; - typedef uint16_t AU2; - typedef uint32_t AU4; - typedef uint64_t AU8; - - const AU AU_MAX = (~(AU)0); - const AU2 AU2_MAX = (~(AU2)0); - const AU4 AU4_MAX = (~(AU4)0); - const AU8 AU8_MAX = (~(AU8)0); - - // ask the compiler what this is - // when using enums we get this whether we want it or not - typedef unsigned int WU; - const WU WU_MAX = (~(WU)0); - - //---------------------------------------- - // flag facility ,argument guard facility - - typedef enum{ - Core·Status·mu = 0 - ,Core·Status·on_track - ,Core·Status·derailed - }Core·Status; - - typedef void (*Core·Flag·Fn)(WU *flag ,WU err); - - void Core·Flag·count(WU *flag ,WU err){ - if(err == WU_MAX){ *flag = WU_MAX; return;} - - //*flag + err > WU_MAX - if(*flag > WU_MAX - err){ *flag = WU_MAX; return;} - - (*flag) += err; - } - - void Core·Flag·collect(WU *flag ,WU err){ - (*flag) |= err; - } - - typedef struct { - const char *name; - Core·Flag·Fn flag_function; - WU flag; - } Core·Guard; - - typedef struct { - void (*init)(Core·Guard *chk ,const char *name ,Core·Flag·Fn af); - void (*reset)(Core·Guard *chk); - void (*check)( - Core·Guard *chk - ,WU err - ,bool condition - ,char *message - ); - } Core·Guard·PFT; - - // Default guard function table - // initialized in the implementation section below - Local Core·Guard·PFT Core·Guard·pft; - - #define Core·Guard·init_count(chk) \ - Core·Guard chk; \ - Core·Guard·pft.init(&chk ,__func__ ,Core·Flag·count); - - #define Core·Guard·init_collect(chk) \ - Core·Guard chk; \ - Core·Guard·pft.init(&chk ,__func__ ,Core·Flag·collect); - - #define Core·Guard·if_return(chk) if( chk.flag ) return Core·Status·derailed; - #define Core·Guard·return(chk)\ - if( chk.flag ) return Core·Status·derailed;\ - else return Core·Status·on_track; - #define Core·Guard·assert(chk) assert(!chk.flag); - - //---------------------------------------- - // functions interface - - // no state ,this is merely a namespace - - typedef struct{ - Core·Status (*on_track)(); - Core·Status (*derailed)(); - Core·Status (*is_aligned)(AU *p ,extent_t·AU alignment ,bool *flag); - Core·Status (*round_down)(AU *p ,extent_t·AU alignment ,AU **result); - Core·Status (*round_up)(AU *p ,extent_t·AU alignment ,AU **result); - } Core·F; - Local Core·F Core·f; - -#endif // #if CORE·FACE - - -/*-------------------------------------------------------------------------------- - Local - at bottom of translation unit, to keep some functions private - --------------------------------------------------------------------------------*/ -#ifdef LOCAL - -// once per translation unit -#ifndef Core·LOCAL -#define Core·LOCAL - - //---------------------------------------- - // argument guard implementation - - Local void Core·Guard·init(Core·Guard *chk ,const char *name ,Core·Flag·Fn af){ - if(!chk) return; - chk->name = name; - chk->flag_function = af; - chk->flag = 0; - } - - Local void Core·Guard·reset(Core·Guard *chk){ - if( !chk ) return; - chk->flag = 0; - } - - Local void Core·Guard·check( - Core·Guard *chk - ,WU err - ,bool condition - ,char *message - ){ - if( !chk || !chk->flag_function ) return; - if( condition ) return; - fprintf(stderr ,"%s\n" ,message); - chk->flag_function(&chk->flag ,err); - } - - Local Core·Guard·PFT Core·Guard·pft = { - .init = Core·Guard·init - ,.reset = Core·Guard·reset - ,.check = Core·Guard·check - }; - - //---------------------------------------- - // Functions implementation - - Core·Status Core·on_track(){ return Core·Status·on_track; } - Core·Status Core·derailed(){ return Core·Status·derailed; } - - Local Core·Status Core·is_aligned(AU *p ,extent_t·AU alignment ,bool *flag){ - #ifdef Core·DEBUG - Core·Guard·init_count(chk); - Core·Guard·pft.check(&chk ,1 ,p ,"given NULL p"); - Core·Guard·pft.check(&chk ,1 ,flag ,"flag is NULL, so nowhere to write result"); - Core·Guard·if_return(chk); - #endif - *flag = ( (uintptr_t)p & alignment ) == 0; - return Core·Status·on_track; - } - - Local Core·Status Core·round_down(AU *p ,extent_t·AU alignment ,AU **result){ - #ifdef Core·DEBUG - Core·Guard·init_count(chk); - Core·Guard·pft.check(&chk ,1 ,p ,"given NULL p to round"); - Core·Guard·pft.check(&chk ,1 ,result ,"result is NULL, so nowhere to write result"); - Core·Guard·if_return(chk); - #endif - *result = (AU *)( (uintptr_t)p & ~(uintptr_t)alignment ); - return Core·Status·on_track; - } - - Local Core·Status Core·round_up(AU *p ,extent_t·AU alignment ,AU **result){ - #ifdef Core·DEBUG - Core·Guard·init_count(chk); - Core·Guard·pft.check(&chk ,1 ,p ,"given NULL p to round"); - Core·Guard·pft.check(&chk ,1 ,result ,"result is NULL, so nowhere to write result"); - Core·Guard·if_return(chk); - #endif - *result = (AU *)( ( (uintptr_t)p + alignment ) & ~(uintptr_t)alignment ); - return Core·Status·on_track; - } - - Local Core·F Core·f = { - .on_track = Core·on_track - ,.derailed = Core·derailed - ,.is_aligned = Core·is_aligned - ,.round_down = Core·round_down // Add `Core` - ,.round_up = Core·round_up // Add `Core` - }; - -#endif // Core·LOCAL -#endif // LOCAL - -/*-------------------------------------------------------------------------------- - Library - compiled into a lib.a file by the current make - Core currently has no library components ---------------------------------------------------------------------------------*/ -#ifdef LIBRARY -#endif - -/*-------------------------------------------------------------------------------- - undef the template parameters - Core currently has not template parameters ---------------------------------------------------------------------------------*/ diff --git "a/developer/cc\360\237\226\211/ParameterConnector.lib.c" "b/developer/cc\360\237\226\211/ParameterConnector.lib.c" deleted file mode 100644 index f0db395..0000000 --- "a/developer/cc\360\237\226\211/ParameterConnector.lib.c" +++ /dev/null @@ -1,77 +0,0 @@ -/* -Namespace: ParameterConnector - -Defines a macro for declaring parameter connectors, and for calling a parameterized function. - -Declares a parameter connector, does not initialize it. - -*/ - -/*-------------------------------------------------------------------------------- - Interface --------------------------------------------------------------------------------*/ - - -// once per translation unit -#ifndef ParameterConnector·FACE -#define ParameterConnector·FACE - - #define ParameterConnector·DEBUG - #ifdef ParameterConnector·DEBUG - #include - #pragma message( "ParameterConnector·FACE" ) - #endif - - #include "cpp_ext.c" - #include "Core.lib.c" - - /* - usage e.g.: ParameterConnector·call(tm, function_name, arg1, arg2, ...) - Expands to: (tm.pft->function_name)(tm ,arg1 ,arg2, ...) - - note the use of the comma operator to return the result from the b.pft->fn call - - pc - parameter connector - PC - generic parameter connector type, though as the parameter connector is the entry point for dispatch, we give it the name of Model/Machine type. - */ - #ifdef ParameterConnector·DEBUG - #include - #define ParameterConnector·call(pc ,fn ,...) ( \ - assert((pc).pft != NULL) \ - ,assert((pc).state_parameter != NULL) \ - ,(pc).pft->fn(pc __VA_OPT__(,) __VA_ARGS__) \ - ) - #else - #define ParameterConnector·call(pc ,fn ,...) \ - (pc).pft->fn(pc __VA_OPT__(,) __VA_ARGS__) - #endif - - #define ParameterConnector·DECLARE(type) \ - typedef struct ·(type ,PFT) ·(type ,PFT); \ - typedef struct ·(type ,StateParameter) ·(type ,StateParameter); \ - typedef struct type { \ - ·(type ,StateParameter) *state_parameter; \ - ·(type ,PFT) *pft; \ - } type; - -#endif - - - -/*-------------------------------------------------------------------------------- - Local - at bottom of translation unit, to keep some functions private - ParameterConnector currently has no local component ---------------------------------------------------------------------------------*/ -#ifdef LOCAL - -#endif - -/*-------------------------------------------------------------------------------- - Library - compiled into a lib.a file by the current make - ParameterConnector has no library component ---------------------------------------------------------------------------------*/ -#ifdef LIBRARY - -#endif - - diff --git "a/developer/cc\360\237\226\211/TM.lib.c" "b/developer/cc\360\237\226\211/TM.lib.c" deleted file mode 100644 index ac59356..0000000 --- "a/developer/cc\360\237\226\211/TM.lib.c" +++ /dev/null @@ -1,143 +0,0 @@ -/* - Namespace: TM - Template parameters: - - `_TM·CVT_` Cell Value Type`. - - TM - Tape Machine Model - - Caller must declare TM set members: - #define SET_Binding__TM· // replacing with the actual value of CVT - -*/ - -/*-------------------------------------------------------------------------------- - Interface ---------------------------------------------------------------------------------*/ - -// once per translation unit -#ifndef TM·FACE -#define TM·FACE - - #include - #include - #include "cpp_ext.c" - - #include "Core.lib.c" - #include "Binding.lib.c" - - #define TM·DEBUG - #ifdef TM·DEBUG - #include - #endif - - typedef enum{ - TM·Topo·mu = 0 - ,TM·Topo·zero_length = 1 - ,TM·Topo·singleton = 1 << 1 - ,TM·Topo·segment = 1 << 2 - ,TM·Topo·circle = 1 << 3 - ,TM·Topo·tail_cyclic = 1 << 4 - ,TM·Topo·infinite = 1 << 5 - }TM·Topo; - const TM·Topo TM·Topo·bounded = - TM·Topo·singleton - | TM·Topo·segment - ; - - typedef enum{ - TM·Status·mu = 0 - ,TM·Status·dismounted = 1 - ,TM·Status·out_of_area = 1 << 1 - ,TM·Status·leftmost = 1 << 2 - ,TM·Status·interim = 1 << 3 - ,TM·Status·rightmost = 1 << 4 - } TM·Status; - - const TM·Status TM·Status·on_tape = - TM·Status·leftmost - | TM·Status·interim - | TM·Status·rightmost - ; - -#endif //#ifndef TM·FACE - -// once per _TM·CVT_ value -// Caller must #define SET_Binding__TM·, after inclusion, to prevent re-inclusion -#ifdef _TM·CVT_ -#if BOOLEAN( NOT_IN(TM ,_TM·CVT_) ) -#ifdef TM·DEBUG - #pragma message( "Creating TM type with a CVT of:" STR_VAL(_TM·CVT_) ) -#endif - - typedef size_t ·(extent_t,_TM·CVT_); - - ParameterConnector·DECLARE( ·(TM,_TM·CVT_) ) - - typedef struct ·(TM,_TM·CVT_,PFT){ - - TM·Topo (*topo) ( ·(TM,_TM·CVT_) tm ); - bool (*bounded) ( ·(TM,_TM·CVT_) tm ); - ·(extent_t,_TM·CVT_) (*extent) ( ·(TM,_TM·CVT_) tm ); - - TM·Status (*status) ( ·(TM,_TM·CVT_) tm ); - bool (*dismounted) ( ·(TM,_TM·CVT_) tm ); - bool (*on_tape) ( ·(TM,_TM·CVT_) tm ); - bool (*on_leftmost)( ·(TM,_TM·CVT_) tm ); - bool (*on_rightmost)( ·(TM,_TM·CVT_) tm ); - - // tape machine functions - void (*mount) ( ·(TM,_TM·CVT_) tm ); - void (*dismount) ( ·(TM,_TM·CVT_) tm ); - - void (*step) ( ·(TM,_TM·CVT_) tm ); - void (*step_left) ( ·(TM,_TM·CVT_) tm ); - void (*rewind) ( ·(TM,_TM·CVT_) tm ); - - _TM·CVT_ (*read) ( ·(TM,_TM·CVT_) tm ); - void (*write) ( ·(TM,_TM·CVT_) tm ,_TM·CVT_ *remote_pt ); - - } ·(TM,_TM·CVT_,PFT); - - -#endif -#endif - -/*-------------------------------------------------------------------------------- - Local ---------------------------------------------------------------------------------*/ -#ifdef LOCAL - - // once per translation unit - #ifndef TM·LOCAL - #define TM·LOCAL - - #include "Core.lib.c" - #include "Binding.lib.c" - - const char *TM·Msg·tm = "given NULL tm"; - const char *TM·Msg·flag = "given NULL flag pointer"; - const char *TM·Msg·result = "given NULL result pointer"; - const char *TM·Msg·status = "bad head status"; - - #endif - - // once per _TM·CVT_ value - // Caller must #define SET_TM·LOCAL__TM·, after inclusion, to prevent re-inclusion - #ifdef _TM·CVT_ - #if BOOLEAN(NOT_IN(TM·LOCAL ,·(TM,_TM·CVT_))) - #ifdef TM·DEBUG - #pragma message( "Including TM LOCAL code for:" STR_VAL(_TM·CVT_) ) - #endif - - #endif // #if BOOLEAN(NOT_IN(TM·LOCAL ,TM)) - #endif // #ifdef _TM·CVT_ - -#endif // LOCAL - -/*-------------------------------------------------------------------------------- - Library - compiled into a lib.a file by the current make - Core currently has no library components ---------------------------------------------------------------------------------*/ -#ifdef LIBRARY -#endif diff --git "a/developer/cc\360\237\226\211/TM\302\267Array.lib.c" "b/developer/cc\360\237\226\211/TM\302\267Array.lib.c" deleted file mode 100644 index f9ce008..0000000 --- "a/developer/cc\360\237\226\211/TM\302\267Array.lib.c" +++ /dev/null @@ -1,244 +0,0 @@ -/* - Namespace: TM·Array - - Template parameters: - - `_TM·CVT_` Cell Value Type`. - -*/ -#include "TM.lib.c" - -/*-------------------------------------------------------------------------------- - Interface ---------------------------------------------------------------------------------*/ - -// once per translation unit -#ifndef TM·Array·FACE -#define TM·Array·FACE - - #define TM·Array·DEBUG - #ifdef TM·Array·DEBUG - #include - #endif - -#endif - -// only include this file once per _TM·CVT_ value -#ifdef _TM·CVT_ - - #if BOOLEAN( NOT_IN(TM ,_TM·CVT_) ) - #include "TM.Lib.c" - #define SET__ - #endif - - #pragma push(T) - #pragma push(TA) - #pragma push(TE) - - #define T ·(TM,_TM·CVT_) - #define TA ·(TM,Array,_TM·CVT_) - #define TE ·(extent_t,_TM·CVT_) - - #ifdef TM·Array·DEBUG - #pragma message( "Declaring:" STR_VAL(TA) ) - #endif - - typedef struct{ - _TM·CVT_ *hd; - _TM·CVT_ *position; - TE extent; - } ·(TA,StateParameter); - - // call signatures for the initialization functions - // - T ·(TA,init_pe)( - ·(TA,StateParameter) *t ,_TM·CVT_ position[] ,TE extent - ); - - T ·(TA,init_pp)( - ·(TA,StateParameter) *t ,_TM·CVT_ *position_left ,_TM·CVT_ *position_right - ); - - #pragma pop(T) - #pragma pop(TA) - #pragma pop(TE) - -#endif -#endif - -/*-------------------------------------------------------------------------------- - Local ---------------------------------------------------------------------------------*/ -#ifdef LOCAL - - // once per translation unit - #ifndef TM·Array·LOCAL - #define TM·Array·LOCAL - - #endif - - // once per _TM·CVT_ value - #ifdef _TM·CVT_ - #if BOOLEAN( NOT_IN(TM·Array·LOCAL ,_TM·CVT_) ) - - #include "TM.Lib.c" - - #pragma push(T) - #pragma push(TA) - #pragma push(TE) - - #define T ·(TM,_TM·CVT_) - #define TA ·(TM,Array,_TM·CVT_) - #define TE ·(extent_t,_TM·CVT_) - - #ifdef TM·Array·DEBUG - #pragma message( "LOCAL:" STR_VAL(TA) ) - #endif - - Local TM·Topo ·(TA,topo)(T tm){ - ·(TA,StateParameter) *t = (·(TA,StateParameter) *) tm.state_parameter; - if( t->extent == 0 ) return TM·Topo·singleton; - return TM·Topo·segment; - } - Local bool ·(TA,bounded)(T tm){ - ·(TA,StateParameter) *t = (·(TA,StateParameter) *) tm.state_parameter; - return ·(TA,topo)(tm) & TM·Topo·bounded; - } - Local TE ·(TA,extent)(T tm){ - ·(TA,StateParameter) *t = (·(TA,StateParameter) *) tm.state_parameter; - return t->extent; - } - - Local TM·Status ·(TA,status)(T tm){ - ·(TA,StateParameter) *t = (·(TA,StateParameter) *) tm.state_parameter; - if( !t->hd ) return TM·Status·dismounted; - if( t->hd == t->position ) return TM·Status·leftmost; - - _TM·CVT_ *rightmost_pt = t->position + t->extent; - if( t->hd == rightmost_pt ) return TM·Status·rightmost; - if( t->hd < t->position || t->hd > rightmost_pt ) - return TM·Status·out_of_area; - - return TM·Status·interim; - } - - Local bool ·(TA,dismounted)(T tm){ - return ·(TA,status)( tm ) & TM·Status·dismounted; - } - - Local bool ·(TA,on_tape)(T tm){ - return ·(TA,status)( tm ) & TM·Status·on_tape; - } - - Local bool ·(TA,on_leftmost)(T tm){ - return ·(TA,status)( tm ) & TM·Status·leftmost; - } - - Local bool ·(TA,on_rightmost)(T tm){ - return ·(TA,status)( tm ) & TM·Status·rightmost; - } - - // does nothing if tape is already mounted - Local void ·(TA,mount)(T tm){ - ·(TA,StateParameter) *t = (·(TA,StateParameter) *) tm.state_parameter; - if( !t->hd ) t->hd = t->position; - } - - Local void ·(TA,dismount)(T tm){ - ·(TA,StateParameter) *t = (·(TA,StateParameter) *) tm.state_parameter; - t->hd = NULL; - } - - Local void ·(TA,step)(T tm){ - ·(TA,StateParameter) *t = (·(TA,StateParameter) *) tm.state_parameter; - t->hd++; - } - - Local void ·(TA,step_left)(T tm){ - ·(TA,StateParameter) *t = (·(TA,StateParameter) *) tm.state_parameter; - t->hd--; - } - - // rewind does nothing if the tape is dismounted - Local void ·(TA,rewind)(T tm){ - ·(TA,StateParameter) *t = (·(TA,StateParameter) *) tm.state_parameter; - if( ·(TA,dismounted)( tm ) ) return; - t->hd = t->position; - } - - Local _TM·CVT_ ·(TA,read)(T tm){ - ·(TA,StateParameter) *t = (·(TA,StateParameter) *) tm.state_parameter; - return *t->hd; - } - - Local void ·(TA,write)(T tm ,_TM·CVT_ *remote_pt){ - ·(TA,StateParameter) *t = (·(TA,StateParameter) *) tm.state_parameter; - *t->hd = *remote_pt; - } - - Local ·(TM,_TM·CVT_,PFT) ·(TA,pft) = { - - .topo = ·(TA,topo) - ,.bounded = ·(TA,bounded) - ,.extent = ·(TA,extent) - - ,.status = ·(TA,status) - ,.dismounted = ·(TA,dismounted) - ,.on_tape = ·(TA,on_tape) - ,.on_leftmost = ·(TA,on_leftmost) - ,.on_rightmost = ·(TA,on_rightmost) - - ,.mount = ·(TA,mount) - ,.dismount = ·(TA,dismount) - - ,.step = ·(TA,step) - ,.step_left = ·(TA,step_left) - ,.rewind = ·(TA,rewind) - - ,.read = ·(TA,read) - ,.write = ·(TA,write) - - }; - - /* - tm is up casted from being array specific, to being generic. Later it is downcasted within the array code before being used. This can be seen at the top of each of the array specific function. This is the only loss of static type safety, and it is embedded in the library code. - */ - ·(TM,_TM·CVT_) ·(TA,init_pe)( - ·(TA,StateParameter) *t - ,_TM·CVT_ *position - ,TE extent - ){ - t->hd = position; - t->position = position; - t->extent = extent; - - T tm = { - .state_parameter = (·(TM,_TM·CVT_,StateParameter) *)t - ,.pft = &·(TA,pft) - }; - - return tm; - } - - ·(TM,_TM·CVT_) ·(TA,init_pp)( - ·(TA,StateParameter) *t - ,_TM·CVT_ *position_left - ,_TM·CVT_ *position_right - ){ - return ·(TA,init_pe)( - t ,position_left ,position_right - position_left - ); - } - - - #endif // #if BOOLEAN(NOT_IN(TM·LOCAL ,TM)) - #endif // #ifdef _TM·CVT_ - -#endif // LOCAL - -/*-------------------------------------------------------------------------------- - Library - compiled into a lib.a file by the current make - Core currently has no library components ---------------------------------------------------------------------------------*/ -#ifdef LIBRARY -#endif diff --git "a/developer/cc\360\237\226\211/TM\302\267SingletonCircle.lib.c" "b/developer/cc\360\237\226\211/TM\302\267SingletonCircle.lib.c" deleted file mode 100644 index 6e375ea..0000000 --- "a/developer/cc\360\237\226\211/TM\302\267SingletonCircle.lib.c" +++ /dev/null @@ -1,182 +0,0 @@ -/* - Namespace: TM - Template parameters: - - `_TM·CVT_` Cell Value Type`. - - TM - Tape Machine Model - - Caller must declare TM set members: - #define SET_Binding__TM· // replacing with the actual value of CVT - -*/ - -/*-------------------------------------------------------------------------------- - Interface ---------------------------------------------------------------------------------*/ - -// once per translation unit -#ifndef TM·FACE -#define TM·FACE - - #define TM·SingletonCircle·DEBUG - #ifdef TM·SingletonCircle·DEBUG - #include - #endif - -#endif //#ifndef TM·FACE - -// once per _TM·CVT_ value -// Caller must #define SET_Binding__TM·SingletonCircle·, after inclusion, to prevent re-inclusion -#ifdef _TM·CVT_ -#if BOOLEAN( NOT_IN(Binding ,·(TM·SingletonCircle,_TM·CVT_)) ) -#ifdef TM·DEBUG - #pragma message( "Creating TM·SingletonCircle type with a CVT of:" STR_VAL(_TM·CVT_) ) -#endif - - typedef struct{ - bool hd; - _TM·CVT_ value; - } ·(TM,_TM·CVT_,SingletonCircle,StateParameter); - - ·(TM,_TM·CVT_) ·(TM,_TM·CVT_,SingletonCircle,init)( - ·(TM,_TM·CVT_,SingletonCircle,StateParameter) *t - ,_TM·CVT_ initial_value - ); - -#endif // #if BOOLEAN( NOT_IN(Binding ,TM) ) -#endif // #ifdef _TM·CVT_ - -/*-------------------------------------------------------------------------------- - Local ---------------------------------------------------------------------------------*/ -#ifdef LOCAL - - // once per translation unit - #ifndef TM·SingletonCircle·LOCAL - #define TM·SingletonCircle·LOCAL - - #endif - - // once per _TM·CVT_ value - // Caller must #define SET_TM·LOCAL__TM·, after inclusion, to prevent re-inclusion - #ifdef _TM·CVT_ - #if BOOLEAN(NOT_IN(TM·SingletonCircle·LOCAL ,·(TM,_TM·CVT_))) - #ifdef TM·SingletonCircle·DEBUG - #pragma message( "Including TM·SingletonCircle LOCAL code for:" STR_VAL(_TM·CVT_) ) - #endif - - Local TM·Topo ·(TM,_TM·CVT_,SingletonCircle,topo)( ·(TM,_TM·CVT_) tm ){ - return TM·Topo·circle; - } - Local bool ·(TM,_TM·CVT_,SingletonCircle,bounded)( ·(TM,_TM·CVT_) tm ){ - return false; - } - Local ·(extent_t,_TM·CVT_) ·(TM,_TM·CVT_,SingletonCircle,extent)( ·(TM,_TM·CVT_) tm ){ - return 0; - } - Local TM·Status ·(TM,_TM·CVT_,SingletonCircle,status)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,SingletonCircle,StateParameter) *t = (·(TM,_TM·CVT_,SingletonCircle,StateParameter) *) tm.state_parameter; - if( !t->hd ) return TM·Status·dismounted; - return TM·Status·interim; - } - Local bool ·(TM,_TM·CVT_,SingletonCircle,dismounted)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,SingletonCircle,StateParameter) *t = (·(TM,_TM·CVT_,SingletonCircle,StateParameter) *) tm.state_parameter; - return !t->hd; - } - - // these could be pulled from the tm.pft table, and defined once - Local bool ·(TM,_TM·CVT_,SingletonCircle,on_tape)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,SingletonCircle,StateParameter) *t = (·(TM,_TM·CVT_,SingletonCircle,StateParameter) *) tm.state_parameter; - return t->hd; - } - Local bool ·(TM,_TM·CVT_,SingletonCircle,on_leftmost)( ·(TM,_TM·CVT_) tm ){ - return false; - } - Local bool ·(TM,_TM·CVT_,SingletonCircle,on_rightmost)( ·(TM,_TM·CVT_) tm ){ - return false; - } - - // does nothing if tape is already mounted - Local void ·(TM,_TM·CVT_,SingletonCircle,mount)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,SingletonCircle,StateParameter) *t = (·(TM,_TM·CVT_,SingletonCircle,StateParameter) *) tm.state_parameter; - t->hd = true; - } - Local void ·(TM,_TM·CVT_,SingletonCircle,dismount)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,SingletonCircle,StateParameter) *t = (·(TM,_TM·CVT_,SingletonCircle,StateParameter) *) tm.state_parameter; - t->hd = false; - } - - Local void ·(TM,_TM·CVT_,SingletonCircle,s)( ·(TM,_TM·CVT_) tm ){ - return; - } - Local void ·(TM,_TM·CVT_,SingletonCircle,step_left)( ·(TM,_TM·CVT_) tm ){ - return; - } - Local void ·(TM,_TM·CVT_,SingletonCircle,rewind)( ·(TM,_TM·CVT_) tm ){ - return; - } - - Local _TM·CVT_ ·(TM,_TM·CVT_,SingletonCircle,r)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,SingletonCircle,StateParameter) *t = (·(TM,_TM·CVT_,SingletonCircle,StateParameter) *) tm.state_parameter; - return t->value; - } - Local void ·(TM,_TM·CVT_,SingletonCircle,w)( ·(TM,_TM·CVT_) tm ,_TM·CVT_ *remote_pt ){ - ·(TM,_TM·CVT_,SingletonCircle,StateParameter) *t = (·(TM,_TM·CVT_,SingletonCircle,StateParameter) *) tm.state_parameter; - t->value = *remote_pt; - } - - Local ·(TM,_TM·CVT_,PFT) ·(TM,_TM·CVT_,SingletonCircle,pft) = { - - .topo = ·(TM,_TM·CVT_,SingletonCircle,topo) - ,.bounded = ·(TM,_TM·CVT_,SingletonCircle,bounded) - ,.extent = ·(TM,_TM·CVT_,SingletonCircle,extent) - - ,.status = ·(TM,_TM·CVT_,SingletonCircle,status) - ,.dismounted = ·(TM,_TM·CVT_,SingletonCircle,dismounted) - ,.on_tape = ·(TM,_TM·CVT_,SingletonCircle,on_tape) - ,.on_leftmost = ·(TM,_TM·CVT_,SingletonCircle,on_leftmost) - ,.on_rightmost = ·(TM,_TM·CVT_,SingletonCircle,on_rightmost) - - ,.mount = ·(TM,_TM·CVT_,SingletonCircle,mount) - ,.dismount = ·(TM,_TM·CVT_,SingletonCircle,dismount) - - ,.step = ·(TM,_TM·CVT_,SingletonCircle,s) - ,.step_left = ·(TM,_TM·CVT_,SingletonCircle,step_left) - ,.rewind = ·(TM,_TM·CVT_,SingletonCircle,rewind) - - ,.r = ·(TM,_TM·CVT_,SingletonCircle,r) - ,.w = ·(TM,_TM·CVT_,SingletonCircle,w) - - }; - - /* - tm is up casted from being array specific, to being generic. Later it is downcasted within the array code before being used. This can be seen at the top of each of the array specific function. This is the only loss of static type safety, and it is embedded in the library code. - */ - ·(TM,_TM·CVT_) ·(TM,_TM·CVT_,SingletonCircle,init)( - ·(TM,_TM·CVT_,SingletonCircle,StateParameter) *t - ,_TM·CVT_ initial_value - ){ - t->hd = true; - t->value = initial_value; - - ·(TM,_TM·CVT_) tm = { - .state_parameter = (·(TM,_TM·CVT_,StateParameter) *)t - ,.pft = &·(TM,_TM·CVT_,SingletonCircle,pft) - }; - - return tm; - } - - #endif // #if BOOLEAN(NOT_IN(TM·LOCAL ,TM)) - #endif // #ifdef _TM·CVT_ - -#endif // LOCAL - -/*-------------------------------------------------------------------------------- - Library - compiled into a lib.a file by the current make - Core currently has no library components ---------------------------------------------------------------------------------*/ -#ifdef LIBRARY -#endif - diff --git "a/developer/cc\360\237\226\211/TM\302\267SingletonSegment.lib.c" "b/developer/cc\360\237\226\211/TM\302\267SingletonSegment.lib.c" deleted file mode 100644 index 1dff957..0000000 --- "a/developer/cc\360\237\226\211/TM\302\267SingletonSegment.lib.c" +++ /dev/null @@ -1,178 +0,0 @@ -/* - Namespace: TM·SingletonSegment - - Template parameters: - - `_TM·CVT_` Cell Value Type`. - -*/ -#include "TM.lib.c" - -/*-------------------------------------------------------------------------------- - Interface ---------------------------------------------------------------------------------*/ - -// once per translation unit -#ifndef TM·FACE -#define TM·FACE - - #define TM·SingletonSegment·DEBUG - #ifdef TM·SingletonSegment·DEBUG - #include - #endif - -#endif //#ifndef TM·FACE - -// once per _TM·CVT_ value -// Caller must #define SET_Binding__TM·SingletonSegment·, after inclusion, to prevent re-inclusion -#ifdef _TM·CVT_ -#if BOOLEAN( NOT_IN(Binding ,·(TM·SingletonSegment,_TM·CVT_)) ) -#ifdef TM·SingletonSegment·DEBUG - #pragma message( "Creating TM·SingletonSegment type with a CVT of:" STR_VAL(_TM·CVT_) ) -#endif - - typedef struct{ - bool hd; - _TM·CVT_ value; - } ·(TM,_TM·CVT_,SingletonSegment,StateParameter); - - ·(TM,_TM·CVT_) ·(TM,_TM·CVT_,SingletonSegment,init)( - ·(TM,_TM·CVT_,SingletonSegment,StateParameter) *t - ,_TM·CVT_ initial_value - ); - -#endif -#endif - -/*-------------------------------------------------------------------------------- - Local ---------------------------------------------------------------------------------*/ -#ifdef LOCAL - - // once per translation unit - #ifndef TM·SingletonSegment·LOCAL - #define TM·SingletonSegment·LOCAL - - #endif - - // once per _TM·CVT_ value - // Caller must #define SET_TM·LOCAL__TM·, after inclusion, to prevent re-inclusion - #ifdef _TM·CVT_ - #if BOOLEAN(NOT_IN(TM·LOCAL ,·(TM·SingletonSegment,_TM·CVT_))) - #ifdef TM·SingletonSegment·DEBUG - #pragma message( "Including TM·SingletonSegment LOCAL code for:" STR_VAL(_TM·CVT_) ) - #endif - - Local TM·Topo ·(TM,_TM·CVT_,SingletonSegment,topo)( ·(TM,_TM·CVT_) tm ){ - return TM·Topo·singleton; - } - Local bool ·(TM,_TM·CVT_,SingletonSegment,bounded)( ·(TM,_TM·CVT_) tm ){ - return true; - } - Local ·(extent_t,_TM·CVT_) ·(TM,_TM·CVT_,SingletonSegment,extent)( ·(TM,_TM·CVT_) tm ){ - return 0; - } - Local TM·Status ·(TM,_TM·CVT_,SingletonSegment,status)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,SingletonSegment,StateParameter) *t = (·(TM,_TM·CVT_,SingletonSegment,StateParameter) *) tm.state_parameter; - if( !t->hd ) return TM·Status·dismounted; - return TM·Status·leftmost | TM·Status·rightmost; - } - Local bool ·(TM,_TM·CVT_,SingletonSegment,dismounted)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,SingletonSegment,StateParameter) *t = (·(TM,_TM·CVT_,SingletonSegment,StateParameter) *) tm.state_parameter; - return !t->hd; - } - - // these could be pulled from the tm.pft table, and defined once - Local bool ·(TM,_TM·CVT_,SingletonSegment,on_tape)( ·(TM,_TM·CVT_) tm ){ - return ·(TM,_TM·CVT_,SingletonSegment,status)( tm ) & TM·Status·on_tape; - } - Local bool ·(TM,_TM·CVT_,SingletonSegment,on_leftmost)( ·(TM,_TM·CVT_) tm ){ - return ·(TM,_TM·CVT_,SingletonSegment,status)( tm ) & TM·Status·leftmost; - } - Local bool ·(TM,_TM·CVT_,SingletonSegment,on_rightmost)( ·(TM,_TM·CVT_) tm ){ - return ·(TM,_TM·CVT_,SingletonSegment,status)( tm ) & TM·Status·rightmost; - } - - // does nothing if tape is already mounted - Local void ·(TM,_TM·CVT_,SingletonSegment,mount)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,SingletonSegment,StateParameter) *t = (·(TM,_TM·CVT_,SingletonSegment,StateParameter) *) tm.state_parameter; - t->hd = true; - } - Local void ·(TM,_TM·CVT_,SingletonSegment,dismount)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,SingletonSegment,StateParameter) *t = (·(TM,_TM·CVT_,SingletonSegment,StateParameter) *) tm.state_parameter; - t->hd = false; - } - - Local void ·(TM,_TM·CVT_,SingletonSegment,s)( ·(TM,_TM·CVT_) tm ){ - assert(0); - } - Local void ·(TM,_TM·CVT_,SingletonSegment,step_left)( ·(TM,_TM·CVT_) tm ){ - assert(0); - } - Local void ·(TM,_TM·CVT_,SingletonSegment,rewind)( ·(TM,_TM·CVT_) tm ){ - return; - } - - Local _TM·CVT_ ·(TM,_TM·CVT_,SingletonSegment,r)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,SingletonSegment,StateParameter) *t = (·(TM,_TM·CVT_,SingletonSegment,StateParameter) *) tm.state_parameter; - return t->value; - } - Local void ·(TM,_TM·CVT_,SingletonSegment,w)( ·(TM,_TM·CVT_) tm ,_TM·CVT_ *remote_pt ){ - ·(TM,_TM·CVT_,SingletonSegment,StateParameter) *t = (·(TM,_TM·CVT_,SingletonSegment,StateParameter) *) tm.state_parameter; - t->value = *remote_pt; - } - - Local ·(TM,_TM·CVT_,PFT) ·(TM,_TM·CVT_,SingletonSegment,pft) = { - - .topo = ·(TM,_TM·CVT_,SingletonSegment,topo) - ,.bounded = ·(TM,_TM·CVT_,SingletonSegment,bounded) - ,.extent = ·(TM,_TM·CVT_,SingletonSegment,extent) - - ,.status = ·(TM,_TM·CVT_,SingletonSegment,status) - ,.dismounted = ·(TM,_TM·CVT_,SingletonSegment,dismounted) - ,.on_tape = ·(TM,_TM·CVT_,SingletonSegment,on_tape) - ,.on_leftmost = ·(TM,_TM·CVT_,SingletonSegment,on_leftmost) - ,.on_rightmost = ·(TM,_TM·CVT_,SingletonSegment,on_rightmost) - - ,.mount = ·(TM,_TM·CVT_,SingletonSegment,mount) - ,.dismount = ·(TM,_TM·CVT_,SingletonSegment,dismount) - - ,.step = ·(TM,_TM·CVT_,SingletonSegment,s) - ,.step_left = ·(TM,_TM·CVT_,SingletonSegment,step_left) - ,.rewind = ·(TM,_TM·CVT_,SingletonSegment,rewind) - - ,.r = ·(TM,_TM·CVT_,SingletonSegment,r) - ,.w = ·(TM,_TM·CVT_,SingletonSegment,w) - - }; - - /* - tm is up casted from being array specific, to being generic. Later it is downcasted within the array code before being used. This can be seen at the top of each of the array specific function. This is the only loss of static type safety, and it is embedded in the library code. - */ - ·(TM,_TM·CVT_) ·(TM,_TM·CVT_,SingletonSegment,init)( - ·(TM,_TM·CVT_,SingletonSegment,StateParameter) *t - ,_TM·CVT_ initial_value - ){ - t->hd = true; - t->value = initial_value; - - ·(TM,_TM·CVT_) tm = { - .state_parameter = (·(TM,_TM·CVT_,StateParameter) *)t - ,.pft = &·(TM,_TM·CVT_,SingletonSegment,pft) - }; - - return tm; - } - - #endif // #if BOOLEAN(NOT_IN(TM·LOCAL ,TM)) - #endif // #ifdef _TM·CVT_ - -#endif // LOCAL - -/*-------------------------------------------------------------------------------- - Library - compiled into a lib.a file by the current make - Core currently has no library components ---------------------------------------------------------------------------------*/ -#ifdef LIBRARY -#endif - diff --git "a/developer/cc\360\237\226\211/TM\302\267ZeroLength.lib.c" "b/developer/cc\360\237\226\211/TM\302\267ZeroLength.lib.c" deleted file mode 100644 index 4506cc6..0000000 --- "a/developer/cc\360\237\226\211/TM\302\267ZeroLength.lib.c" +++ /dev/null @@ -1,180 +0,0 @@ -/* - Namespace: TM·ZeroLength - - Template parameters: - - `_TM·CVT_` Cell Value Type`. - -*/ -#include "TM.lib.c" - -/*-------------------------------------------------------------------------------- - Interface ---------------------------------------------------------------------------------*/ - -// once per translation unit -#ifndef TM·ZeroLength·FACE -#define TM·ZeroLength·FACE - - #define TM·ZeroLength·DEBUG - #ifdef TM·ZeroLength·DEBUG - #include - #endif - -#endif //#ifndef TM·FACE - -// once per _TM·CVT_ value -// Caller must #define SET_Binding__TM·ZeroLength·, after inclusion, to prevent re-inclusion -#ifdef _TM·CVT_ -#if BOOLEAN( NOT_IN(Binding ,·(TM·ZeroLength,_TM·CVT_)) ) -#ifdef TM·ZeroLength·DEBUG - #pragma message( "Creating TM·ZeroLength type with a CVT of:" STR_VAL(_TM·CVT_) ) -#endif - - typedef struct{ - bool hd; - } ·(TM,_TM·CVT_,ZeroLength,StateParameter); - - ·(TM,_TM·CVT_) ·(TM,_TM·CVT_,ZeroLength,init)( - ·(TM,_TM·CVT_,ZeroLength,StateParameter) *t - ); - -#endif -#endif - -/*-------------------------------------------------------------------------------- - Local ---------------------------------------------------------------------------------*/ -#ifdef LOCAL - - // once per translation unit - #ifndef TM·ZeroLength·LOCAL - #define TM·ZeroLength·LOCAL - - #endif - - // once per _TM·CVT_ value - // Caller must #define SET_TM·ZeroLength·LOCAL__TM·, after inclusion, to prevent re-inclusion - #ifdef _TM·CVT_ - #if BOOLEAN(NOT_IN(TM·LOCAL ,·(TM·ZeroLength,_TM·CVT_))) - #ifdef TM·ZeroLength·DEBUG - #pragma message( "Including TM·ZeroLength LOCAL code for:" STR_VAL(_TM·CVT_) ) - #endif - - Local TM·Topo ·(TM,_TM·CVT_,ZeroLength,topo)( ·(TM,_TM·CVT_) tm ){ - return TM·Topo·zero_length; - } - - Local bool ·(TM,_TM·CVT_,ZeroLength,bounded)( ·(TM,_TM·CVT_) tm ){ - return true; - } - - Local ·(extent_t,_TM·CVT_) ·(TM,_TM·CVT_,ZeroLength,extent)( ·(TM,_TM·CVT_) tm ){ - assert(0); - } - - Local TM·Status ·(TM,_TM·CVT_,ZeroLength,status)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,ZeroLength,StateParameter) *t = (·(TM,_TM·CVT_,ZeroLength,StateParameter) *) tm.state_parameter; - if( !t->hd ) return TM·Status·dismounted; - return TM·Status·out_of_area; - } - - Local bool ·(TM,_TM·CVT_,ZeroLength,dismounted)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,ZeroLength,StateParameter) *t = (·(TM,_TM·CVT_,ZeroLength,StateParameter) *) tm.state_parameter; - return !t->hd; - } - - Local bool ·(TM,_TM·CVT_,ZeroLength,on_tape)( ·(TM,_TM·CVT_) tm ){ - return false; - } - - Local bool ·(TM,_TM·CVT_,ZeroLength,on_leftmost)( ·(TM,_TM·CVT_) tm ){ - return false; - } - - Local bool ·(TM,_TM·CVT_,ZeroLength,on_rightmost)( ·(TM,_TM·CVT_) tm ){ - return false; - } - - // does nothing if tape is already mounted - Local void ·(TM,_TM·CVT_,ZeroLength,mount)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,ZeroLength,StateParameter) *t = (·(TM,_TM·CVT_,ZeroLength,StateParameter) *) tm.state_parameter; - if( !t->hd ) t->hd = true; - } - - Local void ·(TM,_TM·CVT_,ZeroLength,dismount)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,ZeroLength,StateParameter) *t = (·(TM,_TM·CVT_,ZeroLength,StateParameter) *) tm.state_parameter; - t->hd = false; - } - - Local void ·(TM,_TM·CVT_,ZeroLength,s)( ·(TM,_TM·CVT_) tm ){ - assert(0); - } - - Local void ·(TM,_TM·CVT_,ZeroLength,step_left)( ·(TM,_TM·CVT_) tm ){ - assert(0); - } - - // rewind does nothing if the tape is dismounted - Local void ·(TM,_TM·CVT_,ZeroLength,rewind)( ·(TM,_TM·CVT_) tm ){ - ·(TM,_TM·CVT_,ZeroLength,StateParameter) *t = (·(TM,_TM·CVT_,ZeroLength,StateParameter) *) tm.state_parameter; - if( ·(TM,_TM·CVT_,ZeroLength,dismounted)( tm ) ) return; - assert(0); - } - - Local _TM·CVT_ ·(TM,_TM·CVT_,ZeroLength,r)( ·(TM,_TM·CVT_) tm ){ - assert(0); - } - - Local void ·(TM,_TM·CVT_,ZeroLength,w)( ·(TM,_TM·CVT_) tm ,_TM·CVT_ *remote_pt ){ - assert(0); - } - - Local ·(TM,_TM·CVT_,PFT) ·(TM,_TM·CVT_,ZeroLength,pft) = { - - .topo = ·(TM,_TM·CVT_,ZeroLength,topo) - ,.bounded = ·(TM,_TM·CVT_,ZeroLength,bounded) - ,.extent = ·(TM,_TM·CVT_,ZeroLength,extent) - - ,.status = ·(TM,_TM·CVT_,ZeroLength,status) - ,.dismounted = ·(TM,_TM·CVT_,ZeroLength,dismounted) - ,.on_tape = ·(TM,_TM·CVT_,ZeroLength,on_tape) - ,.on_leftmost = ·(TM,_TM·CVT_,ZeroLength,on_leftmost) - ,.on_rightmost = ·(TM,_TM·CVT_,ZeroLength,on_rightmost) - - ,.mount = ·(TM,_TM·CVT_,ZeroLength,mount) - ,.dismount = ·(TM,_TM·CVT_,ZeroLength,dismount) - - ,.step = ·(TM,_TM·CVT_,ZeroLength,s) - ,.step_left = ·(TM,_TM·CVT_,ZeroLength,step_left) - ,.rewind = ·(TM,_TM·CVT_,ZeroLength,rewind) - - ,.r = ·(TM,_TM·CVT_,ZeroLength,r) - ,.w = ·(TM,_TM·CVT_,ZeroLength,w) - - }; - - ·(TM,_TM·CVT_) ·(TM,_TM·CVT_,ZeroLength,init)( - ·(TM,_TM·CVT_,ZeroLength,StateParameter) *t - ){ - t->hd = true; - ·(TM,_TM·CVT_) tm = { - .state_parameter = (·(TM,_TM·CVT_,StateParameter) *)t - ,.pft = &·(TM,_TM·CVT_,ZeroLength,pft) - }; - return tm; - } - - - #endif // #if BOOLEAN(NOT_IN(TM·LOCAL ,TM)) - #endif // #ifdef _TM·CVT_ - -#endif // LOCAL - -/*-------------------------------------------------------------------------------- - Library - compiled into a lib.a file by the current make - Core currently has no library components ---------------------------------------------------------------------------------*/ -#ifdef LIBRARY -#endif - diff --git "a/developer/cc\360\237\226\211/cpp_ext.c" "b/developer/cc\360\237\226\211/cpp_ext.c" deleted file mode 100644 index 6cff205..0000000 --- "a/developer/cc\360\237\226\211/cpp_ext.c" +++ /dev/null @@ -1,19 +0,0 @@ -#ifndef CPP_EXT -#define CPP_EXT - - #include "cpp_ext_0.c" - #include "cpp_ext_1.c" - - /* - CONTAINS requires registration of pattern, as examples: - - #define EQ__int__oo__int - #define EQ__float__oo__float - #define EQ__char__oo__char - #define EQ__void__oo__void - - */ - - #define ·(...) CAT(· ,__VA_ARGS__) - -#endif diff --git "a/developer/cc\360\237\226\211/cpp_ext_0.c" "b/developer/cc\360\237\226\211/cpp_ext_0.c" deleted file mode 100644 index a04d08d..0000000 --- "a/developer/cc\360\237\226\211/cpp_ext_0.c" +++ /dev/null @@ -1,290 +0,0 @@ -/* - See also - https://github.com/18sg/uSHET/blob/master/lib/cpp_magic.h - and tutorial at: http://jhnet.co.uk/articles/cpp_magic - - documents in $REPO_HOME/developer/document🖉 - -1. We use a truth of existence - - An empty value is false. Anything else is true. Hence, even the token '0' is true. - -2. todo - -- cpp_ext as separate project -- make the try into tests -- cpp_ext macros put into a namespace to prevent aliasing - -*/ - -#ifndef CPP_EXT_0 -#define CPP_EXT_0 - -/*--------------------------------------------------------------------------- - DEBUG ----------------------------------------------------------------------------*/ - -#include -#define DEBUG_CPP - -// print the macro and the evaluation of the macro at compile time: -// #pragma message( STR_VAL() ) - -#define STR(...) #__VA_ARGS__ -#define VAL(...) STR(__VA_ARGS__) -#define STR_VAL(...) #__VA_ARGS__ " -> " VAL(__VA_ARGS__) - -// print the macro and the evaluation of the macro at run time: -#define SHOW(expr) printf("%s -> %s\n", #expr, STR(expr)); - -/*--------------------------------------------------------------------------- -Constants ----------------------------------------------------------------------------*/ - -#define NOTHING - -#define COMMA , -#define SEMICOLON ; - -// 'twion' is a two component object that masquerades as a single object -#define _TWION_0 ~,0 -#define _TWION_1 ~,1 - -/*--------------------------------------------------------------------------- -Fixed arg count concatenation - - Not implemented for elegance, rather CAT is used to force evaluation of arguments before `##`. -*/ - -#define _CAT2(a ,b) a ## b -#define CAT2(a ,b) _CAT2(a ,b) - -#define _CAT3(a ,b ,c) a ## b ## c -#define CAT3(a ,b ,c) _CAT3(a ,b ,c) - -#define _CAT4(a ,b ,c ,d) a ## b ## c ## d -#define CAT4(a ,b ,c ,d) _CAT4(a ,b ,c ,d) - -/*--------------------------------------------------------------------------- -LOGIC - - empty - false - NOT() - not empty, is true -*/ - - //---------------------------------------- - // primitive access - - // _FIRST with zero arguments returns nothing, otherwise returns first token - // in the list, which can also be nothing. e.g. _FIRST(,2,3) returns nothing. - #define _FIRST(a ,...) a - - // _SECOND must be given a list of length 2, though no tokens need be given - #define _SECOND(a ,b ,...) b - - //---------------------------------------- - // given one or zero arguments, returns nothing - // - #define RETURN_NOTHING() - - //---------------------------------------- - // given a list returns a token - // given an token returns a token - // given nothing, returns nothing - // - #define _OR(...) _FIRST(RETURN_NOTHING __VA_ARGS__ ()) - - /*---------------------------------------- - given a token returns nothing - given nothing returns 1 - - `##` prevents rewrite of _TWION_ in the _EXISTS_TOKEN_1 macro, don't - replace that with CAT! - */ - #define _NOT_TOKEN_ss(x_token) _SECOND(x_token ,) - #define _NOT_TOKEN_s(x_token) _NOT_TOKEN_ss(_TWION_1##x_token) - #define _NOT_TOKEN(x_token) _NOT_TOKEN_s(x_token) - - /*---------------------------------------- - given a token or a list, returns nothing - given nothing, returns 1 - */ - #define NOT(...) _NOT_TOKEN( _OR(__VA_ARGS__) ) - - /*---------------------------------------- - given argument is empty returns empty - given argument is not empty, returns 1 - */ - #define EXISTS(...) NOT( NOT(__VA_ARGS__) ) - - // useful synonym - #define MATCH_RWR(x) NOT(x) - -/*--------------------------------------------------------------------------- - IF-ELSE construct. - Usage: IF_ELSE(condition)()() - - A most amazing little macro. It has no dependencies on the other macros - in this file, though many of those will be useful in predicates -*/ - - #define IF(...) CAT2(_IF_ ,EXISTS(__VA_ARGS__)) - #define _IF_1(...) __VA_ARGS__ _IF_1_ELSE - #define _IF_(...) _IF__ELSE - #define _IF_1_ELSE(...) - #define _IF__ELSE(...) __VA_ARGS__ - -/*--------------------------------------------------------------------------- - - In cpp_ext logic: - ε is false and anything else is true - - In BOOLEAN logic - ε is an error, 0 is false, anything else is true - - USE this operator to convert something in cpp_ext logic to something for - the built-in operators. - - Note the output of BOOLEAN is always an existing token, so it will - aways be 'true' in cpp_ext logic. - -*/ - #define BOOLEAN(...) IF(__VA_ARGS__) (1) (0) - - -/*--------------------------------------------------------------------------- - Logic connectors -*/ - #define LEQ2(x ,y) IF(x) (y) (NOT(y)) - #define XOR2(x ,y) IF(x) (NOT(y)) (y) - #define AND2(x ,y) IF(x) (y) () - #define OR2(x ,y) IF(x) (1) (y) - -/*--------------------------------------------------------------------------- - Set - User must define set members manually: - - #define __ - - For example a set named TRIP with 1 ,2 ,3 in it: - - #define SET_TRIP__1 - #define SET_TRIP__2 - #define SET_TRIP__3 - -*/ - -#define IN(name ,x) NOT(CAT4(SET_ ,name ,__ ,x)) -#define NOT_IN(name ,x) CAT4(SET_ ,name ,__ ,x) - - -/*--------------------------------------------------------------------------- - Registered Equivalence - - Checks if x and y have been paired in a rewrite rule. - - Logic values can not be paired, as anything except an empty argument is taken as true. - - each pairing rule has the form - EQ____oo__ - - for example: - #define EQ__APPLE__oo__APPLE - #define EQ__PEAR__oo__PEAR - - SHOW( EQ(APPLE ,APPLE) ); -> 1 - SHOW( EQ(APPLE ,PEAR) ); -> ε - - // if empty should be EQ to empty, add this - // without this, EQ(,) -> ε - #define EQ____oo__ - ----------------------------------------------------------------------------*/ - - // if empty should be EQ to empty, keep this - // without this, EQ(,) -> ε - #define EQ____oo__ - - #define EQ__0__oo__0 - #define EQ__1__oo__1 - - #define EQ(x_token ,y_token) MATCH_RWR( CAT4(EQ__ ,x_token ,__oo__ ,y_token) ) - -/*--------------------------------------------------------------------------- -Remainder of list ----------------------------------------------------------------------------*/ - - #define _REST(a ,...) __VA_ARGS__ - #define REST(...)\ - IF \ - (__VA_ARGS__) \ - ( _REST(__VA_ARGS__) ) \ - () - -#endif -/* - _FIRST(1) -> 1 - _FIRST() -> - _SECOND(1,2) -> 2 - _SECOND(1,) -> - - RETURN_NOTHING() -> - - _OR() -> - _OR(1) -> RETURN_NOTHING 1 () - _OR(1,2,3) -> RETURN_NOTHING 1 - - T(x) -> 7 - _NOT_ITEM() -> _NOT_ITEM() - _NOT_ITEM(1) -> _NOT_ITEM(1) - _NOT_ITEM(T(x)) -> _NOT_ITEM(7) - - NOT() -> 1 - NOT(1) -> - NOT(T(x)) -> - NOT(1,2,3) -> - - BOOL() -> BOOL() - CAT2(_IF_ ,BOOL()) -> _IF_BOOL() - - TO_1_OR_0() -> TO_1_OR_0() - TO_1_OR_0(1) -> TO_1_OR_0(1) - TO_1_OR_0(x) -> TO_1_OR_0(x) - TO_1_OR_0(1.2.3) -> TO_1_OR_0(1.2.3) - - EXISTS() -> - EXISTS(0) -> 1 - EXISTS(x,y,z) -> 1 - - LEQ2( , ) -> 1 - LEQ2( , 1 ) -> - LEQ2( 1, ) -> - LEQ2( 1, 0 ) -> 0 - - XOR2( , ) -> - XOR2( , 0 ) -> 0 - XOR2( 0, 0 ) -> - - AND2( , 0 ) -> - AND2( 0, 1 ) -> 1 - - OR2( , ) -> - OR2( , 0 ) -> 0 - - EQ(APPLE ,APPLE) -> 1 - EQ(APPLE ,PEAR) -> - EQ(PEAR ,PEAR) -> 1 - EQ(,) -> 1 - EQ(,PEAR) -> - EQ(PEAR ,) -> - - BOOLEAN() -> 0 - BOOLEAN(0) -> 1 - BOOLEAN(foo) -> 1 - BOOLEAN(1,2,3) -> 1 - - REST() -> - REST(1) -> - REST(1,2) -> 2 - REST(1,2,3) -> 2,3 -*/ diff --git "a/developer/cc\360\237\226\211/cpp_ext_1.c" "b/developer/cc\360\237\226\211/cpp_ext_1.c" deleted file mode 100644 index 788c57a..0000000 --- "a/developer/cc\360\237\226\211/cpp_ext_1.c" +++ /dev/null @@ -1,195 +0,0 @@ -/* -These are the recursive extension. - -Simple errors can lead to very long error outputs, which might be why -the cpp designers had obviously intended that recursion would not be possible. - -To be added: - -LIST_TOO_LONG - -cleanup list -DROP_EMPTY_ALL -DROP_EMPTY_LEFT -DROPE_EMPTY_RIGHT - -#define CAT(sep,first,...) \ - -Instead of comma separated lists consider instead to make a list with #define: -``` -#define LIST_1 -#define LIST_2 - -#ifdef LIST_2 - ... -`` - -*/ - -#ifndef CPP_EXT_1 -#define CPP_EXT_1 - -/*--------------------------------------------------------------------------- - Force extra macro expansion (the EVAL trick) - This chain of EVAL macros forces the preprocessor to perform many rescans, - which is necessary to “unroll” recursive macros. ----------------------------------------------------------------------------*/ - //#define EVAL(...) EVAL1024(__VA_ARGS__) - #define EVAL(...) EVAL32(__VA_ARGS__) - #define EVAL1024(...) EVAL512(EVAL512(__VA_ARGS__)) - #define EVAL512(...) EVAL256(EVAL256(__VA_ARGS__)) - #define EVAL256(...) EVAL128(EVAL128(__VA_ARGS__)) - #define EVAL128(...) EVAL64(EVAL64(__VA_ARGS__)) - #define EVAL64(...) EVAL32(EVAL32(__VA_ARGS__)) - #define EVAL32(...) EVAL16(EVAL16(__VA_ARGS__)) - #define EVAL16(...) EVAL8(EVAL8(__VA_ARGS__)) - #define EVAL8(...) EVAL4(EVAL4(__VA_ARGS__)) - #define EVAL4(...) EVAL2(EVAL2(__VA_ARGS__)) - #define EVAL2(...) EVAL1(EVAL1(__VA_ARGS__)) - #define EVAL1(...) __VA_ARGS__ - -/*--------------------------------------------------------------------------- - Defer macros: these help “hide” recursive calls for additional expansion passes. ----------------------------------------------------------------------------*/ -// defined in cpp_ext_0: RETURN_NOTHING() - - #define DEFER1(m) \ - m RETURN_NOTHING() - #define DEFER2(m) \ - m RETURN_NOTHING RETURN_NOTHING()() - #define DEFER3(m) \ - m RETURN_NOTHING RETURN_NOTHING RETURN_NOTHING()()() - #define DEFER4(m) \ - m RETURN_NOTHING RETURN_NOTHING RETURN_NOTHING RETURN_NOTHING()()()() - #define DEFER5(m) \ - m RETURN_NOTHING RETURN_NOTHING RETURN_NOTHING RETURN_NOTHING RETURN_NOTHING()()()()() - -/*--------------------------------------------------------------------------- - List operations - - number of EVALs required depends upon length list that is processed - - REST will return nothing on one of two conditions: that the list has - been exhausted, or that the list is about to be exhausted and it has nothing - after the last comma. To assure that a tailing item always gets sent - to the predicate, even when empty, we append an empty item. - ----------------------------------------------------------------------------*/ - // defined in cpp_ext_0: _FIRST(a ,...) a - - // returns found item or EOL() - #define _FIND(predicate ,...) \ - IF \ - (__VA_ARGS__) \ - (IF \ - ( predicate(_FIRST(__VA_ARGS__)) ) \ - ( _FIRST(__VA_ARGS__) ) \ - ( DEFER3(_FIND_CONFEDERATE)()(predicate ,REST(__VA_ARGS__)) ) \ - ) \ - (EOL()) - #define _FIND_CONFEDERATE() _FIND - #define FIND(predicate ,...) EVAL( _FIND(predicate ,__VA_ARGS__ ,) ) - - // true if list exhausted, false otherwise - #define _WHILE(predicate ,...) \ - IF \ - (__VA_ARGS__) \ - (IF \ - ( predicate(_FIRST(__VA_ARGS__)) ) \ - ( DEFER3(_WHILE_CONFEDERATE)()(predicate ,REST(__VA_ARGS__)) ) \ - () \ - ) \ - (1) - #define _WHILE_CONFEDERATE() _WHILE - #define WHILE(predicate ,...) EVAL( _WHILE(predicate ,__VA_ARGS__ ,) ) - - // returns true or false - #define _CONTAINS(item ,...) \ - IF \ - (__VA_ARGS__) \ - (IF \ - ( EQ(item ,_FIRST(__VA_ARGS__)) ) \ - ( 1 ) \ - ( DEFER3(_CONTAINS_CONFEDERATE)()(item ,REST(__VA_ARGS__)) ) \ - ) \ - () - #define _CONTAINS_CONFEDERATE() _CONTAINS - #define CONTAINS(predicate ,...) EVAL( _CONTAINS(predicate ,__VA_ARGS__ ,) ) - - // if no list, returns EOL(), else returns last item in the list - #define _LAST(...) \ - IF \ - (__VA_ARGS__) \ - ( _LAST_s(_FIRST(__VA_ARGS__) ,REST(__VA_ARGS__)) ) \ - (EOL()) - #define _LAST_s(item, ...) \ - IF \ - (__VA_ARGS__) \ - ( DEFER3(_LAST_s_CONFEDERATE)()(_FIRST(__VA_ARGS__) ,REST(__VA_ARGS__)) ) \ - (item) - #define _LAST_s_CONFEDERATE() _LAST_s - #define LAST(...) EVAL( _LAST(__VA_ARGS__ ,) ) - - #define CAT(sep ,...) \ - IF \ - (__VA_ARGS__) \ - (_CAT_s( sep ,__VA_ARGS__)) \ - () - - #define _CAT_s(sep ,a ,...)\ - IF \ - (__VA_ARGS__) \ - ( EVAL(_CAT_ss(sep ,a ,__VA_ARGS__)) ) \ - (a) - - #define _CAT_ss(sep ,accumulator ,a ,...) \ - IF \ - (__VA_ARGS__) \ - ( DEFER2(_CAT_ss_CONFEDERATE)()(sep ,accumulator##sep##a ,__VA_ARGS__) ) \ - (accumulator##sep##a) - - #define _CAT_ss_CONFEDERATE() _CAT_ss - - // comma does not work with CAT so use this, though perhaps list ,a would be faster? - #define APPEND(...) \ - IF \ - (__VA_ARGS__) \ - (_APPEND_s(__VA_ARGS__)) \ - () - - #define _APPEND_s(a ,...)\ - IF \ - (__VA_ARGS__) \ - ( EVAL(_APPEND_ss(a ,__VA_ARGS__)) ) \ - (a) - - #define _APPEND_ss(accumulator ,a ,...) \ - IF \ - (__VA_ARGS__) \ - ( DEFER2(_APPEND_ss_CONFEDERATE)()(accumulator, a, ,__VA_ARGS__) ) \ - (accumulator,a) - - #define _APPEND_ss_CONFEDERATE() _APPEND_ss - - -/*--------------------------------------------------------------------------- - Quantifiers ----------------------------------------------------------------------------*/ - - // AKA all quantification, returns true or false - #define AND(...) WHILE(EXISTS ,__VA_ARGS__) - - // AKA existence quantification, returns true or false - #define OR(...) NOT( WHILE(NOT ,__VA_ARGS__) ) - -/*--------------------------------------------------------------------------- - Access ----------------------------------------------------------------------------*/ - - #define FIRST(...) \ - IF( __VA_ARGS__ ) \ - ( _FIRST(__VA_ARGS__) ) \ - (EOL()) - - -#endif diff --git "a/developer/cc\360\237\226\211/scratch.c" "b/developer/cc\360\237\226\211/scratch.c" deleted file mode 100644 index 1e39535..0000000 --- "a/developer/cc\360\237\226\211/scratch.c" +++ /dev/null @@ -1,7 +0,0 @@ -// #if BOOLEAN( NOT_IN(TM·Array ,_TM·CVT_) ) -// #include ... -// #define ... -// - - -#if BOOLEAN( NOT_IN(TM·Array ,_TM·CVT_) ) diff --git "a/developer/deprecated\360\237\226\211/.githolder" b/developer/deprecated/.githolder similarity index 100% rename from "developer/deprecated\360\237\226\211/.githolder" rename to developer/deprecated/.githolder diff --git "a/developer/deprecated\360\237\226\211/2025-03-29/N16.lib.c" b/developer/deprecated/2025-03-29/N16.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/2025-03-29/N16.lib.c" rename to developer/deprecated/2025-03-29/N16.lib.c diff --git "a/developer/deprecated\360\237\226\211/2025-03-29/N32.lib.c" b/developer/deprecated/2025-03-29/N32.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/2025-03-29/N32.lib.c" rename to developer/deprecated/2025-03-29/N32.lib.c diff --git "a/developer/deprecated\360\237\226\211/2025-03-29/N64.lib.c" b/developer/deprecated/2025-03-29/N64.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/2025-03-29/N64.lib.c" rename to developer/deprecated/2025-03-29/N64.lib.c diff --git "a/developer/deprecated\360\237\226\211/2025-03-29/N8.lib.c" b/developer/deprecated/2025-03-29/N8.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/2025-03-29/N8.lib.c" rename to developer/deprecated/2025-03-29/N8.lib.c diff --git "a/developer/deprecated\360\237\226\211/2025-03-29/TM_scratch.c" b/developer/deprecated/2025-03-29/TM_scratch.c similarity index 100% rename from "developer/deprecated\360\237\226\211/2025-03-29/TM_scratch.c" rename to developer/deprecated/2025-03-29/TM_scratch.c diff --git "a/developer/deprecated\360\237\226\211/2025-03-29/environment.h" b/developer/deprecated/2025-03-29/environment.h similarity index 100% rename from "developer/deprecated\360\237\226\211/2025-03-29/environment.h" rename to developer/deprecated/2025-03-29/environment.h diff --git "a/developer/deprecated\360\237\226\211/2025-03-29/test_setup.cli.c" b/developer/deprecated/2025-03-29/test_setup.cli.c similarity index 100% rename from "developer/deprecated\360\237\226\211/2025-03-29/test_setup.cli.c" rename to developer/deprecated/2025-03-29/test_setup.cli.c diff --git "a/developer/deprecated\360\237\226\211/2025-03-29/update.lib.c" b/developer/deprecated/2025-03-29/update.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/2025-03-29/update.lib.c" rename to developer/deprecated/2025-03-29/update.lib.c diff --git "a/developer/deprecated\360\237\226\211/About_Python_templates.org" b/developer/deprecated/About_Python_templates.org similarity index 100% rename from "developer/deprecated\360\237\226\211/About_Python_templates.org" rename to developer/deprecated/About_Python_templates.org diff --git "a/developer/deprecated\360\237\226\211/Copy.lib.c" b/developer/deprecated/Copy.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/Copy.lib.c" rename to developer/deprecated/Copy.lib.c diff --git "a/developer/deprecated\360\237\226\211/Copy.lib_2.c" b/developer/deprecated/Copy.lib_2.c similarity index 100% rename from "developer/deprecated\360\237\226\211/Copy.lib_2.c" rename to developer/deprecated/Copy.lib_2.c diff --git "a/developer/deprecated\360\237\226\211/Core_with_tableau.lib.c" b/developer/deprecated/Core_with_tableau.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/Core_with_tableau.lib.c" rename to developer/deprecated/Core_with_tableau.lib.c diff --git "a/developer/deprecated\360\237\226\211/Map.lib.c" b/developer/deprecated/Map.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/Map.lib.c" rename to developer/deprecated/Map.lib.c diff --git "a/developer/deprecated\360\237\226\211/Map2.lib.c" b/developer/deprecated/Map2.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/Map2.lib.c" rename to developer/deprecated/Map2.lib.c diff --git "a/developer/deprecated\360\237\226\211/NN_Count_Digit.lib.c" b/developer/deprecated/NN_Count_Digit.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/NN_Count_Digit.lib.c" rename to developer/deprecated/NN_Count_Digit.lib.c diff --git "a/developer/deprecated\360\237\226\211/N_32_test.cli.c" b/developer/deprecated/N_32_test.cli.c similarity index 100% rename from "developer/deprecated\360\237\226\211/N_32_test.cli.c" rename to developer/deprecated/N_32_test.cli.c diff --git "a/developer/deprecated\360\237\226\211/Natural_32.lib.c" b/developer/deprecated/Natural_32.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/Natural_32.lib.c" rename to developer/deprecated/Natural_32.lib.c diff --git "a/developer/deprecated\360\237\226\211/Natural_32_0.lib.c" b/developer/deprecated/Natural_32_0.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/Natural_32_0.lib.c" rename to developer/deprecated/Natural_32_0.lib.c diff --git "a/developer/deprecated\360\237\226\211/adding_new_N_types.org" b/developer/deprecated/adding_new_N_types.org similarity index 100% rename from "developer/deprecated\360\237\226\211/adding_new_N_types.org" rename to developer/deprecated/adding_new_N_types.org diff --git "a/developer/deprecated\360\237\226\211/copy.lib.c" b/developer/deprecated/copy.lib.c similarity index 100% rename from "developer/deprecated\360\237\226\211/copy.lib.c" rename to developer/deprecated/copy.lib.c diff --git "a/developer/deprecated\360\237\226\211/scatch.c" b/developer/deprecated/scatch.c similarity index 100% rename from "developer/deprecated\360\237\226\211/scatch.c" rename to developer/deprecated/scatch.c diff --git "a/developer/deprecated\360\237\226\211/test_Natural_32_0.cli.c" b/developer/deprecated/test_Natural_32_0.cli.c similarity index 100% rename from "developer/deprecated\360\237\226\211/test_Natural_32_0.cli.c" rename to developer/deprecated/test_Natural_32_0.cli.c diff --git "a/developer/document\360\237\226\211/.githolder" b/developer/document/.githolder similarity index 100% rename from "developer/document\360\237\226\211/.githolder" rename to developer/document/.githolder diff --git "a/developer/document\360\237\226\211/Binding.org" b/developer/document/Binding.org similarity index 100% rename from "developer/document\360\237\226\211/Binding.org" rename to developer/document/Binding.org diff --git "a/developer/document\360\237\226\211/C_features_needed.org" b/developer/document/C_features_needed.org similarity index 100% rename from "developer/document\360\237\226\211/C_features_needed.org" rename to developer/document/C_features_needed.org diff --git "a/developer/document\360\237\226\211/Copy.org" b/developer/document/Copy.org similarity index 100% rename from "developer/document\360\237\226\211/Copy.org" rename to developer/document/Copy.org diff --git "a/developer/document\360\237\226\211/FG_tables.org" b/developer/document/FG_tables.org similarity index 100% rename from "developer/document\360\237\226\211/FG_tables.org" rename to developer/document/FG_tables.org diff --git "a/developer/document\360\237\226\211/TapeMachine_howto.org" b/developer/document/TapeMachine_howto.org similarity index 100% rename from "developer/document\360\237\226\211/TapeMachine_howto.org" rename to developer/document/TapeMachine_howto.org diff --git "a/developer/document\360\237\226\211/alignment.org" b/developer/document/alignment.org similarity index 100% rename from "developer/document\360\237\226\211/alignment.org" rename to developer/document/alignment.org diff --git "a/developer/document\360\237\226\211/build.org" b/developer/document/build.org similarity index 100% rename from "developer/document\360\237\226\211/build.org" rename to developer/document/build.org diff --git "a/developer/document\360\237\226\211/coffee.txt" b/developer/document/coffee.txt similarity index 100% rename from "developer/document\360\237\226\211/coffee.txt" rename to developer/document/coffee.txt diff --git "a/developer/document\360\237\226\211/cpp_gothyas.txt" b/developer/document/cpp_gothyas.txt similarity index 100% rename from "developer/document\360\237\226\211/cpp_gothyas.txt" rename to developer/document/cpp_gothyas.txt diff --git "a/developer/document\360\237\226\211/cpp_grammar.org" b/developer/document/cpp_grammar.org similarity index 100% rename from "developer/document\360\237\226\211/cpp_grammar.org" rename to developer/document/cpp_grammar.org diff --git "a/developer/document\360\237\226\211/cpp_macro_expansion.org" b/developer/document/cpp_macro_expansion.org similarity index 100% rename from "developer/document\360\237\226\211/cpp_macro_expansion.org" rename to developer/document/cpp_macro_expansion.org diff --git "a/developer/document\360\237\226\211/parameterized_functions.org" b/developer/document/parameterized_functions.org similarity index 100% rename from "developer/document\360\237\226\211/parameterized_functions.org" rename to developer/document/parameterized_functions.org diff --git "a/developer/document\360\237\226\211/set_list.org" b/developer/document/set_list.org similarity index 100% rename from "developer/document\360\237\226\211/set_list.org" rename to developer/document/set_list.org diff --git "a/developer/document\360\237\226\211/source_file_sectioins.org" b/developer/document/source_file_sectioins.org similarity index 100% rename from "developer/document\360\237\226\211/source_file_sectioins.org" rename to developer/document/source_file_sectioins.org diff --git "a/developer/document\360\237\226\211/template_in_C.org" b/developer/document/template_in_C.org similarity index 100% rename from "developer/document\360\237\226\211/template_in_C.org" rename to developer/document/template_in_C.org diff --git "a/developer/document\360\237\226\211/todo.org" b/developer/document/todo.org similarity index 100% rename from "developer/document\360\237\226\211/todo.org" rename to developer/document/todo.org diff --git "a/developer/tool\360\237\226\211/clean" b/developer/tool/clean similarity index 100% rename from "developer/tool\360\237\226\211/clean" rename to developer/tool/clean diff --git "a/developer/tool\360\237\226\211/env" b/developer/tool/env similarity index 100% rename from "developer/tool\360\237\226\211/env" rename to developer/tool/env diff --git "a/developer/tool\360\237\226\211/make" b/developer/tool/make similarity index 100% rename from "developer/tool\360\237\226\211/make" rename to developer/tool/make diff --git "a/developer/tool\360\237\226\211/makefile" b/developer/tool/makefile similarity index 100% rename from "developer/tool\360\237\226\211/makefile" rename to developer/tool/makefile diff --git "a/developer/tool\360\237\226\211/release" b/developer/tool/release similarity index 100% rename from "developer/tool\360\237\226\211/release" rename to developer/tool/release diff --git "a/developer/tool\360\237\226\211/release_clean" b/developer/tool/release_clean similarity index 100% rename from "developer/tool\360\237\226\211/release_clean" rename to developer/tool/release_clean diff --git "a/document\360\237\226\211/#Model.org#" b/document/#Model.org# similarity index 100% rename from "document\360\237\226\211/#Model.org#" rename to document/#Model.org# diff --git "a/document\360\237\226\211/#temp.txt#" b/document/#temp.txt# similarity index 100% rename from "document\360\237\226\211/#temp.txt#" rename to document/#temp.txt# diff --git "a/document\360\237\226\211/.githolder" b/document/.githolder similarity index 100% rename from "document\360\237\226\211/.githolder" rename to document/.githolder diff --git "a/document\360\237\226\211/Abstracting_Type_in_C.org" b/document/Abstracting_Type_in_C.org similarity index 100% rename from "document\360\237\226\211/Abstracting_Type_in_C.org" rename to document/Abstracting_Type_in_C.org diff --git "a/document\360\237\226\211/Inclusive_Exclusive_interval_bounds.org" b/document/Inclusive_Exclusive_interval_bounds.org similarity index 100% rename from "document\360\237\226\211/Inclusive_Exclusive_interval_bounds.org" rename to document/Inclusive_Exclusive_interval_bounds.org diff --git "a/document\360\237\226\211/Model.org" b/document/Model.org similarity index 100% rename from "document\360\237\226\211/Model.org" rename to document/Model.org diff --git "a/document\360\237\226\211/RT_C_namespace.org" b/document/RT_C_namespace.org similarity index 100% rename from "document\360\237\226\211/RT_C_namespace.org" rename to document/RT_C_namespace.org diff --git "a/document\360\237\226\211/RT_C_tableau_methhod.org" b/document/RT_C_tableau_methhod.org similarity index 100% rename from "document\360\237\226\211/RT_C_tableau_methhod.org" rename to document/RT_C_tableau_methhod.org diff --git "a/document\360\237\226\211/RT_cli_c_file.org" b/document/RT_cli_c_file.org similarity index 100% rename from "document\360\237\226\211/RT_cli_c_file.org" rename to document/RT_cli_c_file.org diff --git "a/document\360\237\226\211/RT_lib_c_file.org" b/document/RT_lib_c_file.org similarity index 100% rename from "document\360\237\226\211/RT_lib_c_file.org" rename to document/RT_lib_c_file.org diff --git "a/document\360\237\226\211/User_manual.org" b/document/User_manual.org similarity index 100% rename from "document\360\237\226\211/User_manual.org" rename to document/User_manual.org diff --git "a/document\360\237\226\211/continuations.org" b/document/continuations.org similarity index 100% rename from "document\360\237\226\211/continuations.org" rename to document/continuations.org diff --git "a/document\360\237\226\211/emacs_keys.el" b/document/emacs_keys.el similarity index 100% rename from "document\360\237\226\211/emacs_keys.el" rename to document/emacs_keys.el diff --git "a/document\360\237\226\211/temp.txt" b/document/temp.txt similarity index 100% rename from "document\360\237\226\211/temp.txt" rename to document/temp.txt diff --git "a/document\360\237\226\211/unicode_character_use.org" b/document/unicode_character_use.org similarity index 100% rename from "document\360\237\226\211/unicode_character_use.org" rename to document/unicode_character_use.org diff --git "a/tester/cc\360\237\226\211/environment.h" b/tester/cc/cc/environment.h similarity index 100% rename from "tester/cc\360\237\226\211/environment.h" rename to tester/cc/cc/environment.h diff --git "a/tester/cc\360\237\226\211/test_Copy_0.cli.c" b/tester/cc/cc/test_Copy_0.cli.c similarity index 100% rename from "tester/cc\360\237\226\211/test_Copy_0.cli.c" rename to tester/cc/cc/test_Copy_0.cli.c diff --git "a/tester/cc\360\237\226\211/test_setup.cli.c" b/tester/cc/cc/test_setup.cli.c similarity index 100% rename from "tester/cc\360\237\226\211/test_setup.cli.c" rename to tester/cc/cc/test_setup.cli.c diff --git "a/tester/deprecated\360\237\226\211/test_N32.cli.c" b/tester/deprecated/test_N32.cli.c similarity index 100% rename from "tester/deprecated\360\237\226\211/test_N32.cli.c" rename to tester/deprecated/test_N32.cli.c diff --git "a/tester/document\360\237\226\211/build_procedure.org" b/tester/document/build_procedure.org similarity index 100% rename from "tester/document\360\237\226\211/build_procedure.org" rename to tester/document/build_procedure.org diff --git "a/tester/tool\360\237\226\211/clean" b/tester/tool/clean similarity index 100% rename from "tester/tool\360\237\226\211/clean" rename to tester/tool/clean diff --git "a/tester/tool\360\237\226\211/env" b/tester/tool/env similarity index 100% rename from "tester/tool\360\237\226\211/env" rename to tester/tool/env diff --git "a/tester/tool\360\237\226\211/make" b/tester/tool/make similarity index 100% rename from "tester/tool\360\237\226\211/make" rename to tester/tool/make diff --git "a/tester/tool\360\237\226\211/makefile" b/tester/tool/makefile similarity index 100% rename from "tester/tool\360\237\226\211/makefile" rename to tester/tool/makefile diff --git "a/tester/tool\360\237\226\211/release_pull" b/tester/tool/release_pull similarity index 100% rename from "tester/tool\360\237\226\211/release_pull" rename to tester/tool/release_pull diff --git "a/tester/tool\360\237\226\211/release_remove" b/tester/tool/release_remove similarity index 100% rename from "tester/tool\360\237\226\211/release_remove" rename to tester/tool/release_remove diff --git "a/tool\360\237\226\211/add_git_holder" b/tool/add_git_holder similarity index 100% rename from "tool\360\237\226\211/add_git_holder" rename to tool/add_git_holder diff --git "a/tool\360\237\226\211/env" b/tool/env similarity index 100% rename from "tool\360\237\226\211/env" rename to tool/env diff --git "a/tool_shared/bespoke\360\237\226\211/env" b/tool_shared/bespoke/env similarity index 100% rename from "tool_shared/bespoke\360\237\226\211/env" rename to tool_shared/bespoke/env diff --git "a/tool_shared/bespoke\360\237\226\211/version" b/tool_shared/bespoke/version similarity index 100% rename from "tool_shared/bespoke\360\237\226\211/version" rename to tool_shared/bespoke/version diff --git "a/tool_shared/document\360\237\226\211/install.txt" b/tool_shared/document/install.txt similarity index 100% rename from "tool_shared/document\360\237\226\211/install.txt" rename to tool_shared/document/install.txt -- 2.20.1