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

Change config types in docs to appropriate types in code #2592

Closed
fanatid opened this issue May 13, 2020 · 3 comments · Fixed by #2659
Closed

Change config types in docs to appropriate types in code #2592

fanatid opened this issue May 13, 2020 · 3 comments · Fixed by #2659
Labels
type: task Generic non-code related tasks

Comments

@fanatid
Copy link
Contributor

fanatid commented May 13, 2020

Based on #2590 (comment) & #2590 (comment)

Gonna take it after #2493 (comment)

@binarylogic binarylogic added domain: website type: task Generic non-code related tasks labels May 14, 2020
@fanatid
Copy link
Contributor Author

fanatid commented May 18, 2020

Before done this, some questions after first review:

  • f32 => float
  • f64 => double
  • i32 => int
  • i64 => long
  • u32 => uint
  • u64 => ulong
  • usize => ?

Or types in docs should be just changed to: f32 / f64 / i32 / i64 / u32 / u64 / usize?

@lukesteensen
Copy link
Member

TOML only has integer and float, so it probably makes sense to stick with that terminology. We can add the concept of signed/unsigned since that's meaningful for us.

  • f32 => float
  • f64 => float
  • i32 => int
  • i64 => int
  • u32 => uint
  • u64 => uint
  • usize => uint

It may even be nice in the future to decouple the TOML types from the Rust types a bit. For example, it's convenient to use -1 as a shortcut for usize::MAX. But for the time being, I think the above is fine.

@fanatid
Copy link
Contributor Author

fanatid commented May 21, 2020

OK, I changed int to uint where type is not i32/i64.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: task Generic non-code related tasks
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants