summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/mir/from_hir.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mir/from_hir.cpp b/src/mir/from_hir.cpp
index 500db069..10f9768d 100644
--- a/src/mir/from_hir.cpp
+++ b/src/mir/from_hir.cpp
@@ -930,7 +930,8 @@ namespace {
BUG(node.span(), "Cannot cast to " << ty_out << " from " << ty_in);
}
)
- else if( de == ::HIR::CoreType::Usize && ty_in.m_data.is_Pointer() ) {
+ // NOTE: Valid for all integer types
+ else if( ty_in.m_data.is_Pointer() ) {
// TODO: Only valid for T: Sized?
}
else if( de == ::HIR::CoreType::Usize && ty_in.m_data.is_Function() ) {