Hi,

I have some issues using ccache and Qt build tools, because the content of the generated files with repc is different from time to time.
When I use the following commands, it could be possible, that the generated content inside method registerMetatypes has a different sort order:
Qt Code:
  1. repc -o replica Abcd.rep rep_Abcd_replica1.h
  2. repc -o replica Abcd.rep rep_Abcd_replica2.h
To copy to clipboard, switch view to plain text mode 

rep_Abcd_replica1.h
Qt Code:
  1. static void registerMetatypes()
  2. {
  3. static bool initialized = false;
  4. if (initialized)
  5. return;
  6. initialized = true;
  7. qRegisterMetaType<State1>();
  8. qRegisterMetaType<State2>();
  9.  
  10. }
To copy to clipboard, switch view to plain text mode 

rep_Abcd_replica2.h
Qt Code:
  1. static void registerMetatypes()
  2. {
  3. static bool initialized = false;
  4. if (initialized)
  5. return;
  6. initialized = true;
  7. qRegisterMetaType<State2>();
  8. qRegisterMetaType<State1>();
  9.  
  10. }
To copy to clipboard, switch view to plain text mode 

As you can see, the sort order for qRegisterMetaType has been changed.

The rep File itself remains unchanged.
Qt Code:
  1. class Abcd
  2. {
  3. ENUM State1 { Off=0, On }
  4. PROP(State1 state=State1::Off SOURCEONLYSETTER)
  5.  
  6. ENUM State2 { Off=0, On }
  7. PROP(State2 state=State2::Off SOURCEONLYSETTER)
  8. }
To copy to clipboard, switch view to plain text mode 

Is it not possible, to generate always the same content?