Cysharp / MemoryPack

Zero encoding extreme performance binary serializer for C# and Unity.
MIT License
3.01k stars 182 forks source link

[Question] Is there any code style for this project for contributing to the repo #271

Open lxymahatma opened 3 months ago

lxymahatma commented 3 months ago

Last time when I trying to dig into why the code generator doesn't work for my project, I cloned the repo and open it with Rider. The project seems a little bit messy so i actually take some time to locate the method i want to find. Also, Rider gives me tons of suggestions on refactoring the code, like use => instead of writing return, use ; instead of { } with empty classes, remove unneeded this., etc. But cz i'm not familiar with the actual things happening behind things I'm a bit afraid of changing those stuff

There are also some small issues with naming i guess(? like the SuppressDefaultInitialization Attributes, i think theoretically the it should end with 'Attribute'

So like, is it possible for me to do a pr to correct those styles 👀

neuecc commented 3 months ago

SuppressDefaultInitialization is a new addition and I did not review it enough. This should add Attribtue, thanks.

Rider's suggesion is too meddlesome. I would not try to apply it 100%.

lxymahatma commented 3 months ago

SuppressDefaultInitialization is a new addition and I did not review it enough. This should add Attribtue, thanks.

Rider's suggesion is too meddlesome. I would not try to apply it 100%.

oh i see, so maybe i could make a pr for some style changes(? imo some style changes make the code more easier to read