On Tue, 09 Mar 2010 14:07:10 -0500, Steven Schveighoffer wrote: > On Tue, 09 Mar 2010 12:54:16 -0500, Lutger > <[email protected]> wrote: > >> Michal Minich wrote: >> >>> On Tue, 09 Mar 2010 10:23:07 -0500, Steven Schveighoffer wrote: >>> >>>> I want to focus more on the fact that you are declaring the data >>>> after the slice as being no longer used. >>> >>> kind of assumeUnique ... >>> >>> assumeNoArrayReference ? >> >> I like that. Or assumeNoMemoryAliasing. It should be clear that it is a >> potentially very unsafe function. > > I like this train of thought, assume is a good term for what you are > doing, and it is consistent with assumeUnique. > > The only thing I don't like about it is you aren't really assuming > anything about the slice, you are assuming the data after the slice is > no longer used. It looks weird that you are assuming something about > the slice. > > assumeEndOfData ? > assumeAllocation ? > > I don't 100% like those either. > > -Steve
assumeNoArrayReference does not express that there can be references to the original array before slice start. probably better expressing, if rather long name could be assumeNoOriginArrayReferencesPastSliceEnd assumeNoOriginArrayReferencesAfter or probably somthing like this: unsafeDeletePastSlice
