jak-project/test/decompiler
Tyler Wilding abf61a94fb
docs: add support for :override-doc in method declarations as well as documenting state handlers (#2139)
Adding support for better child-type method docstrings. This is a
problem unique to methods.

Usually, a child-type will have the same signature and a common name
will apply, but the implementation is different. This means, you
probably want a different docstring to describe what is happening.

Currently this is possible to do via `:replace`. The problem with
replace is two fold:
- a replaced method ends up in the generated `deftype`...because you
usually change the signature!
- we don't put docstrings in the `deftype` in normal GOAL, this is just
something we do for the `all-types` file (they go in the `defmethod`
instead)
- more importantly, this means anytime you now want to change the
parent's name/args/return type -- you have to apply that change
everywhere.

So this is a better design you can now just declare the method like so:
```clj
(:override-doc "my new docstring" <method_id>)
```

And internally a pseudo-replaced method will be added, but it will
inherit everything from the parent (except the docstring of course)

Unrelated - I also made all the keyword args for declaring methods not
depend on ordering

This also adds support for documenting virtual and non-virtual state
handlers. For example:

```clj
  (:states
    (part-tester-idle (:event "test") symbol))
```

or

```clj
(idle () _type_ :state (:event "test") 20)
```

I will probably add the ability to give some sort of over-view docstring
at a later date.

Co-authored-by: water <awaterford111445@gmail.com>
2023-01-21 20:45:45 -05:00
..
reference docs: add support for :override-doc in method declarations as well as documenting state handlers (#2139) 2023-01-21 20:45:45 -05:00
vu_reference [jak 2] merc (#2039) 2022-11-30 22:36:09 -05:00
FormRegressionTest.cpp Fix GCC build (#1992) 2022-10-29 15:25:21 -04:00
FormRegressionTest.h Fix GCC build (#1992) 2022-10-29 15:25:21 -04:00
test_AtomicOpBuilder.cpp lint: add include sorting config to clang-format (#1517) 2022-06-22 23:37:46 -04:00
test_DataParser.cpp [decomp] make defpart and defpartgroup work in jak 2 (#1947) 2022-10-09 12:53:44 -04:00
test_DisasmVifDecompile.cpp tests: Cleanup decompiler test fixtures and try to improve the test output / add a readable report (#1724) 2022-08-05 12:12:33 -04:00
test_FormBeforeExpressions.cpp tests: Cleanup decompiler test fixtures and try to improve the test output / add a readable report (#1724) 2022-08-05 12:12:33 -04:00
test_FormExpressionBuild.cpp d/jak2: finish cty-guard-turret-button | race-h | height-map-h and a lot of rigid-body (#1957) 2022-10-11 23:20:36 -04:00
test_FormExpressionBuild2.cpp d/jak2: finish task-arrow | carry-h | projectile | gun-[red|yellow|blue]-shot (#1864) 2022-10-29 15:22:57 -04:00
test_FormExpressionBuild3.cpp tests: Cleanup decompiler test fixtures and try to improve the test output / add a readable report (#1724) 2022-08-05 12:12:33 -04:00
test_FormExpressionBuildLong.cpp [decompiler] make (not (logtest? work (#1934) 2022-09-30 18:26:52 -04:00
test_gkernel_jak1_decomp.cpp tests: Cleanup decompiler test fixtures and try to improve the test output / add a readable report (#1724) 2022-08-05 12:12:33 -04:00
test_InstructionDecode.cpp [decompiler] support for jak 2 (#1781) 2022-08-22 18:53:51 -04:00
test_InstructionParser.cpp lint: add include sorting config to clang-format (#1517) 2022-06-22 23:37:46 -04:00
test_math_decomp.cpp tests: Cleanup decompiler test fixtures and try to improve the test output / add a readable report (#1724) 2022-08-05 12:12:33 -04:00
test_VuDisasm.cpp [jak 2] merc (#2039) 2022-11-30 22:36:09 -05:00