| 404 | } |
| 405 | |
| 406 | void SpaceAnalyzer::SpaceLeft(LuaSyntaxNode n, const LuaSyntaxTree &t, std::size_t space, SpacePriority priority) { |
| 407 | auto token = n.GetPrevToken(t); |
| 408 | auto it = _rightSpaces.find(token.GetIndex()); |
| 409 | if (it != _rightSpaces.end()) { |
| 410 | if (it->second.Priority > priority) { |
| 411 | return; |
| 412 | } |
| 413 | } |
| 414 | |
| 415 | _rightSpaces[token.GetIndex()] = SpaceData(space, priority); |
| 416 | } |
| 417 | |
| 418 | void SpaceAnalyzer::SpaceRight(LuaSyntaxNode n, const LuaSyntaxTree &t, std::size_t space, SpacePriority priority) { |
| 419 | auto token = n.GetLastToken(t); |
no test coverage detected