lmi
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lmi] std::vector::at() in group-quote code


From: Greg Chicares
Subject: [lmi] std::vector::at() in group-quote code
Date: Fri, 13 May 2016 13:27:22 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Icedove/38.6.0

Vadim--I notice that you've used std::vector::at() throughout the
group-quote code in preference to operator[](). Is that because

(1) it provides extra safety at an incremental cost that is negligible
in the context of generating PDF files, or

(2) it actually costs nothing (when it doesn't throw) with a modern
compiler such as we're using, even on msw with sjlj semantics?

I'm assuming that the reason is (1). But if, as I can hardly imagine,
(2) also holds, then perhaps I should use at() globally.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]