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

bug in OtpErlangList iterator #1

Open
apperly opened this issue Dec 9, 2009 · 3 comments
Open

bug in OtpErlangList iterator #1

apperly opened this issue Dec 9, 2009 · 3 comments

Comments

@apperly
Copy link

apperly commented Dec 9, 2009

hi there,

been playing with your code as an alternative to otp.net. its great - thanks!

one small thing - there appears to be a bug in your implentation of GetEnumerator() on OtpErlangList. Doing a foreach over a list skips the first item! Maybe because the start parameter you pass into your inner Itr class shadows the exisiting field with the same name?

fwiw, might just be easier let the compiler write the iterator for you with yield return?

@takayuki
Copy link
Owner

Thank you, apperly! I just pushed a quick fix.

@apperly
Copy link
Author

apperly commented Dec 10, 2009

that's great. thanks.

another request - would you consider implementing IEnumerable on OtpErlangTuple as well?

@apperly
Copy link
Author

apperly commented Dec 10, 2009

i meant IEnumerable<OtpErlangObject> (editor doesn't like angle brackets!)

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