Given a slice of token_item, reassembles them into the original literal expression.
(tokens []token_item)
| 252 | // Given a slice of token_item, reassembles them into the original literal |
| 253 | // expression. |
| 254 | func token_items_to_string(tokens []token_item) string { |
| 255 | var buf bytes.Buffer |
| 256 | for _, t := range tokens { |
| 257 | buf.WriteString(t.literal()) |
| 258 | } |
| 259 | return buf.String() |
| 260 | } |
| 261 | |
| 262 | // this function is called when the cursor is at the '.' and you need to get the |
| 263 | // declaration before that dot |
no test coverage detected