Ticket #44605: patch-ChangeLog-modules_switch.cc-modules_switch.h-gui_gui_stopwatch.cc-fix-clang-compile-errors.diff

File patch-ChangeLog-modules_switch.cc-modules_switch.h-gui_gui_stopwatch.cc-fix-clang-compile-errors.diff, 3.4 KB (added by Ionic (Mihai Moldovan), 9 years ago)

fix clang compile errors.

  • ChangeLog

    old new  
     12013-10-15 Borut Razem <borutr@users.sourceforge.net>
     2        * modules/stimuli.cc, modules/stimuli.h, modules/switch.h,
     3          modules/switch.cc, gui/gui_stopwatch.cc: applied patch
     4          #32 Make gpsim compile with clang,
     5          thanks to Ralf Horstmann
     6
    172011-04-27 Roy Rankin <rrankin@ihug.com.au>
    28        * regression/p16f690/Makefile : use local lkr file
    39        * regression/Makefile.am : tarball fix
  • gui/gui_stopwatch.cc

    old new  
    179179    }
    180180    if(!sww->IsUpdate() && (text=gtk_entry_get_text (GTK_ENTRY(widget)))!=0)
    181181    {
    182         long long v = strtoll(text,0,10);
     182        long long v = ::strtoll(text,0,10);
    183183        if(v!=(sww->cyclecounter-sww->offset)%sww->rollover)
    184184        {
    185185            v=(v+sww->offset)%sww->rollover;
     
    201201    }
    202202    if(!sww->IsUpdate() && (text=gtk_entry_get_text (GTK_ENTRY(widget)))!=0)
    203203    {
    204         long long v = strtoll(text,0,10);
     204        long long v = ::strtoll(text,0,10);
    205205
    206206        if(v!=sww->offset)
    207207        {
     
    221221    }
    222222    if(!sww->IsUpdate() && (text=gtk_entry_get_text (GTK_ENTRY(widget)))!=0)
    223223    {
    224         long long v = strtoll(text,0,10);
     224        long long v = ::strtoll(text,0,10);
    225225
    226226        if(v!=sww->rollover)
    227227        {
     
    403403
    404404  get_config();
    405405  if(config_get_string(name(),"rollover",&string))
    406     rollover = strtoll(string,0,10);
     406    rollover = ::strtoll(string,0,10);
    407407  config_get_variable(name(),"count_dir",&count_dir);
    408408   
    409409  if(enabled)
  • modules/stimuli.cc

    old new  
    216216  //----------------------------------------------------------------------
    217217  //----------------------------------------------------------------------
    218218
    219   PulseGen::PulseGen(const char *_name=0)
     219  PulseGen::PulseGen(const char *_name)
    220220    : StimulusBase(_name, "\
    221221Pulse Generator\n\
    222222 Attributes:\n\
  • modules/stimuli.h

    old new  
    4848    gint64 time;
    4949    Value  *v;
    5050
    51     inline bool operator < (ValueStimulusData &rValue) {
     51    inline bool operator < (const ValueStimulusData &rValue) const {
    5252      return time < rValue.time;
    5353    }
    54     inline bool operator == (ValueStimulusData rValue) {
     54    inline bool operator == (const ValueStimulusData rValue) const {
    5555      return time == rValue.time;
    5656    }
    5757  };
     
    7272  {
    7373  public:
    7474    static Module *construct(const char *new_name);
    75     PulseGen(const char *_name);
     75    PulseGen(const char *_name=0);
    7676    ~PulseGen();
    7777
    7878    virtual void callback();
  • modules/switch.cc

    old new  
    582582
    583583  //========================================================================
    584584
    585   Switch::Switch(const char *_new_name=0)
     585  Switch::Switch(const char *_new_name)
    586586    : SwitchBase(_new_name, "\
    587587Two port switch\n\
    588588 Attributes:\n\
  • modules/switch.h

    old new  
    8888  class Switch : public SwitchBase
    8989  {
    9090  public:
    91     Switch(const char *_name);
     91    Switch(const char *_name=0);
    9292    ~Switch();
    9393
    9494    virtual void setState(bool);