Reusable Code Search

How do you find reusable code if you don't know it? In a large code base with many library functions, as you know, is the code you intend to write already written?

+1
source share
7 answers

I read the documentation. If there is no documentation, it cannot be reused.

Reuse is not something that comes for free. For example, take a look at the C ++ library class Stansdard std :: string - do you think you can use it in your code if many people do not pay much attention to the document on how it works? You need to do the same to make your own code reusable.

+8

- , . , , , , , "ReverseString" ( "String.Reverse" OO-). - ​​, "RevString" "FastStrRev" "gnirts" - , . .

, ( , ). -, , , , , . StackOverflow.

+2

- .

, , SlickEdit. ctag vim , . ( , ..) .

, .

+1

. Visual Studio, Eclipse . .

+1

, , , - . , .

, .

0

, , . , , , , .

If the code is intended to be reused and not separately released, then proceed with caution.

0
source

Ask someone else on the team - they can tell you from the head. Otherwise, find the code or file names for something similar to what you are doing.
Then copy and paste the code :-)

I find that duplicating even simple functions is bad, so any reuse you can do is fine.

0
source

All Articles