Commit Graph
100 Commits
Author SHA1 Message Date
sashakoshka 0acf44886a generate: Clean up generate_test.go 2025-08-20 12:05:37 -04:00
sashakoshka a4da33536c tape: Utilize skimming in the dynamic decoder 2025-08-18 22:26:53 -04:00
sashakoshka 2180d29615 tape: Implement Skim function 2025-08-12 12:29:50 -04:00
sashakoshka 2209763666 tape: Write test for Skim function 2025-08-12 12:29:28 -04:00
sashakoshka 96c8d7924f tape: Test that integers of a user-defined type can be encoded 2025-08-12 08:21:19 -04:00
sashakoshka fdf0aa89a4 tape: Use reflection when encoding integers 2025-08-12 08:16:34 -04:00
sashakoshka 1bded9852d tape: Dynamic tests put out more information 2025-08-12 08:16:21 -04:00
sashakoshka 8beb9de256 Merge pull request 'encode-signedness' (#13) from encode-signedness into message-size-increase
Reviewed-on: #13
2025-08-11 19:10:56 -06:00
sashakoshka dc72cc2010 generate: Support LSI tags 2025-08-11 20:59:20 -04:00
sashakoshka 0e03f84b8a generate: Update tests with new TNs 2025-08-11 20:59:10 -04:00
sashakoshka 02196edf61 design: Change tag for signed PDL integers 2025-08-11 20:10:03 -04:00
sashakoshka 1058615f6f tape: Do something when receiving an LSI tag 2025-08-11 18:40:56 -04:00
sashakoshka 024edfa922 tape: Actually test decoding lol 2025-08-11 18:39:38 -04:00
sashakoshka fe973af99c tape: Test dynamic encoding and decoding of signed integers 2025-08-10 23:28:43 -04:00
sashakoshka 52f0d6932e tape: Add encoding and decoding of signed integers 2025-08-10 23:28:25 -04:00
sashakoshka 8e14a2c3f1 tape: Add LSI to Tag constants 2025-08-07 21:14:40 -04:00
sashakoshka 4fbb70081a generate: Finish test sub-case for MessageNestedArray 2025-08-06 22:15:22 -04:00
sashakoshka a108e53cb6 Merge pull request 'branched-generated-encoder' (#9) from branched-generated-encoder into message-size-increase
Reviewed-on: #9
2025-08-06 19:11:08 -06:00
sashakoshka 57c30ac669 generate: Generator compiles 2025-08-06 20:19:31 -04:00
sashakoshka a270c22cb9 generate: The generics idea didn't work, use type names instead 2025-08-06 19:39:41 -04:00
sashakoshka a99d4dee66 generate: Fix no return statement, unused variables 2025-08-06 19:07:57 -04:00
sashakoshka c18e251b4a generate: Convert int64 to int to satisfy range
This is a stupid fucking restriction
2025-08-06 18:58:54 -04:00
sashakoshka 170f79c914 generate: Fix bad variable names 2025-08-06 18:48:17 -04:00
sashakoshka 77c6b67d65 generate: Break line after continue statements 2025-08-06 18:41:37 -04:00
sashakoshka 195d0f9725 generate: Pass decoder to branch functions 2025-08-06 18:40:28 -04:00
sashakoshka fa4f591126 generate: make branch functions generic, take in ~ of base type 2025-08-06 18:38:30 -04:00
sashakoshka 12142706e1 generate: Fix syntax and formatting errors 2025-08-06 17:59:26 -04:00
sashakoshka 30e9ead1ab generate: Do the same for <user-type>.Decode 2025-08-06 17:27:04 -04:00
sashakoshka 1118b11bcd generate: Properly check assignment within <message>.Decode 2025-08-06 17:24:51 -04:00
sashakoshka 7343cf5853 generate: Fix array element tag variable 2025-08-06 17:03:58 -04:00
sashakoshka a9f583d2e7 generate: Validate OTA tags properly 2025-08-06 17:02:33 -04:00
sashakoshka c4dd129fc5 generate: Decode tables (but don't validate their length yet) 2025-08-06 17:00:39 -04:00
sashakoshka 2cbf58d558 generate: Decode arrays (but don't validate their length yet) 2025-08-05 06:22:27 -04:00
sashakoshka 7dcfc08678 generate: Add "stub" for actually generating branch functions 2025-08-04 16:01:50 -04:00
sashakoshka 711ac30486 generate: Add branch decode function request queue 2025-08-04 12:26:16 -04:00
sashakoshka b15c3aa76c generate: Implement Generator.generateDecodeBranch 2025-08-04 09:36:52 -04:00
sashakoshka a1bfae443c design: Add paragraph about how we need a skimming function in tape 2025-08-03 22:28:06 -04:00
sashakoshka df3fe1280d generate: Remove abort parameter 2025-08-03 22:27:14 -04:00
sashakoshka 41b3376fa3 generate: Add Generator.generateDecodeBranch stub 2025-08-03 22:19:06 -04:00
sashakoshka fae702edfd generate: Add String functions, TypeHash function for types 2025-08-03 22:07:31 -04:00
sashakoshka c86f9b03f2 generated: Remove unneeded code 2025-08-03 21:00:24 -04:00
sashakoshka dcbfbe9141 design: Import issue from Tebitea (it is down) 2025-08-03 20:59:59 -04:00
sashakoshka 40444ee2f4 generate: Add TODOs about a big problem... 2025-07-25 21:01:48 -04:00
sashakoshka 59cc90166f generate: WIP test of nested arrays 2025-07-25 21:01:23 -04:00
sashakoshka f222fb02b7 generate: Gracefully discard unexpected data while decoding 2025-07-22 20:20:47 -04:00
sashakoshka 6ecc33a46b generate: Fix TestGenerateRun when testing numbers 2025-07-21 16:51:33 -04:00
sashakoshka 5d84636b55 tape: Add functions to encode and decode float16 2025-07-21 15:58:32 -04:00
sashakoshka f009a970cd generate: Fix another syntax error when reading floats 2025-07-21 15:00:57 -04:00
sashakoshka 8b63166ba1 generate: Test encoding floating point values 2025-07-21 14:57:34 -04:00
sashakoshka 3ef7de118b generate: Fix syntax error when reading floats 2025-07-21 14:56:58 -04:00
sashakoshka 51ed6aed9f generate: Fix TestGenerateRun so it snakes around User tables 2025-07-21 14:32:33 -04:00
sashakoshka 6017ac1fa3 generate: Encode SI properly 2025-07-21 14:11:40 -04:00
sashakoshka b8047585fb generate: Test integer encoding 2025-07-21 14:10:34 -04:00
sashakoshka ad3973dd9e generate: Test array encoding 2025-07-20 23:21:59 -04:00
sashakoshka 0f626b2e93 generate: Fix array encoding not writing length or item tag properly 2025-07-20 23:19:21 -04:00
sashakoshka 272e47224d generate: Make output of testGenerateRun easier to compare 2025-07-20 23:18:36 -04:00
sashakoshka 2c57423838 generate: Fix encoding of table length field 2025-07-20 10:26:29 -04:00
sashakoshka e2b9e809a8 generate: Fix TestGenerateRun 2025-07-20 10:25:53 -04:00
sashakoshka 7e8b272ef0 generate: And now for an actual use of testGenerateRun 2025-07-19 06:24:30 -04:00
sashakoshka a257902705 generate: Flush the buffer before trying to compare it 2025-07-17 14:47:23 -04:00
sashakoshka 4955f66ad6 generate: testEncode uses snakes now 2025-07-17 14:06:05 -04:00
sashakoshka f646207ab1 generate: Use newTemporarVar in more places 2025-07-17 11:28:53 -04:00
sashakoshka b50a199842 generate: Fix the testEncode function 2025-07-17 11:19:57 -04:00
sashakoshka b826cbf83e generate: The test now compiles 2025-07-17 10:26:31 -04:00
sashakoshka b73f9fa7ce generate: Implement decoding (untested) 2025-07-16 22:57:12 -04:00
sashakoshka d3d7b07a74 generate: Emit stub for message decoding function 2025-07-12 20:01:42 -04:00
sashakoshka daa6a44179 generate: Generate Method method 2025-07-12 19:37:58 -04:00
sashakoshka af7669c783 generate: Fix more nonsense surrounding named types 2025-07-11 20:08:43 -04:00
sashakoshka 2305814e10 tape: Add StringTag 2025-07-10 21:56:38 -04:00
sashakoshka 5a3296a842 generate: Parse primitive types into actual types rather than named types 2025-07-10 21:53:21 -04:00
sashakoshka 3bf365a7a9 generate: Fix more semantic errors in the generated code 2025-07-08 21:50:29 -04:00
sashakoshka e48be0bc15 generate: Fix more semantic issues with generated code 2025-07-08 21:32:34 -04:00
sashakoshka a210f6112c generate: Fix more semantic issues in generated code 2025-07-08 20:35:11 -04:00
sashakoshka 9ff317d443 generate: Change comment so it gets detected by the regex for generated files 2025-07-08 15:44:24 -04:00
sashakoshka cdba8ee601 generate: Fix a bunch of semantic issues with the generated code 2025-07-08 14:52:05 -04:00
sashakoshka e75d7534c1 generate: Fix syntax errors in generated code 2025-07-08 12:01:21 -04:00
sashakoshka 8a0ae9b03f generate: Update tests to account for new changes 2025-07-08 11:39:37 -04:00
sashakoshka 9bc90b0e17 generate: What the fuck is a teibibyte 2025-07-08 11:39:18 -04:00
sashakoshka c70c23d137 generate: Fix testGenerateRun so that it actually works 2025-07-08 11:38:00 -04:00
sashakoshka a9d5bb83a2 generate: Add framework for testing output of generated code 2025-07-07 16:00:25 -04:00
sashakoshka f1df5fa84d generate: Add stub return to generateDecodeValue so it compiles 2025-07-07 15:13:18 -04:00
sashakoshka 76a8f9444a tape: Ignore type names when encoding primitives using reflection 2025-07-05 22:10:55 -04:00
sashakoshka 0f20c4cdab tape: Fix TestEncodeDecodeAny using int instead of uint32 2025-07-05 19:14:36 -04:00
sashakoshka 1b82f2cd83 tape: Use tu.Describe() in tests 2025-07-05 18:47:57 -04:00
sashakoshka 6ba70ed046 internal/testutil: Create function to closely examine any data 2025-07-05 18:47:08 -04:00
sashakoshka c118a4d7ef tape: Change name of test to TestEncodeDecodeAnyTable 2025-07-04 14:30:23 -04:00
sashakoshka 877698d402 tape: Remove print statements 2025-07-04 14:18:56 -04:00
sashakoshka 5989a82bee tape: Fix negative slice length 2025-07-04 14:18:30 -04:00
sashakoshka c8a2f03ca1 tape: Fix peekSlice not using the correct tag 2025-07-04 12:22:49 -04:00
sashakoshka 07fc77c83e tape: WIP 2025-07-02 06:25:24 -04:00
sashakoshka 2138d47f07 tape: Flush writer after encoding for testing 2025-06-29 13:22:46 -04:00
sashakoshka e9633770ad internal/testutil: Formatting fix 2025-06-29 13:22:21 -04:00
sashakoshka dcf923b1f3 internal/testutil: Snake.String and HexBytes return "EMPTY" when input is empty 2025-06-29 11:06:58 -04:00
sashakoshka 8f8cd91b5d tape: Fix usage of Encoder/Decoder in dynamic tests 2025-06-29 10:30:32 -04:00
sashakoshka 81ac10508b tape: Change how slice skeletons are generated, support nested OTAs 2025-06-29 10:27:40 -04:00
sashakoshka 4930215166 tape: Make decoder inherit bufio.Writer 2025-06-28 11:24:32 -04:00
sashakoshka e1f58a194a tape: In progress testing of dynamic encoding/decoding 2025-06-28 06:24:44 -04:00
sashakoshka 37eccc91c0 tape: Progress on dynamically decoding OTAs 2025-06-28 06:23:51 -04:00
sashakoshka 08fe3d45dd tape: Encoder inherits bufio.Writer, need to do same for decoder 2025-06-28 06:23:18 -04:00
sashakoshka 3eb826735b tape: Send reflect values where possible instead of pointers 2025-06-27 19:05:17 -04:00