• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Others / shredder / #48
71%

Build:
DEFAULT BRANCH: master
Ran 21 Aug 2020 02:54AM UTC
Jobs 1
Files 21
Run time 1s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
#48

push

circle-ci

web-flow
WIP: Unsized types (#45)

* Add ?Sized bounds to all (?) appropriate locations

I have added ?Sized to pretty much all T that is garbage collected and
that needs it. However, there are a few structs defined in a rental!
macro that are causing the build to break due to trasmutation rules.
Enforcing a Sized bound causes the GcRef type to require a Sized T,
which doesn't seem right.

* Removed ?Sized bounds from smart-pointer implementations of RwLock, Mutex, and RefCell

The implementations of RwLock, Mutex, and RefCell all have special
guards for their borrow() (and related) functions that wrap around their
normal standard library guards. These guards are implemented using the
rental crate, which has a special macro that does some magic behind the
scenes involving transmutation of types - which breaks some type rules
when they're possibly unsized.

This now compiles, and the Gc<RwLock>, Gc<Mutex>, and Gc<RefCell> types
do not have access to the ergonomic GcRef type or their special borrow()
family of methods.

* WIP: add nightly-only features CoerceUnsized and Unsize

These allow a `Gc<T>` to be coerced to a `Gc<dyn R>` when `T` is some
trait `R`. This requires `std::ops::CoerceUnsized` and
`std::marker::Unsize`, which are nightly features.

TODO: Add compile-time bounds for these functions/imports

* Add support for converting Box<T> to a Gc<T> where T: ?Size

Unsized types are able to be created by allocating a Box<T>, converting
it to a Box<dyn MyTrait>, and then moving that pointer to the allocator.

* Add `ToScan` trait which forces the value to be converted to a `&dyn
  Scan`, which is required for using any of the new `from_box` methods.
  Also add `impl_to_scan_safe` macro for convenience
* Add Gc::from_box function for converting the boxed value to a GC'd
  value
* Add GcAllocation::from_box function which does the actual convertion
  from the boxed value to a pointer
* Add Colletor::track_boxed_value w... (continued)

833 of 1229 relevant lines covered (67.78%)

2.1 hits per line

Jobs
ID Job ID Ran Files Coverage
1 #48.1 21 Aug 2020 02:54AM UTC 0
67.78
Source Files on build #48
Detailed source file information is not available for this build.
  • Back to Repo
  • 419a34b2 on github
  • Prev Build on master
  • Next Build on master
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc