Skip to content

Conversation

samebchase
Copy link
Contributor

Implemented to_str() for HashMap and HashSet
Added tests.
Minor formatting and stylistic cleanups.

@luqmana luqmana mentioned this pull request May 10, 2013
@pcwalton
Copy link
Contributor

Why is the test commented out?

@samebchase
Copy link
Contributor Author

@pcwalton

All tests pass with the existing tests. For some reason, I was getting test failures (on the tests I wrote myself).

I compiled a simple test Rust program and testing hash_table.to_str() works fine.

The order in which the elements are accessed is prone to change. I think that is why the test may have failed. I'll try getting the empty HashMap test to pass and recommit.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change all the ~"foo" to "foo", expect for the initial one.

1. Extra space removed.
2. Using acc.push_str() instead of str::push_str
3. Update test to reflect representation change.
Also added some whitespace to enhance readabilty.
bors added a commit that referenced this pull request May 12, 2013
Implemented to_str() for HashMap and HashSet
Added tests.
Minor formatting and stylistic cleanups.
@bors bors closed this May 12, 2013
@bors bors merged commit 0acb6ab into rust-lang:incoming May 12, 2013
@samebchase samebchase deleted the experimental branch May 13, 2013 06:39
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.

4 participants