hjanuschka wrote:

@carlosgalvezp thanks for the feedback. I've removed the transformation:

```c++
auto sub2 = s.subspan(n);        // transforms to: auto sub2 = s.last(s.size() 
- n);
```

While I agree that the transformed expression is more complex (due to size() - 
x), I initially included it for two reasons:

Consistency: Using `first()/last()` everywhere possible makes the codebase more 
uniform
The method name `last()` better expresses the intent than `subspan()`, even if 
the calculation is more verbose

Let me know if you think we should revisit this decision.

https://github.com/llvm/llvm-project/pull/118074
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to