terminal/src
Dustin L. Howett 54a7fce3e0
Move to GSL 3.1.0 (#6908)
GSL 3, the next major version of GSL after the one we're using, replaced
their local implementation of `span` with one that more closely mimics
C++20's span. Unfortunately, that is a breaking change for all of GSL's
consumers.

This commit updates our use of span to comply with the new changes in
GSL 3.

Chief among those breaking changes is:

* `span::at` no longer exists; I replaced many instances of `span::at`
  with `gsl::at(x)`
* `span::size_type` has finally given up on `ptrdiff_t` and become
  `size_t` like all other containers

While I was here, I also made the following mechanical replacements:

* In some of our "early standardized" code, we used std::optional's
  `has_value` and `value` back-to-back. Each `value` incurs an
  additional presence test.
  * Change: `x.value().member` -> `x->member` (`optional::operator->`
    skips the presence test)
  * Change: `x.value()` -> `*x` (as above)
* GSL 3 uses `size_t` for `size_type`.
  * Change: `gsl::narrow<size_t>(x.size())` -> `x.size()`
  * Change: `gsl::narrow<ptrdiff_t>(nonSpan.size())` -> `nonSpan.size()`
    during span construction

I also replaced two instances of `x[x.size() - 1]` with `x.back()` and
one instance of a manual array walk (for comparison) with a direct
comparison.

NOTE: Span comparison and `make_span` are not part of the C++20 span
library.

Fixes #6251
2020-07-14 18:30:59 +00:00
..
buffer Add support for the "concealed" graphic rendition attribute (#6907) 2020-07-14 14:11:03 +00:00
cascadia Move to GSL 3.1.0 (#6908) 2020-07-14 18:30:59 +00:00
dep Move all wildcards into targets or expand them (#6406) 2020-06-08 14:01:47 -07:00
host Move to GSL 3.1.0 (#6908) 2020-07-14 18:30:59 +00:00
inc Move to GSL 3.1.0 (#6908) 2020-07-14 18:30:59 +00:00
interactivity Refactor the renderer color calculations (#6853) 2020-07-10 22:26:34 +00:00
internal Merged PR 4271163: [Git2Git] Remove use of private theme APIs 2020-02-03 23:13:31 +00:00
propsheet Replace old C headers (xxx.h) with modern ones (cxxx) (#5080) 2020-07-01 11:00:24 -07:00
propslib Find icon from shortcut target if shortcut doesn't specify it (#6277) 2020-06-01 17:19:05 +00:00
renderer Move to GSL 3.1.0 (#6908) 2020-07-14 18:30:59 +00:00
server Reintroduce a color compatibility hack, but only for PowerShells (#6810) 2020-07-10 15:25:39 -07:00
terminal Add support for the "concealed" graphic rendition attribute (#6907) 2020-07-14 14:11:03 +00:00
testlist inbox: Merge accumulated build fixes from RS_ONECORE_DEP_ACIOSS (#1002) 2019-05-24 12:28:30 -07:00
til Fix the x86 build and re-enable x86 CI (#6467) 2020-06-11 17:04:42 +00:00
tools fix scheme name resolution, and schema load on WSL (#5327) 2020-07-01 20:15:09 +00:00
tsf Replace old C headers (xxx.h) with modern ones (cxxx) (#5080) 2020-07-01 11:00:24 -07:00
types Move to GSL 3.1.0 (#6908) 2020-07-14 18:30:59 +00:00
winconpty Add support for win32-input-mode to conhost, ConPTY, Terminal (#6309) 2020-06-08 22:31:28 +00:00
common.build.post.props Add experimental retro terminal effects (#3468) 2019-12-12 13:44:01 +00:00
common.build.pre.props Enable Control Flow Guard in the common build props (#5453) 2020-04-22 11:30:13 -07:00
common.build.tests.props Move ConPTY to use til::bitmap (#5024) 2020-03-23 15:57:54 +00:00
ConsolePerf.regions.xml Tab to spaces (#578) 2019-05-13 18:06:36 -07:00
ConsolePerf.wprp Fix the WPR profile (#4007) 2019-12-17 17:14:15 -08:00
cppwinrt.build.post.props deps: upgrade CppWinRT to 2.0.200316.3, gsl to v2.1.0 (#4536) 2020-03-23 17:15:24 +00:00
cppwinrt.build.pre.props Fix the build in VS 2019 16.7 (#6838) 2020-07-09 04:10:50 +00:00
dirs build: move oss required to build conhost out of dep/ (#5451) 2020-04-21 14:43:09 -07:00
project.inc Merged PR 4915574: console: switch to /Zc:wchar_t (native wchar_t) 2020-07-13 23:04:32 +00:00
project.unittest.inc Merged PR 4915530: Reflect OS Build fixes on top of 58f5d7c7 2020-07-13 23:00:53 +00:00
StaticAnalysis.ruleset Combined changes to make the build work again (see inside) (#2945) 2019-09-30 10:39:55 -07:00
unit.tests.x64.runsettings Initial release of the Windows Terminal source code 2019-05-02 15:29:04 -07:00
unit.tests.x86.runsettings Initial release of the Windows Terminal source code 2019-05-02 15:29:04 -07:00
wap-common.build.post.props Initial release of the Windows Terminal source code 2019-05-02 15:29:04 -07:00
wap-common.build.pre.props Initial release of the Windows Terminal source code 2019-05-02 15:29:04 -07:00