[fpc-devel] ptop inconsistent with defaults config file specified
    Graeme Geldenhuys 
    graemeg.lists at gmail.com
       
    Mon Mar 19 09:14:47 CET 2007
    
    
  
Hi,
I saved the default settings of 'ptop' to a file using the following
  ptop -g ptop.cfg
Now using that config file with the -c parameter and not specifying it
at all should give me the same results, but it does!  Anybody that can
shed some light on this.  I'm in the process of creating a Borland
Object Pascal coding standards config file and came across this
stumbling block.
Here is how I used the ptop application with the defaults and defaults
generated config file:
1)    ptop test3.pp test3_out.pp
2)    ptop -c ptop.cfg test3.pp test3_out.pp
Here is the content of the test3.pp file
-------------------[ test3.pp ]--------------------------
procedure TestTryProc;
begin
try ShowMessage ('Start'); try ShowMessage ('trying');
try ShowMessage ('still trying');
finally ShowMessage ('going...'); end;
except ShowMessage ('except'); end;
finally ShowMessage ('Finally!'); end;
end;
-------------------[ end ]--------------------------
Here is the output of 1) above.  Notice the difference in indentation
of the try/finally and try/except blocks in 1) and 2).
----------[ no config file specified ]------------------
Procedure TestTryProc;
Begin
  Try
    ShowMessage ('Start');
    Try
      ShowMessage ('trying');
      Try
        ShowMessage ('still trying');
      Finally
        ShowMessage ('going...');
      End;
    Except
      ShowMessage ('except');
    End;
  Finally
    ShowMessage ('Finally!');
  End;
End;
------------------------[ end ]---------------
.. and here is the output of 2) above - both should have been the same.
----------[ default generated config file specified ]------------------
Procedure TestTryProc;
Begin
  Try
    ShowMessage ('Start');
    Try
      ShowMessage ('trying');
      Try
        ShowMessage ('still trying');
  Finally
    ShowMessage ('going...');
  End;
  Except
    ShowMessage ('except');
  End;
  Finally
    ShowMessage ('Finally!');
  End;
End;
------------------------[ end ]---------------
-- 
Graeme Geldenhuys
There's no place like S34° 03.168'  E018° 49.342'
    
    
More information about the fpc-devel
mailing list