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

Add a decode() function that looks for a BOM. #23

Merged
merged 1 commit into from
Dec 12, 2013

Conversation

SimonSapin
Copy link
Collaborator

Only works with a single string entirely in memory.

This is part of #19, although complete #19 would also support incremental decoding.

Only works with a single string entirely in memory.

This is part of lifthrasiir#19,
although complete lifthrasiir#19 would also support incremental decoding.
@SimonSapin
Copy link
Collaborator Author

This also backports a .starts_with(&[T]) method from later versions of libstd. This backport is removed in #24, which targets rust-0.9-pre rather than master.

@SimonSapin
Copy link
Collaborator Author

If both this and #26 are accepted, please also change this to use EncodingObj instead of &'static Encoding, both for the parameter and the return value. (Sending separate pull requests makes this awkward…)

@lifthrasiir lifthrasiir merged commit 0c1d3f6 into lifthrasiir:master Dec 12, 2013
@SimonSapin SimonSapin deleted the decode-BOM branch December 13, 2013 00:14
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

Successfully merging this pull request may close these issues.

2 participants