getting warnings about unused public variables or functions

View: New views
8 Messages — Rating Filter:   Alert me  

getting warnings about unused public variables or functions

by Martin Bähr :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

hi,

while refactoring some code today, i noticed how helpful the warnings
about unused private variables or functions are.

but it would have been even more helpful to optionally also have
warnings (notices) about any unused items to be ableto find them easier
and then decide if they are really needed.

greetings, martin.

getting warnings about unused public variables or functions

by Mirar @ Pike developers forum :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Well, perhaps you should look at adapting a refactoring tool to work
with Pike.

Re: getting warnings about unused public variables or functions

by Martin Bähr :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

all the tools i can see out there are very language specific,
might as well write one from scratch.

refactoring requires a parser. the best parser for pike is pike itself,
hence, in order to write a refactoring tool for pike, pike would need
this functionality (then the tool could run the code through pike, get a
list and report that list to the user or do something more useful (like
automaticly remove the items in question)

greetings, martin.

Re: getting warnings about unused public variables or functions

by Mirar @ Pike developers forum :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I was sort of expecting that message to continue on to the topic of
Parser.Pike; what it lacks, for qualifying as a parser, or something,
but found none. Would that help you get further, if it is indeed news?

Re: getting warnings about unused public variables or functions

by Mirar @ Pike developers forum :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

It would be really exciting to be able to use the actual parser used by
the Pike compiler. I really hope that the next version of Hilfe has no
parser in it...

Re: getting warnings about unused public variables or functions

by Martin Bähr :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

absolutely!
that would be really exciting.

what does it take to get there?

greetings, martin.

Re: getting warnings about unused public variables or functions

by Bill Welliver :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

+1

What would be really nifty would be a mode whereby you could access  
the node tree for a program and query it. That would enable all kinds  
of very powerful program manipulation.

Bill

On Jul 20, 2008, at 5:20 AM, Martin Bähr wrote:

> absolutely!
> that would be really exciting.
>
> what does it take to get there?
>
> greetings, martin.


Re: getting warnings about unused public variables or functions

by Stephen R. van den Berg :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

H. William Welliver III wrote:
>What would be really nifty would be a mode whereby you could access  
>the node tree for a program and query it. That would enable all kinds  
>of very powerful program manipulation.

Lisp, eat your heart out! ;-)
--
Sincerely,
           Stephen R. van den Berg.
"I hate spinach, and I'm glad that I hate it, because if I wouldn't hate it,
 I would have to eat it, and I hate it!"