summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJohn Hodge <tpg@mutabah.net>2016-06-08 12:46:24 +0800
committerJohn Hodge <tpg@mutabah.net>2016-06-08 12:46:24 +0800
commit5961266133f5e0cbcd57403021086c788d732ec1 (patch)
tree7a1233503921e6f9ed0e71dd0b3ada0196b19441 /src
parent40071822728499b9028400ddac3cd32fb884b2a0 (diff)
downloadmrust-5961266133f5e0cbcd57403021086c788d732ec1.tar.gz
Commenting
Diffstat (limited to 'src')
-rw-r--r--src/expand/format_args.cpp2
-rw-r--r--src/hir_typeck/expr.cpp5
2 files changed, 5 insertions, 2 deletions
diff --git a/src/expand/format_args.cpp b/src/expand/format_args.cpp
index 6f9ea9ec..dacef203 100644
--- a/src/expand/format_args.cpp
+++ b/src/expand/format_args.cpp
@@ -43,7 +43,7 @@ namespace {
unsigned int arg_index;
const char* trait_name;
- // TODO: Support case where this hasn't been edited
+ // TODO: Support case where this hasn't been edited (telling the formatter that it has nothing to apply)
FmtArgs args;
};
diff --git a/src/hir_typeck/expr.cpp b/src/hir_typeck/expr.cpp
index b15abc4d..e60c4350 100644
--- a/src/hir_typeck/expr.cpp
+++ b/src/hir_typeck/expr.cpp
@@ -2193,7 +2193,7 @@ namespace {
ERROR(sp, E0000, "Omitted type parameter with no default in " << path);
}
else {
- // TODO: What if this contains a generic param? (is that valid?)
+ // TODO: What if this contains a generic param? (is that valid? Self maybe, what about others?)
params.m_types.push_back( typ.m_default.clone() );
}
}
@@ -2216,6 +2216,9 @@ namespace {
TU_MATCH(::HIR::Path::Data, (path.m_data), (e),
(Generic,
+ // TODO: This could also point to an enum variant, or to a struct constructor
+ // - Current code only handles functions.
+
const auto& fcn = this->context.m_crate.get_function_by_path(sp, e.m_path);
this->fix_param_count(sp, path, fcn.m_params, e.m_params);
fcn_ptr = &fcn;