[llvm-dev] ArgList flag values

David Greene via llvm-dev llvm-dev at lists.llvm.org
Mon Aug 13 08:10:04 PDT 2018


<paul.robinson at sony.com> writes:

>> ArgList::hasFlag is a convenient way to check true/false with a default
>> value.  An ArgList::hasFlag that returned Optional<bool> would allow
>> checking the unspecified case.  Returning some kind Tribool class object
>> would allow the same.
>
> I'd be inclined to use getLastArg for this, which returns nullptr if you
> don't have any of the specified options.

Thanks for the pointer!

                           -David


More information about the llvm-dev mailing list