What is meta? ×
Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 150 Stack Exchange communities.

Suppose I have the following code:

List<Integer> list = new ArrayList<Integer>();

Is there a way to make ArrayList above point to its documentation?

share|improve this question

3 Answers 3

up vote 8 down vote accepted

int main() {
    return 0;

It requires the use of explicit HTML, though.

share|improve this answer
I guess the downside of using explicit HTML is that you don't get syntax highlighting. – Darthenius Dec 6 '11 at 19:16
Oof, that's ugly though. I knew about the HTML approach but didn't realize that characters on the following line would hide the link underlining. – Pops Dec 6 '11 at 21:06
@PopularDemand: That's probably browser-dependent. It looks fine in Chrome. – hammar Dec 7 '11 at 12:50
Oh, okay. FF5 Win7 here, for what it's worth. – Pops Dec 7 '11 at 15:16
List<Integer> list = new [ArrayList]<Integer>();

Doesn't seem like you can (see edits to this answer)

But you can do:

List<Integer> list = new ArrayList<Integer>();

Which is a link (but the whole line)

share|improve this answer
Your whole-line example renders identically to just plain old code for me. Seems like the potential for confusion is very high. – sarnold Dec 6 '11 at 21:40

Using the technique shown in hammar's answer, here's the original example using explicit HTML:

List<Integer> list = new ArrayList<Integer>();

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .