mirror of
https://github.com/Mercury-Language/mercury.git
synced 2026-04-16 01:43:35 +00:00
Minor documentation fixes.
This commit is contained in:
@@ -136,7 +136,7 @@ add_pragma_foreign_enum(ModuleInfo, ImsItem, !TypeCtorForeignEnumMap,
|
||||
OoMMercuryForeignTagPairs, Context, _SeqNum),
|
||||
% Here we construct ItemPragmaInfo just to test whether this pragma
|
||||
% was in the interface. Unfortunately, while we *could* avoid this
|
||||
% (e.g. by making making report_if_pragma_is_wrongly_in_interface work
|
||||
% (e.g. by making report_if_pragma_is_wrongly_in_interface work
|
||||
% not on full pragmas but on pragma kinds, a flattened-to-an-enum
|
||||
% form of pragmas), the cost in increased code complexity is
|
||||
% not worth it.
|
||||
|
||||
@@ -712,7 +712,7 @@ check_type_ctor_defns(InsistOnDefn, ModuleName,
|
||||
% TypeCtor is NOT defined as a solver, equivalence, du or foreign type,
|
||||
% and it is NOT declared either as a solver or as a nonsolver type.
|
||||
% This means it has no type definition whatsoever. The only way
|
||||
% we can get here is is it has any foreign enum definitions.
|
||||
% we can get here is if it has any foreign enum definitions.
|
||||
list.foldl(
|
||||
report_foreign_enum_for_undefined_type(TypeCtor, "undeclared"),
|
||||
ImpEnums, !Specs)
|
||||
|
||||
@@ -459,7 +459,7 @@ bad_instance_type_msg(ClassId, InstanceDefn, EndPieces, Kind) = Spec :-
|
||||
% would not make sense.
|
||||
InstanceTypes = InstanceDefn ^ instdefn_orig_types
|
||||
),
|
||||
% XXX Removing the module qualification from the type type constructors
|
||||
% XXX Removing the module qualification from the type constructors
|
||||
% in InstanceTypes before converting them to strings would make
|
||||
% the error message less cluttered.
|
||||
InstanceTypesString = mercury_type_list_to_string(InstanceVarSet,
|
||||
|
||||
@@ -903,7 +903,7 @@ do_dead_proc_eliminate(ElimOptImported, !.Needed, !ModuleInfo) :-
|
||||
TypeCtorGenInfos),
|
||||
module_info_set_type_ctor_gen_infos(TypeCtorGenInfos, !ModuleInfo),
|
||||
|
||||
% We could also eliminate eliminate table structs, but we don't do that
|
||||
% We could also eliminate table structs, but we don't do that
|
||||
% yet, because some references to such structs are currently visible
|
||||
% only in C code embedded in compiler-generated foreign_procs, and
|
||||
% therefore we might accidentally create dangling references.
|
||||
|
||||
@@ -382,7 +382,7 @@ check_goal_for_exceptions_2(SCC, VarTypes, GoalExpr, GoalInfo,
|
||||
;
|
||||
GoalExpr = call_foreign_proc(Attributes, _, _, _, _, _, _),
|
||||
|
||||
% NOTE: for --intermodule-analysis the results for for foreign_procs
|
||||
% NOTE: for --intermodule-analysis the results for foreign_procs
|
||||
% will *always* be optimal (since we always rely on user annotation),
|
||||
% so there's nothing to do here.
|
||||
MayCallMercury = get_may_call_mercury(Attributes),
|
||||
|
||||
@@ -1635,7 +1635,7 @@ need_unify(ModuleInfo, UnusedVars, Unify, Changed) :-
|
||||
Unify = deconstruct(LVar, _, ArgVars, ArgModes, CanFail, _CanCGC),
|
||||
not list.member(LVar, UnusedVars),
|
||||
(
|
||||
% Are any of the args unused? If so, we need to to fix up the
|
||||
% Are any of the args unused? If so, we need to fix up the
|
||||
% goal_info.
|
||||
CanFail = cannot_fail,
|
||||
check_deconstruct_args(ModuleInfo, UnusedVars, ArgVars, ArgModes,
|
||||
|
||||
Reference in New Issue
Block a user