Code center > Darwinbots3
Programming task (DNA editor)
Panda:
Riiiiiiighhhhht. I'm back now and I'm still willing to do this. :)
Numsgil:
Okay! I've basically got the DNA in a good state. First step is you'll need to get the code and make sure it actually compiles on your machine. I've updated the Darwinbots3 page on the wiki.
Assuming you can open and build Sunweaver.sln (the solution file for the DNA), you just need to call Sunweaver.Parsing.Parser.ParseDNA to turn text in to DNA. Importantly there's an overload that returns a list of CompilationMessages. These messages have things like line and column numbers for syntax errors in DNA, and a short message describing what's wrong. So first step is to get Scintilla to send text through that ParseDNA method, and provide red squiggly lines for syntax errors. The parsing should be fast enough that you can run it on a background thread whenever there's a pause in typing (similar to what Visual Studio does).
After that, syntax highlighting would be good. You can get a list of known sysvars and commands in Sunweaver.DNASystem.Sysvars and Sunweaver.DNASystem.Commands. Anything else is stored in the Sunweaver.Chromosome you get back after you parse DNA.
After that, stuff to let you "go to definition" for codules would be neat. But I'm not sure how that'll work. At some point you might need to dig in to the code for parsing DNA and get your hands dirty. Hopefully it makes sense. And of course, the unit tests are good for figuring out how something is supposed to work.
Once you have a simple prototype working I'll help you get the code in to the repository in a way that makes sense.
Panda:
I will get back to you on Monday about whether I've got everything working on this machine but I don't think it will be a problem. I know I have licensed version of VS2013 Ultimate on this machine so that definitely won't be a problem.
What extent of Unit Tests will you expect from me?
Just to condense it:
* syntax errors
* syntax hilighting
* "go to definition"
I'm pretty sure I have SVN rights but I cannot remember what my credentials are? I know I can still download the source anyway so that's not a problem.
Anything else that I'm missing?
Botsareus:
This is a related repo. question:
When me and Panda where working on chloroplasts in DB2 together, every time another person made change in the repo. you had to create a fresh local copy. Very inefficient imo. I am guessing there is improvement on that in the DB3 repo. as you say " I'll help you get the code in to the repository in a way that makes sense." How does that work?
Panda:
I can't remember having to make a fresh local copy whenever there was a change in the repo. :s Maybe we did but that was a while ago.
I guess what he means by that is we just find a logical place for it to go in the repo later rather than trying to sort it out now.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version