struct TemplateTypeResult

Defined at line 39 of file ../../src/developer/debug/zxdb/expr/template_type_extractor.h

C++ template types are mostly opaque to the debugger and we can't do many transformations on

them. We don't attempt to fully parse or understand types and require the user to input things

according to how the symbols represent the names.

But one thing we do need to do is find where the end of a type is for certain expressions such as

template parameters, and to perform limited canonicalization of those types.

For example, to do a cast:

static_cast

<Foo

::Bar

<Something

*>>(a)

We need only understand what the type is enough to look it up in the symbols, and would prefer to

allow the user flexibility in exactly matching the whitespace generated by the compiler.

There are two parts:

1. Finding the end of a template type. This tracks things like brackets, parens, and quotes so

we know where the end token of the type is. In the above example, this means knowing the

second '>' is the terminator.

2. Canonicalization. The only canonicalization we do is whitespace canonicalization. This comes

up most often in spaces after commas in type lists, and whether the ">>" at the end of the

above example needs a space separating them or not.

Public Members

bool success
size_t unmatched_error_token
size_t end_token
basic_string canonical_name