Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

About JSON interface #21

Open
ghost opened this issue Jun 3, 2018 · 5 comments
Open

About JSON interface #21

ghost opened this issue Jun 3, 2018 · 5 comments

Comments

@ghost
Copy link

ghost commented Jun 3, 2018

I like it, but it has one big drawback, code, which previously was written like:

config.getIntArray("admins")

where config is a section of a TOML file
now needs to be written like:

import sequtils
config["admins"].getElems().mapIt(it.getNum())
@PMunch
Copy link
Member

PMunch commented Jun 3, 2018

Yeah, I was still working on it. And the PR was just to show what I was doing. Not sure why @data-man merged it but we should probably undo that until it's done properly.

@data-man
Copy link
Contributor

data-man commented Jun 4, 2018

Within the PR we would not receive feedback. :)

@PMunch
Copy link
Member

PMunch commented Sep 20, 2018

How does JSON handle this? Wouldn't it have the same issue?

@ghost
Copy link
Author

ghost commented Sep 21, 2018

@PMunch yeah, with JSON I would do it the same way, but with older API of this lib it was easier :) But yeah, it's fine for me

@PMunch
Copy link
Member

PMunch commented Sep 23, 2018

I'm considering splitting this into multiple files. One with the object definition and parsing/converting stuff, and others with interface logic. This way we can actually have different interfaces.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants