~ubuntu-branches/ubuntu/wily/julia/wily

« back to all changes in this revision

Viewing changes to base/timsort.jl

  • Committer: Package Import Robot
  • Author(s): Sébastien Villemot
  • Date: 2013-02-11 03:51:26 UTC
  • mfrom: (1.1.4)
  • Revision ID: package-import@ubuntu.com-20130211035126-hap464pbhd97wjbl
Tags: 0.1~20130211.git86fbe98d-1
* New upstream snapshot.
* debian/control:
   + add git to Recommends (for Julia package manager)
   + remove dependencies on libglpk-dev (it moved to its own package)
   + add explicit dependency on libgmp10 (there is no more a wrapper)
* fix-clean-rules.patch: remove patch, applied upstream
* gsvddense_blasint.patch: new patch
* Refresh other patches

Show diffs side-by-side

added added

removed removed

Lines of Context:
406
406
end
407
407
 
408
408
# TimSort main method
409
 
function sort!(::TimSort, o::Ordering, v::AbstractVector, lo::Int, hi::Int)
 
409
function sort!(v::AbstractVector, lo::Int, hi::Int, ::TimSort, o::Ordering)
410
410
    minrun = merge_compute_minrun(hi-lo+1)
411
411
    state = MergeState()
412
412
    i = lo
417
417
            # Make a run of length minrun
418
418
            count = min(minrun, hi-i+1)
419
419
            run_range = i:i+count-1
420
 
            sort!(SMALL_ALGORITHM, o, v, i, i+count-1)
 
420
            sort!(v, i, i+count-1, SMALL_ALGORITHM, o)
421
421
        else
422
422
            if !issorted(run_range)
423
423
                run_range = last(run_range):first(run_range)