Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Third Party Harfbuzz
提交
d0df996c
T
Third Party Harfbuzz
项目概览
OpenHarmony
/
Third Party Harfbuzz
接近 2 年 前同步成功
通知
1
Star
18
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
Third Party Harfbuzz
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
d0df996c
编写于
5月 15, 2019
作者:
B
Behdad Esfahbod
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Use implicit lambda return type
上级
57f65ae9
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
22 addition
and
23 deletion
+22
-23
src/hb-array.hh
src/hb-array.hh
+2
-2
src/hb-ot-layout-gsub-table.hh
src/hb-ot-layout-gsub-table.hh
+4
-4
src/hb-ot-layout-gsubgpos.hh
src/hb-ot-layout-gsubgpos.hh
+9
-9
src/hb-ot-stat-table.hh
src/hb-ot-stat-table.hh
+1
-1
src/hb-ot-var-fvar-table.hh
src/hb-ot-var-fvar-table.hh
+2
-2
src/test-iter.cc
src/test-iter.cc
+4
-4
src/test-meta.cc
src/test-meta.cc
+0
-1
未找到文件。
src/hb-array.hh
浏览文件 @
d0df996c
...
...
@@ -319,7 +319,7 @@ bool hb_array_t<T>::operator == (const hb_array_t<T> &o) const
{
return
length
==
o
.
length
&&
+
hb_zip
(
*
this
,
o
)
|
hb_map
([]
(
hb_pair_t
<
T
&
,
T
&>
&&
_
)
->
bool
{
return
_
.
first
==
_
.
second
;
})
|
hb_map
([]
(
hb_pair_t
<
T
&
,
T
&>
&&
_
)
{
return
_
.
first
==
_
.
second
;
})
|
hb_all
;
}
...
...
@@ -329,7 +329,7 @@ uint32_t hb_array_t<T>::hash () const
return
+
hb_iter
(
*
this
)
|
hb_map
(
hb_hash
)
|
hb_reduce
([]
(
uint32_t
a
,
uint32_t
b
)
->
uint32_t
{
return
a
*
31
+
b
;
},
0
)
|
hb_reduce
([]
(
uint32_t
a
,
uint32_t
b
)
{
return
a
*
31
+
b
;
},
0
)
;
}
...
...
src/hb-ot-layout-gsub-table.hh
浏览文件 @
d0df996c
...
...
@@ -48,7 +48,7 @@ struct SingleSubstFormat1
{
+
hb_iter
(
this
+
coverage
)
|
hb_filter
(
*
c
->
glyphs
)
|
hb_map
([
&
]
(
hb_codepoint_t
g
)
->
hb_codepoint_t
{
return
(
g
+
deltaGlyphID
)
&
0xFFFFu
;
})
|
hb_map
([
&
]
(
hb_codepoint_t
g
)
{
return
(
g
+
deltaGlyphID
)
&
0xFFFFu
;
})
|
hb_sink
(
c
->
output
)
;
}
...
...
@@ -58,7 +58,7 @@ struct SingleSubstFormat1
if
(
unlikely
(
!
(
this
+
coverage
).
add_coverage
(
c
->
input
)))
return
;
+
hb_iter
(
this
+
coverage
)
|
hb_map
([
&
]
(
hb_codepoint_t
g
)
->
hb_codepoint_t
{
return
(
g
+
deltaGlyphID
)
&
0xFFFFu
;
})
|
hb_map
([
&
]
(
hb_codepoint_t
g
)
{
return
(
g
+
deltaGlyphID
)
&
0xFFFFu
;
})
|
hb_sink
(
c
->
output
)
;
}
...
...
@@ -741,7 +741,7 @@ struct LigatureSet
{
return
+
hb_iter
(
ligature
)
|
hb_map
([
&
]
(
const
OffsetTo
<
Ligature
>
&
_
)
->
bool
{
return
(
this
+
_
).
intersects
(
glyphs
);
})
|
hb_map
([
&
]
(
const
OffsetTo
<
Ligature
>
&
_
)
{
return
(
this
+
_
).
intersects
(
glyphs
);
})
|
hb_any
;
}
...
...
@@ -764,7 +764,7 @@ struct LigatureSet
{
return
+
hb_iter
(
ligature
)
|
hb_map
([
&
]
(
const
OffsetTo
<
Ligature
>
&
_
)
->
bool
{
return
(
this
+
_
).
would_apply
(
c
);
})
|
hb_map
([
&
]
(
const
OffsetTo
<
Ligature
>
&
_
)
{
return
(
this
+
_
).
would_apply
(
c
);
})
|
hb_any
;
}
...
...
src/hb-ot-layout-gsubgpos.hh
浏览文件 @
d0df996c
...
...
@@ -708,7 +708,7 @@ static inline bool intersects_array (const hb_set_t *glyphs,
{
return
+
hb_iter
(
values
,
count
)
|
hb_map
([
&
]
(
const
HBUINT16
&
_
)
->
bool
{
return
intersects_func
(
glyphs
,
_
,
intersects_data
);
})
|
hb_map
([
&
]
(
const
HBUINT16
&
_
)
{
return
intersects_func
(
glyphs
,
_
,
intersects_data
);
})
|
hb_any
;
}
...
...
@@ -1371,7 +1371,7 @@ struct RuleSet
{
return
+
hb_iter
(
rule
)
|
hb_map
([
&
]
(
const
OffsetTo
<
Rule
>
&
_
)
->
bool
{
return
(
this
+
_
).
intersects
(
glyphs
,
lookup_context
);
})
|
hb_map
([
&
]
(
const
OffsetTo
<
Rule
>
&
_
)
{
return
(
this
+
_
).
intersects
(
glyphs
,
lookup_context
);
})
|
hb_any
;
}
...
...
@@ -1399,7 +1399,7 @@ struct RuleSet
{
return
+
hb_iter
(
rule
)
|
hb_map
([
&
]
(
const
OffsetTo
<
Rule
>
&
_
)
->
bool
{
return
(
this
+
_
).
would_apply
(
c
,
lookup_context
);
})
|
hb_map
([
&
]
(
const
OffsetTo
<
Rule
>
&
_
)
{
return
(
this
+
_
).
would_apply
(
c
,
lookup_context
);
})
|
hb_any
;
}
...
...
@@ -1410,7 +1410,7 @@ struct RuleSet
TRACE_APPLY
(
this
);
return_trace
(
+
hb_iter
(
rule
)
|
hb_map
([
&
]
(
const
OffsetTo
<
Rule
>
&
_
)
->
bool
{
return
(
this
+
_
).
apply
(
c
,
lookup_context
);
})
|
hb_map
([
&
]
(
const
OffsetTo
<
Rule
>
&
_
)
{
return
(
this
+
_
).
apply
(
c
,
lookup_context
);
})
|
hb_any
)
;
...
...
@@ -1444,7 +1444,7 @@ struct ContextFormat1
+
hb_zip
(
this
+
coverage
,
ruleSet
)
|
hb_filter
(
*
glyphs
,
hb_first
)
|
hb_map
(
hb_second
)
|
hb_map
([
&
]
(
const
OffsetTo
<
RuleSet
>
&
_
)
->
bool
{
return
(
this
+
_
).
intersects
(
glyphs
,
lookup_context
);
})
|
hb_map
([
&
]
(
const
OffsetTo
<
RuleSet
>
&
_
)
{
return
(
this
+
_
).
intersects
(
glyphs
,
lookup_context
);
})
|
hb_any
;
}
...
...
@@ -2022,7 +2022,7 @@ struct ChainRuleSet
{
return
+
hb_iter
(
rule
)
|
hb_map
([
&
]
(
const
OffsetTo
<
ChainRule
>
&
_
)
->
bool
{
return
(
this
+
_
).
intersects
(
glyphs
,
lookup_context
);
})
|
hb_map
([
&
]
(
const
OffsetTo
<
ChainRule
>
&
_
)
{
return
(
this
+
_
).
intersects
(
glyphs
,
lookup_context
);
})
|
hb_any
;
}
...
...
@@ -2046,7 +2046,7 @@ struct ChainRuleSet
{
return
+
hb_iter
(
rule
)
|
hb_map
([
&
]
(
const
OffsetTo
<
ChainRule
>
&
_
)
->
bool
{
return
(
this
+
_
).
would_apply
(
c
,
lookup_context
);
})
|
hb_map
([
&
]
(
const
OffsetTo
<
ChainRule
>
&
_
)
{
return
(
this
+
_
).
would_apply
(
c
,
lookup_context
);
})
|
hb_any
;
}
...
...
@@ -2056,7 +2056,7 @@ struct ChainRuleSet
TRACE_APPLY
(
this
);
return_trace
(
+
hb_iter
(
rule
)
|
hb_map
([
&
]
(
const
OffsetTo
<
ChainRule
>
&
_
)
->
bool
{
return
(
this
+
_
).
apply
(
c
,
lookup_context
);
})
|
hb_map
([
&
]
(
const
OffsetTo
<
ChainRule
>
&
_
)
{
return
(
this
+
_
).
apply
(
c
,
lookup_context
);
})
|
hb_any
)
;
...
...
@@ -2089,7 +2089,7 @@ struct ChainContextFormat1
+
hb_zip
(
this
+
coverage
,
ruleSet
)
|
hb_filter
(
*
glyphs
,
hb_first
)
|
hb_map
(
hb_second
)
|
hb_map
([
&
]
(
const
OffsetTo
<
ChainRuleSet
>
&
_
)
->
bool
{
return
(
this
+
_
).
intersects
(
glyphs
,
lookup_context
);
})
|
hb_map
([
&
]
(
const
OffsetTo
<
ChainRuleSet
>
&
_
)
{
return
(
this
+
_
).
intersects
(
glyphs
,
lookup_context
);
})
|
hb_any
;
}
...
...
src/hb-ot-stat-table.hh
浏览文件 @
d0df996c
...
...
@@ -289,7 +289,7 @@ struct STAT
;
+
get_axis_value_offsets
()
|
hb_map
([
&
]
(
const
OffsetTo
<
AxisValue
>&
_
)
->
const
AxisValue
*
{
return
hb_addressof
(
this
+
_
);
})
|
hb_map
([
&
]
(
const
OffsetTo
<
AxisValue
>&
_
)
{
return
hb_addressof
(
this
+
_
);
})
|
hb_map
(
&
AxisValue
::
get_value_name_id
)
|
hb_sink
(
nameids_to_retain
)
;
...
...
src/hb-ot-var-fvar-table.hh
浏览文件 @
d0df996c
...
...
@@ -290,12 +290,12 @@ struct fvar
;
+
hb_range
((
unsigned
)
instanceCount
)
|
hb_map
([
&
]
(
const
unsigned
_
)
->
unsigned
{
return
get_instance_subfamily_name_id
(
_
);
})
|
hb_map
([
&
]
(
const
unsigned
_
)
{
return
get_instance_subfamily_name_id
(
_
);
})
|
hb_sink
(
nameids
)
;
+
hb_range
((
unsigned
)
instanceCount
)
|
hb_map
([
&
]
(
const
unsigned
_
)
->
unsigned
{
return
get_instance_postscript_name_id
(
_
);
})
|
hb_map
([
&
]
(
const
unsigned
_
)
{
return
get_instance_postscript_name_id
(
_
);
})
|
hb_sink
(
nameids
)
;
}
...
...
src/test-iter.cc
浏览文件 @
d0df996c
...
...
@@ -203,8 +203,8 @@ main (int argc, char **argv)
;
+
hb_iter
(
src
)
|
hb_map
([
&
]
(
int
i
)
->
int
{
return
1
;
})
|
hb_reduce
([
&
]
(
int
acc
,
int
value
)
->
int
{
return
acc
;
},
2
)
|
hb_map
([
&
]
(
int
i
)
{
return
1
;
})
|
hb_reduce
([
&
]
(
int
acc
,
int
value
)
{
return
acc
;
},
2
)
;
using
map_pair_t
=
hb_item_type
<
hb_map_t
>
;
...
...
@@ -251,8 +251,8 @@ main (int argc, char **argv)
unsigned
int
temp3
=
0
;
+
hb_iter
(
src
)
|
hb_map
([
&
]
(
int
i
)
->
int
{
return
++
temp3
;
})
|
hb_reduce
([
&
]
(
float
acc
,
int
value
)
->
float
{
return
acc
+
value
;
},
0
)
|
hb_map
([
&
]
(
int
i
)
{
return
++
temp3
;
})
|
hb_reduce
([
&
]
(
float
acc
,
int
value
)
{
return
acc
+
value
;
},
0
)
;
hb_map_destroy
(
result
);
...
...
src/test-meta.cc
浏览文件 @
d0df996c
...
...
@@ -32,7 +32,6 @@
int
main
(
int
argc
,
char
**
argv
)
{
static_assert
(
hb_is_convertible
(
void
,
void
),
""
);
static_assert
(
hb_is_convertible
(
void
,
const
void
),
""
);
static_assert
(
hb_is_convertible
(
const
void
,
void
),
""
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录