Skip to content
New issue

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

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

Already on GitHub? # to your account

command-parser: remove 'unicode-segmentation' dependency #585

Merged
merged 1 commit into from
Nov 2, 2020
Merged

command-parser: remove 'unicode-segmentation' dependency #585

merged 1 commit into from
Nov 2, 2020

Conversation

zeylahellyer
Copy link
Member

Remove the unicode-segmentation dependency from the Command Parser. It was added in #575 to support unicode via unicode_segmentation::GrapheneIndices, but it's not actually required, as the std::str::CharIndices iterator is effectively the same with how it's used. Tests for unicode support are unchanged and continue to pass.

Remove the `unicode-segmentation` dependency from the Command Parser.
It was added in #575 to support unicode via
`unicode_segmentation::GrapheneIndices`, but it's not actually required,
as the `std::str::CharIndices` iterator is effectively the same with how
it's used. Tests for unicode support are unchanged and continue to pass.

Signed-off-by: Vivian Hellyer <vivian@hellyer.dev>
@zeylahellyer zeylahellyer changed the title command-parser: remove 'unicode-segmentation' dep command-parser: remove 'unicode-segmentation' dependency Oct 31, 2020
@zeylahellyer zeylahellyer merged commit 0c740ed into twilight-rs:trunk Nov 2, 2020
@zeylahellyer zeylahellyer deleted the command-parser-remove-unicode-segmentation branch November 2, 2020 14:21
zeylahellyer added a commit that referenced this pull request Nov 2, 2020
Remove the `unicode-segmentation` dependency due to the functionality
used from it also being in the stdlib ([#585] - [@vivian]).

[@vivian]: https://github.com/vivian
[#585]: #585

Signed-off-by: Vivian Hellyer <vivian@hellyer.dev>
zeylahellyer added a commit that referenced this pull request Nov 7, 2020
Remove the `unicode-segmentation` dependency from the Command Parser.
It was added in #575 to support unicode via
`unicode_segmentation::GrapheneIndices`, but it's not actually required,
as the `std::str::CharIndices` iterator is effectively the same with how
it's used. Tests for unicode support are unchanged and continue to pass.

Approved-by: Cassandra McCarthy <cassie@7596ff.com>
Approved-by: Zachary Kohnen <me@dusterthefirst.com>
Merged-by: Vivian Hellyer <vivian@hellyer.dev>
Signed-off-by: Vivian Hellyer <vivian@hellyer.dev>
(cherry picked from commit 0c740ed)
zeylahellyer added a commit that referenced this pull request Nov 7, 2020
This release includes a few bugfixes. While v0.1 will be maintained
until the deprecation of version 6 of the Discord API, we recommend
upgrading to v0.2.

Fixes

Add unicode support to the `Arguments`
iterator ([#575], [#585] - [@AsianIntel], [@vivian]).

Take whitespace after prefixes into account when creating the initial
index for argument iterating, for example when the prefix is a user
mention. This fixes the first argument being the last letter of the
command name ([#584] - [@vivian]).

[@AsianIntel]: https://github.com/AsianIntel
[@vivian]: https://github.com/vivian
[#585]: #585
[#584]: #584
[#575]: #575

Signed-off-by: Vivian Hellyer <vivian@hellyer.dev>
zeylahellyer added a commit to twilight-rs/command-parser that referenced this pull request Apr 15, 2022
Remove the `unicode-segmentation` dependency due to the functionality
used from it also being in the stdlib ([#585] - [@vivian]).

[@vivian]: https://github.com/vivian
[#585]: twilight-rs/twilight#585

Signed-off-by: Vivian Hellyer <vivian@hellyer.dev>
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants