paper-plane-developers / tdlib-rs

Rust wrapper around the Telegram Database Library
Apache License 2.0
53 stars 13 forks source link

Document enums #13

Open melix99 opened 2 years ago

melix99 commented 2 years ago

Currently this is the missing piece for having a 100% documented library. To do that we need to parse the "@class" tag in the .tl file first.

x2bool commented 2 years ago

Hi! Perhaps I could help?

What do you think about porting parser to use something like https://github.com/Geal/nom ?

I could rewrite parser to produce full AST including @ Class definitions.

I have experience with parsing .tl files using parser combinators: https://github.com/egramtel/tdsharp/blob/master/TdLib.CodeGen/Parser.fs (.NET / C# / F#)

x2bool commented 2 years ago

Having full AST could also help with removing 1-variant enums https://github.com/melix99/tdlib-rs/issues/14

melix99 commented 2 years ago

Hi! Perhaps I could help?

What do you think about porting parser to use something like https://github.com/Geal/nom ?

I could rewrite parser to produce full AST including @ Class definitions.

I have experience with parsing .tl files using parser combinators: https://github.com/egramtel/tdsharp/blob/master/TdLib.CodeGen/Parser.fs (.NET / C# / F#)

Hi!

I think that would be great! I'd be more than happy to review/merge that.