Ignore:
Timestamp:
06/25/20 00:34:29 (4 years ago)
Author:
Maciej Komosinski
Message:

Genetic format ID becomes a string (no longer limited to a single character)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpp/frams/_demos/genooper_test.cpp

    r534 r955  
    88void printGen(Geno &g)
    99{
    10         printf("Genotype: %s\nFormat: %c\nValid: %s\nComment: %s\n",
    11                 g.getGenes().c_str(), g.getFormat(), g.isValid() ? "yes" : "no", g.getComment().len() == 0 ? "(empty)" : g.getComment().c_str());
     10        printf("Genotype: %s\nFormat: %s\nValid: %s\nComment: %s\n",
     11                g.getGenes().c_str(), g.getFormat().c_str(), g.isValid() ? "yes" : "no", g.getComment().len() == 0 ? "(empty)" : g.getComment().c_str());
    1212}
    1313
     
    3030        Geno gsrc(src, -1, "First");
    3131        printGenAndTitle(gsrc, "source genotype (gsrc)");
    32         char format = gsrc.getFormat();
     32        SString format = gsrc.getFormat();
    3333
    3434        Geno gmut = genetics.genman.mutate(gsrc);
     
    4141        printGenAndTitle(gsimplest, "simplest");
    4242
    43         Geno ginvalid("IT'S REALLY WRONG", format);
     43        Geno ginvalid("IT'S REALLY WRONG", format.c_str());
    4444        printGenAndTitle(ginvalid, "invalid");
    4545
Note: See TracChangeset for help on using the changeset viewer.