Open simPod opened 3 months ago
Q | A |
---|---|
Bug fix? | no |
New feature? | yes |
Doc updated | no |
BC breaks? | no |
Deprecations? | no |
Tests pass? | yes |
Fixed tickets | #... |
License | MIT |
@idbentley can you help with code review, please? :)
@simPod I think we need also E2E test of deserialisation - I think it should already work for simple types :)
My main feedback is that this PR seems rather incomplete.
The changes to the @Type
lexer/parser may support the simplest array<A|B>
test case, but I can think of some edge cases that would cause that type parsing to fail. The @Type
typer lexer/parser currently has no union support, so this adds support for array<A|B>
but there's no support for just A|B
.
The only tests seem to be of the docblockparser (which is good), but no tests of any serialization/deserialization, no tests of the Type annotation lexer changes.
What is the expected behaviour of A|B[]
in a docblock type?
Overall, I think this is a great feature, but needs some extra help.