General Comment:
Testfile:
class Teste
{
public String name;
public String aa;
public String bb;
public String cc;
public String name;
public String get_name() { return name; }
private Void set_name(String s) { name = s; }
}
Valgrind summary:
==34640== HEAP SUMMARY:
==34640== in use at exit: 9,056 bytes in 70 blocks
==34640== total heap usage: 240 allocs, 170 frees, 30,514 bytes allocated
==34640==
==34640== 144 (96 direct, 48 indirect) bytes in 1 blocks are definitely
lost in loss record 11 of 21
==34640== at 0x10007CD8B: operator new(unsigned long)
(vg_replace_malloc.c:261)
==34640== by 0x100015DA1: clever::yylex(clever::ast::ASTNode**,
clever::location*, clever::Driver&, clever::ScannerState&) (in ./clever)
==34640== by 0x1000047F5: clever::Parser::parse() (in ./clever)
==34640== by 0x1000188EA: clever::Driver::parseFile(std::string const&)
(in ./clever)
==34640== by 0x10002A5F0: main (in ./clever)
==34640==
==34640== 4,728 (112 direct, 4,616 indirect) bytes in 1 blocks are
definitely lost in loss record 21 of 21
==34640== at 0x10007CD8B: operator new(unsigned long)
(vg_replace_malloc.c:261)
==34640== by 0x100004D6D: clever::Parser::parse() (in ./clever)
==34640== by 0x1000188EA: clever::Driver::parseFile(std::string const&)
(in ./clever)
==34640== by 0x10002A5F0: main (in ./clever)
==34640==
==34640== LEAK SUMMARY:
==34640== definitely lost: 208 bytes in 2 blocks
==34640== indirectly lost: 4,664 bytes in 66 blocks
==34640== possibly lost: 0 bytes in 0 blocks
==34640== still reachable: 4,184 bytes in 2 blocks
==34640== suppressed: 0 bytes in 0 blocks
==34640== Reachable blocks (those to which a pointer was found) are not
shown.
==34640== To see them, rerun with: --leak-check=full --show-reachable=yes
==34640==
==34640== For counts of detected and suppressed errors, rerun with: -v
==34640== ERROR SUMMARY: 2 errors from 2 contexts (suppressed: 0 from 0)
For more information:
http://code.google.com/p/clever/source/detail?r=437