PLC-lang / PLC-lang/rusty

Serializer Improvments

Open
#982 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

CFC low-priority refactor
Dominant language
Rust
Stars
362
Forks
75
Avg merge
6d 9h
Merged PRs (30d)
35

Description

PR https://github.com/PLC-lang/rusty/pull/967 will change the Serializer API drastically to make it more concise, however there are still some issues and features we'd like to add in the near future as discussed offline with @ghaith

  1. Make the serialize() method compatible with SC; the current implementation for example lacks support for the position element (among other things) which in turn yields a null-pointer exception in SC when copy-pasting the generated XML output
  2. Refactor the serialize() method to return a model rather than an XML string, and consequentially add a serialize() method to the model to generate XML. Effectively we can then both test the model and parser separately.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing PR 967 and the current serialize() API described in this issue. Trace how the serializer, model, and parser handle generated XML, including the missing position element and the copy-paste failure in SC. Done means the model and parser can be tested separately, the model can generate XML, and the output is compatible with SC.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust, xml
Domain
compilers
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.