By default, Eclipse’s editor will not display line numbers, it’s no good for debugging. Here’s a tip to show you how to turn on the “display line numbers” feature in Eclipse.

In Eclipse IDE, select “Windows” > “Preference” > “General” > “Editors” > “Text Editors” , check on the “Show line numbers” option.

line numbers in Eclipse

See result.

line number in eclipse editor