mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-23 02:14:50 +00:00
Trying to fix #7321: add some assertions.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37914 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
00a10facd2
commit
076151f508
@ -2244,6 +2244,7 @@ TextMetrics const & BufferView::textMetrics(Text const * t) const
|
||||
|
||||
TextMetrics & BufferView::textMetrics(Text const * t)
|
||||
{
|
||||
LASSERT(t, /**/);
|
||||
TextMetricsCache::iterator tmc_it = d->text_metrics_.find(t);
|
||||
if (tmc_it == d->text_metrics_.end()) {
|
||||
tmc_it = d->text_metrics_.insert(
|
||||
|
@ -158,6 +158,7 @@ pair<pit_type, ParagraphMetrics const *> TextMetrics::first() const
|
||||
|
||||
pair<pit_type, ParagraphMetrics const *> TextMetrics::last() const
|
||||
{
|
||||
LASSERT(!par_metrics_.empty(), /**/);
|
||||
ParMetricsCache::const_reverse_iterator it = par_metrics_.rbegin();
|
||||
return make_pair(it->first, &it->second);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user