Skip to content
This repository was archived by the owner on Oct 12, 2022. It is now read-only.

Conversation

@JinShil
Copy link
Contributor

@JinShil JinShil commented Aug 27, 2019

Followup to #2647, #2644, #2643, and #2634

This is a continuation of work to clean up object.d. It's just a cut-and-paste with the exception of getPostblit and doPostblit which were made public (though still private to druntime because it is in core.internal) so it could be used by some associative array code that still resides in object.d

@dlang-bot
Copy link
Contributor

Thanks for your pull request and interest in making D better, @JinShil! We are looking forward to reviewing it, and you should be hearing from a maintainer soon.
Please verify that your PR follows this checklist:

  • My PR is fully covered with tests (you can see the coverage diff by visiting the details link of the codecov check)
  • My PR is as minimal as possible (smaller, focused PRs are easier to review than big ones)
  • I have provided a detailed rationale explaining my changes
  • New or modified functions have Ddoc comments (with Params: and Returns:)

Please see CONTRIBUTING.md for more information.


If you have addressed all reviews or aren't sure how to proceed, don't hesitate to ping us with a simple comment.

Bugzilla references

Your PR doesn't reference any Bugzilla issue.

If your PR contains non-trivial changes, please reference a Bugzilla issue or create a manual changelog.

Testing this PR locally

If you don't have a local development environment setup, you can use Digger to test this PR:

dub fetch digger
dub run digger -- build "master + druntime#2761"

@JinShil
Copy link
Contributor Author

JinShil commented Aug 27, 2019

Weird! All packages in buildkite pass, but the unittests in core.internal.array.duplication.d fail.

@thewilsonator
Copy link
Contributor

src/core/internal/array/duplication.d(243): Error: cannot implicitly convert expression `dup(s)` of type `char[]` to `immutable(string)`
--
  | src/core/internal/array/duplication.d(268): Error: cannot implicitly convert expression `dup(m)` of type `void[]` to `immutable(void)[]`
  | src/core/internal/array/duplication.d(272): Error: cannot implicitly convert expression `dup(s)` of type `shared(void)[]` to `immutable(void)[]`
  | src/core/internal/array/duplication.d(243): Error: cannot implicitly convert expression `dup(s)` of type `char[]` to `immutable(string)`
  | src/core/internal/array/duplication.d(268): Error: cannot implicitly convert expression `dup(m)` of type `void[]` to `immutable(void)[]`
  | src/core/internal/array/duplication.d(272): Error: cannot implicitly convert expression `dup(s)` of type `shared(void)[]` to `immutable(void)[]`

@JinShil
Copy link
Contributor Author

JinShil commented Aug 27, 2019

@thewilsonator. Thanks. I see the error message, but any idea why it is occurring? All I did was move the code.

@thewilsonator
Copy link
Contributor

Dunno, but it seems that all of those should be idups.

@JinShil
Copy link
Contributor Author

JinShil commented Aug 27, 2019

it seems that all of those should be idups.

Line 38 explicitly says const overload to support implicit conversion to immutable (unique result, see DIP29), so there must be something else at play. Something's not right though. Just moving code shouldn't trigger this.

@thewilsonator
Copy link
Contributor

IDK, try asking on slack or the NG,

@JinShil
Copy link
Contributor Author

JinShil commented Sep 3, 2019

I don't think these symbols should be in core.internal. I think there are a couple of better ways to do this.

@JinShil JinShil closed this Sep 3, 2019
@JinShil JinShil deleted the move_dup branch September 3, 2019 06:04
@PetarKirov
Copy link
Member

@JinShil as mentioned in #2784, I think they're perfect candidates for core.array.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants