Add utils for working with endianness, more documentation, refactor CMake

Decided to update the docs, as well as adding few new features and small
refactoring.
This commit is contained in:
2025-02-28 21:44:01 +03:00
parent 93033ebc99
commit a2d0913c79
19 changed files with 4138 additions and 43 deletions

View File

@@ -385,6 +385,23 @@ BH_UNIT_TEST(InvalidLong)
}
BH_UNIT_TEST(Aesthetics)
{
BH_ArgsOption options[] = {
{'a', "abc", 0, NULL},
{'b', "bcd", BH_ARGS_VALUE, "B option"},
{'i', "input", BH_ARGS_VALUE | BH_ARGS_OPTIONAL, "Input option"},
{1000, "long-option", 0, "Long options\nWith newline"},
{'p', NULL, 0, "P option"},
{0, NULL, 0, NULL},
};
BH_ArgsHelp(options, 0);
return 0;
}
int main(int argc, char **argv)
{
(void)argc;
@@ -398,6 +415,7 @@ int main(int argc, char **argv)
BH_UNIT_ADD(Complex);
BH_UNIT_ADD(InvalidShort);
BH_UNIT_ADD(InvalidLong);
BH_UNIT_ADD(Aesthetics);
return BH_UnitRun();
}