gnucobol-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[open-cobol-list] tips on studying code bases


From: Patrick
Subject: [open-cobol-list] tips on studying code bases
Date: Tue, 29 Apr 2014 09:07:14 -0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20131103 Icedove/17.0.10

Hi Everyone

Thanks again to Brian for yet another very helpful post and I am thankful for the private messages I received too.

I think I am going to make another big push to learn the code base.

I printed all the source code from 1.1. I think this is okay for bulk memorization but I wouldn't do it again,

I ran cobc through cflow last night. It gives results like this:

main() <int main (int argc, char **argv) at cobc.c:3669>:
    memset()
cobc_sig_handler() <void COB_A_NORETURN cobc_sig_handler (int sig) at cobc.c:1478>:
        raise()
        kill()
        getpid()
        exit()
continues on....

It shows that raise, kill, getpid etc are callable from cobc_sig_handler but it can't tell which path of execution it will take.

I was thinking of building a version with a whole bunch of printf statements inside each function that would print the path of execution, "I am raise()" etc.

I thought that I would then look at each function and then use ctags to view the argument definitions.

Does this sound like a logical way to study the code base ? If not could you recommend some other techniques ?

Thanks-Patrick




reply via email to

[Prev in Thread] Current Thread [Next in Thread]