Changeset 4bf3731


Ignore:
Timestamp:
Feb 16, 2016, 6:00:27 PM (8 years ago)
Author:
Paul Brossier <piem@piem.org>
Branches:
feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/pydocstrings, feature/timestretch, fix/ffmpeg5, master, pitchshift, sampler, timestretch, yinfft+
Children:
a7348ca5
Parents:
d04875c
Message:

src/mathutils.c: avoid for loop initial declarations [gcc]

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mathutils.c

    rd04875c r4bf3731  
    254254fvec_shift (fvec_t * s)
    255255{
    256   uint_t half = s->length / 2, start = half;
     256  uint_t half = s->length / 2, start = half, j;
    257257  // if length is odd, middle element is moved to the end
    258258  if (2 * half < s->length) start ++;
    259259#ifndef HAVE_ATLAS
    260   for (uint_t j = 0; j < half; j++) {
     260  for (j = 0; j < half; j++) {
    261261    ELEM_SWAP (s->data[j], s->data[j + start]);
    262262  }
     
    265265#endif
    266266  if (start != half) {
    267     for (uint_t j = 0; j < half; j++) {
     267    for (j = 0; j < half; j++) {
    268268      ELEM_SWAP (s->data[j + start - 1], s->data[j + start]);
    269269    }
     
    274274fvec_ishift (fvec_t * s)
    275275{
    276   uint_t half = s->length / 2, start = half;
     276  uint_t half = s->length / 2, start = half, j;
    277277  // if length is odd, middle element is moved to the beginning
    278278  if (2 * half < s->length) start ++;
    279279#ifndef HAVE_ATLAS
    280   for (uint_t j = 0; j < half; j++) {
     280  for (j = 0; j < half; j++) {
    281281    ELEM_SWAP (s->data[j], s->data[j + start]);
    282282  }
     
    285285#endif
    286286  if (start != half) {
    287     for (uint_t j = 0; j < half; j++) {
     287    for (j = 0; j < half; j++) {
    288288      ELEM_SWAP (s->data[half], s->data[j]);
    289289    }
Note: See TracChangeset for help on using the changeset viewer.