e
in o
.Basically it does:
o.write "{prefix}{display(e)}\n"
Usually, you should redefine display
to change the display of an element.
# Write the full line for the element `e` in `o`.
#
# Basically it does:
#
# ~~~nitish
# o.write "{prefix}{display(e)}\n"
# ~~~
#
# Usually, you should redefine `display` to change the display of an element.
protected fun write_line(o: Writer, e: E, prefix: String)
do
o.write "{prefix}{display(e)}\n"
end
lib/ordered_tree/ordered_tree.nit:172,2--184,4
redef fun write_line(o, n, p)
do
if display_line then
var ls = n.location.line_start
var file = n.location.file
var line = self.line
if ls > line and file != null then
if line == 0 then line = ls - 1
while line < ls do
line += 1
o.write "{line}\t{file.get_line(line)}\n".light_gray
end
self.line = ls
end
end
super
end
src/parser/parser_nodes.nit:217,2--234,4