Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Sep 6, 2008, 6:30:40 PM (16 years ago)
Author:
landauf
Message:

bugfix + cleanup

Location:
code/branches/core3/src/core
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core3/src/core/ConfigValueContainer.cc

    r1716 r1720  
    153153        {
    154154            return this->callFunctionWithIndex(&ConfigValueContainer::tset, input);
    155         }
    156         else
    157         {
    158 //            MultiType temp = this->value_;
    159 //            if (temp.assimilate(input))
    160 //            {
    161 //                this->value_ = temp;
    162                 this->value_ = input;
    163                 if (this->identifier_)
    164                     this->identifier_->updateConfigValues();
    165 
    166                 return true;
    167 //            }
    168         }
    169         return false;
     155            return false;
     156        }
     157        else
     158        {
     159            this->value_ = input;
     160
     161            if (this->identifier_)
     162                this->identifier_->updateConfigValues();
     163
     164            return true;
     165        }
    170166    }
    171167
     
    194190            }
    195191
    196 //            MultiType temp = this->value_;
    197 //            if (temp.assimilate(input))
    198 //            {
    199 //                this->valueVector_[index] = temp;
    200                 this->valueVector_[index] = input;
    201 
    202                 if (this->identifier_)
    203                     this->identifier_->updateConfigValues();
    204 
    205                 return true;
    206 //            }
     192            this->valueVector_[index] = input;
     193
     194            if (this->identifier_)
     195                this->identifier_->updateConfigValues();
     196
     197            return true;
    207198        }
    208199        else
    209200        {
    210201            COUT(1) << "Error: Config-value '" << this->varname_ << "' in " << this->sectionname_ << " is not a vector." << std::endl;
    211         }
    212         return false;
     202            return false;
     203        }
    213204    }
    214205
  • code/branches/core3/src/core/Functor.h

    r1716 r1720  
    280280
    281281
    282 /*
    283 #define FUNCTOR_EVALUATE_PARAM(numparams) FUNCTOR_EVALUATE_PARAM##numparams
    284 #define FUNCTOR_EVALUATE_PARAM0
    285 #define FUNCTOR_EVALUATE_PARAM1 \
    286     if (index == 0) { P1 temp = param; param = temp; }
    287 #define FUNCTOR_EVALUATE_PARAM2 \
    288     if (index == 0) { P1 temp = param; param = temp; } \
    289     else if (index == 1) { P2 temp = param; param = temp; }
    290 #define FUNCTOR_EVALUATE_PARAM3 \
    291     if (index == 0) { P1 temp = param; param = temp; } \
    292     else if (index == 1) { P2 temp = param; param = temp; } \
    293     else if (index == 2) { P3 temp = param; param = temp; }
    294 #define FUNCTOR_EVALUATE_PARAM4 \
    295     if (index == 0) { P1 temp = param; param = temp; } \
    296     else if (index == 1) { P2 temp = param; param = temp; } \
    297     else if (index == 2) { P3 temp = param; param = temp; } \
    298     else if (index == 3) { P4 temp = param; param = temp; }
    299 #define FUNCTOR_EVALUATE_PARAM5 \
    300     if (index == 0) { P1 temp = param; param = temp; } \
    301     else if (index == 1) { P2 temp = param; param = temp; } \
    302     else if (index == 2) { P3 temp = param; param = temp; } \
    303     else if (index == 3) { P4 temp = param; param = temp; } \
    304     else if (index == 4) { P5 temp = param; param = temp; }
    305 */
     282
    306283#define FUNCTOR_EVALUATE_PARAM(numparams) FUNCTOR_EVALUATE_PARAM##numparams
    307284#define FUNCTOR_EVALUATE_PARAM0
     
    330307
    331308
     309
    332310#define CREATE_STATIC_FUNCTOR(returnvalue, numparams) \
    333311    FUNCTOR_TEMPLATE(0, returnvalue, numparams) \
Note: See TracChangeset for help on using the changeset viewer.