mirror of
https://gitea.invidious.io/iv-org/shard-crystal-db.git
synced 2024-08-15 00:53:32 +00:00
Use forall
This commit is contained in:
parent
751be7aa6a
commit
ae6a68f00e
1 changed files with 2 additions and 2 deletions
|
@ -75,7 +75,7 @@ module DB
|
||||||
end
|
end
|
||||||
|
|
||||||
# Reads the next column value as a **type**
|
# Reads the next column value as a **type**
|
||||||
def read(type : T.class) : T
|
def read(type : T.class) : T forall T
|
||||||
read.as(T)
|
read.as(T)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -84,7 +84,7 @@ module DB
|
||||||
internal_read(*types)
|
internal_read(*types)
|
||||||
end
|
end
|
||||||
|
|
||||||
private def internal_read(*types : *T)
|
private def internal_read(*types : *T) forall T
|
||||||
{% begin %}
|
{% begin %}
|
||||||
Tuple.new(
|
Tuple.new(
|
||||||
{% for type in T %}
|
{% for type in T %}
|
||||||
|
|
Loading…
Reference in a new issue