Changes between Version 1 and Version 2 of Development/FixingNewbie

Nov 26, 2010, 8:55:36 AM (9 years ago)



  • Development/FixingNewbie

    v1 v2  
    1 Fixing Newbie Bugs
     2= Fixing Newbie Bugs =
     4So, you'd like to contribute to DDC but don't know how? Then this page is for you!
     6I will assume that you have already figured out how to use [wiki:UsingDarcs darcs] (especially the part about setting up a bug fix branch) to get the source code and you've built it and run the test suite. I'll also assume that you have picked a bug on [ newbie list] of the bug tracker that you'd like to work on.
     8The next step is to see if there is already a test case in the darcs tree. Test cases for bugs which have not been fixed yet are put in the `test/Broken-skip` part of the ddc darcs tree. For say bug number `XXX`, there may already be a test case called '''`TXXX-BugName`'''. If you list the '''`TXXX-BugName`''' directory, you will find that it probably contains a single file named '''`Test.ds`''' or '''`Main.ds`'''. With the compiler already built, you can try compiling the test case using the command:
     11bin/ddc test/Broken-skip/TXXX-BugName/Test.ds
     14which should produce a similar error message to the one in the bug report.
     16If there isn't already a test case, you should add a '''`TXXX-BugName`''' directory and a appropriate test file.
     18At this stage its usually a good idea to add a simple shell script in the top level directory, which will build the compiler and run your test case with a simple command. This shell script (which can be named say '''``''') might look a little like this (modify to suit):
     23make || exit 1
     25bin/ddc test/Broken-skip/TXXX-BugName/Test.ds 2>&1
     28Depending on the particular problem you're working on you may want to add '''`-v`''' or one of the '''`-dump-*`''' command line options to the '''`ddc`''' command line.
     30Once you have all this set up, its time to start adding debug print statements to help track down the problem.
     32When you have a fix for the bug, you can use '''`darcs`''' to send a patch to the mailing list.