Kevin Day [Sun, 2 Jul 2023 02:38:33 +0000 (21:38 -0500)]
Update: Add man pages for most or all FLL functions.
This is a huge amount of work.
I attempted to use several tools and doxygen had the best results.
The doxygen did a tolerable job but did not do a good job.
In fact, the man page generation of doxygen is horrible.
I instead used doxygen to create XML and then use a tool called doxy2man.
The end result is a barely tolerable man page.
I then had to go through and mass change the files due to problems.
I've brute-force stripped out a lot of messed up parts rather than try to address them.
Some of the data I did manually add or tweak and this task is incredibly tedius.
I observed that a lot of the documentation regarding function returns never completely made it into the man pages.
This means that the man pages are incomplete.
This is, however, better than nothing.
In the long term I can see myself writing my own parser (which makes me cringe).
I believe that I need to create a man page alternative program that uses the FSS formats for a more sane and more readable format.
This is not happening now or any time soon.
I specifically used doxywizard for the doxygen and the following is the configuration settings with the comments removed.
DOXYFILE_ENCODING = UTF-8
PROJECT_NAME = FLL
PROJECT_NUMBER = 0.6.6
PROJECT_BRIEF =
PROJECT_LOGO =
OUTPUT_DIRECTORY = generated
CREATE_SUBDIRS = NO
ALLOW_UNICODE_NAMES = NO
OUTPUT_LANGUAGE = English
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = YES
ABBREVIATE_BRIEF = "The $name class" \
"The $name widget" \
"The $name file" \
is \
provides \
specifies \
contains \
represents \
a \
an \
the
ALWAYS_DETAILED_SEC = NO
INLINE_INHERITED_MEMB = NO
FULL_PATH_NAMES = YES
STRIP_FROM_PATH =
STRIP_FROM_INC_PATH =
SHORT_NAMES = NO
JAVADOC_AUTOBRIEF = NO
QT_AUTOBRIEF = NO
MULTILINE_CPP_IS_BRIEF = NO
INHERIT_DOCS = NO
SEPARATE_MEMBER_PAGES = NO
TAB_SIZE = 4
ALIASES =
TCL_SUBST =
OPTIMIZE_OUTPUT_FOR_C = YES
OPTIMIZE_OUTPUT_JAVA = NO
OPTIMIZE_FOR_FORTRAN = NO
OPTIMIZE_OUTPUT_VHDL = NO
EXTENSION_MAPPING =
MARKDOWN_SUPPORT = YES
TOC_INCLUDE_HEADINGS = 0
AUTOLINK_SUPPORT = YES
BUILTIN_STL_SUPPORT = NO
CPP_CLI_SUPPORT = NO
SIP_SUPPORT = NO
IDL_PROPERTY_SUPPORT = YES
DISTRIBUTE_GROUP_DOC = NO
GROUP_NESTED_COMPOUNDS = NO
SUBGROUPING = YES
INLINE_GROUPED_CLASSES = NO
INLINE_SIMPLE_STRUCTS = NO
TYPEDEF_HIDES_STRUCT = NO
LOOKUP_CACHE_SIZE = 0
EXTRACT_ALL = YES
EXTRACT_PRIVATE = NO
EXTRACT_PACKAGE = NO
EXTRACT_STATIC = NO
EXTRACT_LOCAL_CLASSES = YES
EXTRACT_LOCAL_METHODS = NO
EXTRACT_ANON_NSPACES = NO
HIDE_UNDOC_MEMBERS = NO
HIDE_UNDOC_CLASSES = NO
HIDE_FRIEND_COMPOUNDS = NO
HIDE_IN_BODY_DOCS = NO
INTERNAL_DOCS = NO
CASE_SENSE_NAMES = NO
HIDE_SCOPE_NAMES = NO
HIDE_COMPOUND_REFERENCE= NO
SHOW_INCLUDE_FILES = YES
SHOW_GROUPED_MEMB_INC = NO
FORCE_LOCAL_INCLUDES = NO
INLINE_INFO = YES
SORT_MEMBER_DOCS = YES
SORT_BRIEF_DOCS = NO
SORT_MEMBERS_CTORS_1ST = NO
SORT_GROUP_NAMES = NO
SORT_BY_SCOPE_NAME = NO
STRICT_PROTO_MATCHING = NO
GENERATE_TODOLIST = NO
GENERATE_TESTLIST = NO
GENERATE_BUGLIST = NO
GENERATE_DEPRECATEDLIST= NO
ENABLED_SECTIONS =
MAX_INITIALIZER_LINES = 30
SHOW_USED_FILES = YES
SHOW_FILES = YES
SHOW_NAMESPACES = YES
FILE_VERSION_FILTER =
LAYOUT_FILE =
CITE_BIB_FILES =
QUIET = NO
WARNINGS = YES
WARN_IF_UNDOCUMENTED = YES
WARN_IF_DOC_ERROR = YES
WARN_NO_PARAMDOC = NO
WARN_AS_ERROR = NO
WARN_FORMAT = "$file:$line: $text"
WARN_LOGFILE =
INPUT = includes
INPUT_ENCODING = UTF-8
FILE_PATTERNS = *.c \
*.cc \
*.cxx \
*.cpp \
*.c++ \
*.java \
*.ii \
*.ixx \
*.ipp \
*.i++ \
*.inl \
*.idl \
*.ddl \
*.odl \
*.h \
*.hh \
*.hxx \
*.hpp \
*.h++ \
*.cs \
*.d \
*.php \
*.php4 \
*.php5 \
*.phtml \
*.inc \
*.m \
*.markdown \
*.md \
*.mm \
*.dox \
*.py \
*.pyw \
*.f90 \
*.f95 \
*.f03 \
*.f08 \
*.f \
*.for \
*.tcl \
*.vhd \
*.vhdl \
*.ucf \
*.qsf
RECURSIVE = YES
EXCLUDE =
EXCLUDE_SYMLINKS = NO
EXCLUDE_PATTERNS =
EXCLUDE_SYMBOLS =
EXAMPLE_PATH =
EXAMPLE_PATTERNS = *
EXAMPLE_RECURSIVE = NO
IMAGE_PATH =
INPUT_FILTER =
FILTER_PATTERNS =
FILTER_SOURCE_FILES = NO
FILTER_SOURCE_PATTERNS =
USE_MDFILE_AS_MAINPAGE =
SOURCE_BROWSER = NO
INLINE_SOURCES = NO
STRIP_CODE_COMMENTS = NO
REFERENCED_BY_RELATION = NO
REFERENCES_RELATION = NO
REFERENCES_LINK_SOURCE = YES
SOURCE_TOOLTIPS = YES
USE_HTAGS = NO
VERBATIM_HEADERS = YES
CLANG_ASSISTED_PARSING = NO
CLANG_OPTIONS =
ALPHABETICAL_INDEX = YES
COLS_IN_ALPHA_INDEX = 5
IGNORE_PREFIX =
GENERATE_HTML = NO
HTML_OUTPUT = html
HTML_FILE_EXTENSION = .html
HTML_HEADER =
HTML_FOOTER =
HTML_STYLESHEET =
HTML_EXTRA_STYLESHEET =
HTML_EXTRA_FILES =
HTML_COLORSTYLE_HUE = 220
HTML_COLORSTYLE_SAT = 100
HTML_COLORSTYLE_GAMMA = 80
HTML_TIMESTAMP = NO
HTML_DYNAMIC_SECTIONS = NO
HTML_INDEX_NUM_ENTRIES = 100
GENERATE_DOCSET = NO
DOCSET_FEEDNAME = "Doxygen generated docs"
DOCSET_BUNDLE_ID = org.doxygen.Project
DOCSET_PUBLISHER_ID = org.doxygen.Publisher
DOCSET_PUBLISHER_NAME = Publisher
GENERATE_HTMLHELP = NO
CHM_FILE =
HHC_LOCATION =
GENERATE_CHI = NO
CHM_INDEX_ENCODING =
BINARY_TOC = NO
TOC_EXPAND = NO
GENERATE_QHP = NO
QCH_FILE =
QHP_NAMESPACE = org.doxygen.Project
QHP_VIRTUAL_FOLDER = doc
QHP_CUST_FILTER_NAME =
QHP_CUST_FILTER_ATTRS =
QHP_SECT_FILTER_ATTRS =
QHG_LOCATION =
GENERATE_ECLIPSEHELP = NO
ECLIPSE_DOC_ID = org.doxygen.Project
DISABLE_INDEX = NO
GENERATE_TREEVIEW = NO
ENUM_VALUES_PER_LINE = 4
TREEVIEW_WIDTH = 250
EXT_LINKS_IN_WINDOW = NO
FORMULA_FONTSIZE = 10
FORMULA_TRANSPARENT = YES
USE_MATHJAX = NO
MATHJAX_FORMAT = HTML-CSS
MATHJAX_RELPATH = http://cdn.mathjax.org/mathjax/latest
MATHJAX_EXTENSIONS =
MATHJAX_CODEFILE =
SEARCHENGINE = YES
SERVER_BASED_SEARCH = NO
EXTERNAL_SEARCH = NO
SEARCHENGINE_URL =
SEARCHDATA_FILE = searchdata.xml
EXTERNAL_SEARCH_ID =
EXTRA_SEARCH_MAPPINGS =
GENERATE_LATEX = NO
LATEX_OUTPUT = latex
LATEX_CMD_NAME = latex
MAKEINDEX_CMD_NAME = makeindex
COMPACT_LATEX = NO
PAPER_TYPE = a4
EXTRA_PACKAGES =
LATEX_HEADER =
LATEX_FOOTER =
LATEX_EXTRA_STYLESHEET =
LATEX_EXTRA_FILES =
PDF_HYPERLINKS = YES
USE_PDFLATEX = YES
LATEX_BATCHMODE = NO
LATEX_HIDE_INDICES = NO
LATEX_SOURCE_CODE = NO
LATEX_BIB_STYLE = plain
LATEX_TIMESTAMP = NO
GENERATE_RTF = NO
RTF_OUTPUT = rtf
COMPACT_RTF = NO
RTF_HYPERLINKS = NO
RTF_STYLESHEET_FILE =
RTF_EXTENSIONS_FILE =
RTF_SOURCE_CODE = NO
GENERATE_MAN = NO
MAN_OUTPUT = man
MAN_EXTENSION = .3
MAN_SUBDIR =
MAN_LINKS = NO
GENERATE_XML = YES
XML_OUTPUT = xml
XML_PROGRAMLISTING = NO
GENERATE_DOCBOOK = NO
DOCBOOK_OUTPUT = docbook
DOCBOOK_PROGRAMLISTING = NO
GENERATE_AUTOGEN_DEF = NO
GENERATE_PERLMOD = NO
PERLMOD_LATEX = NO
PERLMOD_PRETTY = YES
PERLMOD_MAKEVAR_PREFIX =
ENABLE_PREPROCESSING = YES
MACRO_EXPANSION = YES
EXPAND_ONLY_PREDEF = NO
SEARCH_INCLUDES = YES
INCLUDE_PATH =
INCLUDE_FILE_PATTERNS =
PREDEFINED =
EXPAND_AS_DEFINED =
SKIP_FUNCTION_MACROS = YES
TAGFILES =
GENERATE_TAGFILE =
ALLEXTERNALS = NO
EXTERNAL_GROUPS = YES
EXTERNAL_PAGES = YES
PERL_PATH = /usr/bin/perl
CLASS_DIAGRAMS = NO
MSCGEN_PATH =
DIA_PATH =
HIDE_UNDOC_RELATIONS = YES
HAVE_DOT = NO
DOT_NUM_THREADS = 0
DOT_FONTNAME = Helvetica
DOT_FONTSIZE = 10
DOT_FONTPATH =
CLASS_GRAPH = YES
COLLABORATION_GRAPH = YES
GROUP_GRAPHS = YES
UML_LOOK = NO
UML_LIMIT_NUM_FIELDS = 10
TEMPLATE_RELATIONS = NO
INCLUDE_GRAPH = YES
INCLUDED_BY_GRAPH = YES
CALL_GRAPH = NO
CALLER_GRAPH = NO
GRAPHICAL_HIERARCHY = YES
DIRECTORY_GRAPH = YES
DOT_IMAGE_FORMAT = png
INTERACTIVE_SVG = NO
DOT_PATH =
DOTFILE_DIRS =
MSCFILE_DIRS =
DIAFILE_DIRS =
PLANTUML_JAR_PATH =
PLANTUML_CFG_FILE =
PLANTUML_INCLUDE_PATH =
DOT_GRAPH_MAX_NODES = 50
MAX_DOT_GRAPH_DEPTH = 0
DOT_TRANSPARENT = NO
DOT_MULTI_TARGETS = NO
GENERATE_LEGEND = YES
DOT_CLEANUP = YES
Kevin Day [Thu, 29 Jun 2023 04:39:59 +0000 (23:39 -0500)]
Update: Relax the requirement in the license to be less verbose.
Do not specifically use my name "Kevin Day".
Instead refer to the "original license owner" or some authorized party.
This will make the license more flexible.
Kevin Day [Fri, 16 Jun 2023 02:39:55 +0000 (21:39 -0500)]
Bugfix: FSS Extended List Read program should print new line after Object.
In the case where Object is printed but not Content a new line must be printed.
This is done to be consistent with the other programs, such as FSS Basic List Read.
The 0.7.x and later versions should probably implement something like -L/--line_end to perform this behavior.
In which case the default behavior would be what the code was doing here prior to this commit.
Kevin Day [Fri, 9 Jun 2023 04:17:26 +0000 (23:17 -0500)]
Bugfix: Use arguments passed to fake when processing build with the custom build arguments.
The custom build arguments are passed when the make mode is being used to call the build mode.
The mode arguments passed to the fake program, these should be propagated into the custom build arguments for the build mode.
Move the print message to after the build modes are processed so that an accurate message is printed.
Kevin Day [Wed, 31 May 2023 04:31:13 +0000 (23:31 -0500)]
Bugfix: Quotes in FSS read functions are not being properly handled and fix backtick handling.
At some point in time the intended behavior changed from using the literal quote character to an enumeration representing the quote character on FSS read calls.
This transition is incomplete and broken.
Finish the transition, passing the enumeration representation rather than the literal character.
Remove an unnecessary initialization on the quote because the private function being called also initializes the variable.
Relocate the f_uint8s_increase() call to be after changing the error status to ensure that the quotes array is properly incremented.
Update the documentation comments to better clarify this behavior in regards to the enumeration.
There are several FSS read functions that are not handling backticks properly.
The backticks should now be fully and properly processed on read.
Kevin Day [Mon, 29 May 2023 23:22:57 +0000 (18:22 -0500)]
Bugfix: Handle f_directory_not status as an invalid directory.
The status f_directory_not is returned with the path exists but is not a directory.
The fake program can fail when doing something like this:
fake clean make -w /arbitrary_non_directory_file +V
The error message returned is not very helpful:
ERROR: (674) when calling function f_file_stat().
This is a known file-related error and so it is now handled appropraitely.
The new error message looks like:
ERROR: Invalid directory while trying to access directory '/arbitrary_non_directory_file'.
Kevin Day [Mon, 29 May 2023 23:16:44 +0000 (18:16 -0500)]
Bugfix: The testfile needs to handle the --build parameter and improve --work parameter handling.
Provide a new operation "build_path" to load the "--build" parameter properly.
The existing checks for the "--work" parameter is better suited checking against "work:value" rather than "work".
There may be an existing bug where the condition for "build" parameter is always returning true when it should not.
This requires further investigation and is not addressed within the scope of this commit.
Kevin Day [Sat, 29 Apr 2023 01:23:05 +0000 (20:23 -0500)]
Bugfix: Incorrect return code in tests causes false failures in CI.
Recent changes of the code change the "failure" variable from being an empty string for no error to being the explicit digit of "0".
The change is incomplete and this caused the false failure by incorrectly returning "1" when instead "0" should be returned.
The Gitlab CI detected this but the Github CI failed to.
Kevin Day [Fri, 28 Apr 2023 01:05:55 +0000 (20:05 -0500)]
Cleanup: Fix mistake in documentation that makes sentence nonsense.
The word "Content" should not be used here and instead use "data".
The word "main" is used here randomly with no logical sense.
Remove this use of the word "main".
Kevin Day [Wed, 26 Apr 2023 23:47:36 +0000 (18:47 -0500)]
Update: Add stand alone build for fss_payload_read and fss_payload_write.
I did fss_payload_read in a hurry and may have missed something.
Making potential problems potentially worse I just copied the fss_payload_read for fss_payload_write and then made minor modifications.
There is some significant potential for unneeded code being added due to the disable define configuration.
Kevin Day [Thu, 6 Apr 2023 01:47:19 +0000 (20:47 -0500)]
Bugfix: The stage files should not begin with "-".
I haven't looked at the stage files in a while because it just works.
I happened to notice that they are beginning with "-".
This is incorrect.
Turns out that at some point in time the separator got pulled outside the process.used condition.
This results in the "-" always being added when it should not be.
The problem is introduced in this completely erroneous commit 8cb1d765b75403e242e307590842628aad7ad91b.
Add the same logic check to the name because it also append a "-".
Also reset the used length at the start of population of the stage file strings.
Kevin Day [Tue, 4 Apr 2023 23:48:45 +0000 (18:48 -0500)]
Update: Improve thread configuration, document modes in build settings files, and update build scripts.
Improve the thread configuration to make it easier to enable or disable thread support.
Add documentation regarding the build modes supported in each of the build settings files.
Update the build scripts to better handle the now additional build modes.
The build scripts now use braces everywhere.
Doing this should make it easier to be compatible with other scripting engines such as ZSH.
Kevin Day [Sun, 2 Apr 2023 22:45:11 +0000 (17:45 -0500)]
Bugfix: Remove extra arguments being added.
The parameter expansion is perhaps the worst designed area of the Featureless Make project.
It went through a lot of iterations and the logic requires jumping around too much.
At some point I changed the code to fix problems with the expansion logic regarding quotes and not quotes.
Two functions were left that still added arguments of their own.
This seems wrong.
This does not appear to cause an obvious bug and so it is also unclear if removing these cause a non-obvious regression.
Keep an eye out for regressions in this.
This program correctly errors when there is no "main" section.
When specifically asking to run a named section rather than the default "main", who cares if there is no "main"?
Based on that logic the lack of a "main" section should not be an error.
Kevin Day [Fri, 31 Mar 2023 04:10:53 +0000 (23:10 -0500)]
Update: Back port utf string compare code from 0.7.x.
This only back ports the functions that are present in 0.6.x.
This does not introduce any new functions and therefore has neither any API nor any ABI changes.
Kevin Day [Thu, 30 Mar 2023 04:48:52 +0000 (23:48 -0500)]
Cleanup: Remove invalid documentation comments from fl_string_dynamic_compare_except_string() and fl_string_dynamic_compare_string().
These two functions, fl_string_dynamic_compare_except_string() and fl_string_dynamic_compare_string(), are not trim functions.
They do not ignore leading and trailing white space.
Kevin Day [Thu, 30 Mar 2023 00:13:48 +0000 (19:13 -0500)]
Bugfix: Add missing function fl_string_dynamic_partial_compare_trim().
The function declaration is missing from the header.
This is technically an API change but because the function actually exists and is defined there is no ABI change.
This is discovered by back porting some unit tests.
Kevin Day [Wed, 29 Mar 2023 23:24:15 +0000 (18:24 -0500)]
Regression: Build test.sh script is not properly running.
Three mistakes are introduced by the commit 362c7b9f6cd57421a18c0148fb6eb9bda165bcd2.
1) The error handling return status checks are against empty string and not "0".
2) The test.sh script is backported from the 0.7.x development branch and accidentally included projects not existing in this 0.6.x branch.
3) Accidental copy and paste mistake where print variable is being used as if it were a function.
Remove the failure=0 assignment.
The default of failure="" is what is needed.
The fl_path project is actually fll_path.
The variable print_line_first is supposed to be test_print_first.
The unit tests might also be back ported at a later time.
Writing unit tests exposed this problem.
The last1 and last2 positions could be the exclusive stop points.
The comparison checks fail to handle this situation and expect the last1 and last2 variables to not be positioned at an exclusive stop point.
This results in an invalid read.
Kevin Day [Mon, 27 Mar 2023 12:33:28 +0000 (07:33 -0500)]
Bugfix: The fl_string parsing functions do not check buffer.used.
The range length is being performed but not the buffer used length.
Add the appropriate return codes to represent end of string (buffer used length is reached).
This is applicable for the dynamic strings but is not applicable for the regular strings.
Kevin Day [Tue, 21 Mar 2023 03:52:41 +0000 (22:52 -0500)]
Bugfix: Out of date repository build scripts.
The repository build scripts are very much out of date.
A recent bugfix, commit 9a021eb4044cf8cb63bcef6f8851566b4bc574c7, attempted to partially address this.
It turns out that there is a lot more that needs to be done.
All of the repository build scripts are now updated.
Make sure the copyright parameter is available.
Make sure the "+Q/++quiet" and "+E/++error" parameters are correct and working.
This is a copy of the changes from commit 736d99ce416da505e859c9ee3890b3adf119260f from the 0.7.0 development branch.
The 0.7.0 parameters "+F/++line_first_no" and "+L/++line_last_no" are removed as they are not available in 0.6.0 stable branch versions.
The relevant code remains, it is just unused.
Improve return status handling.
The goal here is to avoid calling "exit".
The use of "exit" is not safe as under certain conditions it can close terminals that the script is running in.
Kevin Day [Mon, 20 Mar 2023 03:14:02 +0000 (22:14 -0500)]
Bugfix: Out of date install.sh and Featureless Make helper scripts.
It seems that I never looked at these in a while and they are rather out of date.
Fix the parameters.
There are other scripts that need to be looked at as well and are not solved by this commit.
I fixed this in 0.7.0.
I decided to cheat with install.sh and copy over the file with the newer features.
Just disable those features by deleting a few lines to maintain synthetic API compatibility.
This is a script and so API is not really a thing.
Kevin Day [Thu, 16 Mar 2023 23:17:26 +0000 (18:17 -0500)]
Update: Add unit tests for fll_path.
I noticed that the '~' path is not expanded.
I checked to see if this is intentional or not.
It is intentionally not supported yet.
I need another function.
This check encouraged me to write some unit tests for the current behavior.
It seems that I had forgotten just how few unit tests I have.
Now there are at least more.
Kevin Day [Sat, 11 Mar 2023 02:42:53 +0000 (20:42 -0600)]
Update: Add example contrroller script for running under systemd using cgroups.
This provides an example cgroups setup.
I found that on systems with cgroups2, this is harder to figure out.
This turned out to be because of the existing setup used by many systemd systems.
This provides an example that I managed to get to work under some systems in some circumstances.
The biggest problems is that the subtree needs to be passed along and that tends to not be done by default.
The current user, if not root, usually lacks the privileges to do so.
The best case would be to use the cgroups generation when running as root to setup the appropriate user.
Then, use the program startup examples as the normal user.
This should show the cgroup situation.
I would not be surprised if the cgroup setup scripts has to be altered (not just the user and group name).
Kevin Day [Thu, 9 Mar 2023 05:00:33 +0000 (23:00 -0600)]
Feature: Add support for 'helper' mode to compliment the 'program' mode.
This is a bug fix disguised as a new feature.
When controller runs in program mode and is cancelled, all background (asynchronous) processes are cancelled.
My original thoughts were that background processes should stay open in program mode.
This is the bug being fixed.
I believe that there are use cases to operate in "program" mode and to always terminate the background processes in this manner.
Rather than fixing one case and breaking the other, this is a new feature that helps solve both cases.
The "program" mode operates in the same manner unchanged.
The new "helper" mode operates by detaching background (asynchronous) processes on exit.
The foreground process still runs and blocks normally.
A terminate signal might still terminate background processes.
More work is likely needed in this regard.
This stretches the original design to its limits.
The 0.7.x versions and later will need re-design to better handle these cases.
The original design I used was a learn as I go for thread design.
This resulted in rather messy code.
Now that I made it to this point, the controller program (0.6.x and earlier) can be used as a stepping stone for a better design.
Some of the problems are worked-around.
The program starts and exits too fast in controller mode.
The child processes end up getting terminated before a complete process is started and then backgrounded.
The work-around is to add a short sleep.
This is not reliable but for most cases it should be fine.
Additional work-arounds may be needed by the user such as executig their own sleep foreground process.
Kevin Day [Thu, 9 Mar 2023 02:47:47 +0000 (20:47 -0600)]
Cleanup: Remove dead code in controller program.
The process variable is not used.
I decided to not remove the now unused process parameter from the relevant functions.
This prevents breaking API and ABI.
Kevin Day [Thu, 9 Mar 2023 02:27:46 +0000 (20:27 -0600)]
Bugfix: Multiple cancellations may occur, use mutex lock to prevent.
There is an existing check that prevents the cancellation from being called more than once.
What is not being considered is that if the main thread calls cancellation while another cancellation is active then the controller_thread_process_exit() gets called.
The controller_thread_process_exit() function will begin more forcibly shutting things down.
Avoid this by providing a mutex lock to lock the cancellation.
Only once the first cancellation is complete will the second (or more) then return without doing anything.
This clarification paved the way for a solution to the bug where lines with unterminated quotes are not getting anything at all.
By "favoring the typo", the rest of the line is preserved and is able to be printed.
Kevin Day [Mon, 6 Mar 2023 03:45:13 +0000 (21:45 -0600)]
Update: Further clarify quoting in FSS specifications.
I looked at the code and realized I should instead favor the "typo" behavior.
Process until the end of the line rather than break up the Object due to the quotes.
This means if the quote is unterminated then the rest of the line is considerd the Object.
Also document where Content utilizes the same rules.
Example Object and Content pair following FSS-0001:
Object "Content".
The Content would be "Content".
This behavior effectively preserves the period and also retains the quotes.
Another example (FSS-0001):
"Object 1" "Content 1" Content2 and_3
"Object 2": Content.
This second row shows the "typo" is favored concept.
The second row has no Content and instead has the following as the "Object: Object 2": Content.
Note how the quotes are kept when this situation happens.
I also updated the word "newline", replacing it with the words "new" and "line".
I noticed and fixed a mistake in the logic due to this refactor and a similar previous refactor.
Kevin Day [Mon, 6 Mar 2023 01:37:30 +0000 (19:37 -0600)]
Update: Clarify FSS specifications in regards to quote behavior.
I noticed a problem where something that is quoted with an immediate character after it does not get processed.
Example Object and Content pair following FSS-0001:
Object "Content".
In the above example, notice how there is a period after the quotes.
Also notice how the content has no spaces.
The current behavior would treat the "Content". as invalid.
I reviewed the specifications and found them lacking in regards to this dilemma.
I updated the specification to clarify the behavior.
With this change the FSS read functions will need to be updated.
Another example (FSS-0001):
"Object 1" "Content 1" Content2 and_3
"Object 2": Content.
In the above example for an FSS-001, the first row is straight-forward.
The second row is a problem.
Because there is non-white space after the quote, this cannot be treated as a quoted Object.
The behavior would then be to treat this as not quoted.
This means for row two, the object name is: "Object
The first Content is 2":
The second Content is Content.
Kevin Day [Mon, 6 Mar 2023 01:16:21 +0000 (19:16 -0600)]
Feature: Implement wrap support for IKI standard to be compliant with recent changes.
The wrap support for IKI (using open and close brackets '[' (U+005B) ']' (U+005D)) has been recently added to the specification.
This updates the project to be in compliance.
Kevin Day [Sun, 5 Mar 2023 20:51:19 +0000 (14:51 -0600)]
Bugfix: Dead code in return status handling.
The fake_make_operate_process_return() has dead code where it checks for the inverse of the return_code in two spots.
The first of which always returns.
The second case can never be reached.
Redesign the function.
This success/failure behavior should be preserved with this change.
Add a simple example fakefile for testing the return code value.
Kevin Day [Thu, 2 Mar 2023 04:03:23 +0000 (22:03 -0600)]
Feature: The IKI standard now supports bracket wrapping.
I wanted to avoid this and keep IKI as simple as possible.
My recent uses have shown that I must have some sort of word-separator support.
This is the simplest implementation that I can think of at this time.
The brackets do not get escaped, instead the IKI gets escaped.
If there is no closing brracket in the correct spot, then the first bracket is not part of the variable.
The brackets other than the opening at the front and the closing bracket at the end are allowed.
The vocabulary name never includes the open and close bracket.
The following shows the heart of the problem this feature solves:
Consider:
- helloworld:"earth".
What if "world" is the variable name and hello is not supposed to be space separated?
With this featre, now the following is possible:
- hello[world]:"earth"
Note that the following are not valid (that is to say these are not IKI variables):
- hello[world:"earth"
- heloworld]:"earth"
- hello[[world]]:"earth"