Skip to content

Commit f187d64

Browse files
committed
[flang][nfc] Fix comments, remove needless API, tweak script
* Remove an unimplemented and unused member function declaration * Remove a misleading comment about an unrelated constraint number * Fix a comment * Add f18 crash message to "flang" driver script Differential Revision: https://reviews.llvm.org/D95180
1 parent 520b5ec commit f187d64

File tree

4 files changed

+8
-4
lines changed

4 files changed

+8
-4
lines changed

flang/include/flang/Parser/provenance.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,6 @@ class AllSources {
173173
std::string GetPath(Provenance) const; // __FILE__
174174
int GetLineNumber(Provenance) const; // __LINE__
175175
Provenance CompilerInsertionProvenance(char ch);
176-
Provenance CompilerInsertionProvenance(const char *, std::size_t);
177176
ProvenanceRange IntersectionWithSourceFiles(ProvenanceRange) const;
178177
llvm::raw_ostream &Dump(llvm::raw_ostream &) const;
179178

flang/include/flang/Semantics/symbol.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,7 @@ class TypeParamDetails {
356356
};
357357

358358
// Record the USE of a symbol: location is where (USE statement or renaming);
359-
// symbol is the USEd module.
359+
// symbol is in the USEd module.
360360
class UseDetails {
361361
public:
362362
UseDetails(const SourceName &location, const Symbol &symbol)

flang/lib/Semantics/assignment.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ void AssignmentContext::Analyze(const parser::AssignmentStmt &stmt) {
7070
const Scope &scope{context_.FindScope(lhsLoc)};
7171
if (auto whyNot{WhyNotModifiable(lhsLoc, lhs, scope, true)}) {
7272
if (auto *msg{Say(lhsLoc,
73-
"Left-hand side of assignment is not modifiable"_err_en_US)}) { // C1158
73+
"Left-hand side of assignment is not modifiable"_err_en_US)}) {
7474
msg->Attach(*whyNot);
7575
}
7676
}

flang/tools/f18/flang

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,9 @@ module_dir=$wd/include/flang
1212
if [[ ! -d $module_dir ]]; then
1313
module_dir=$wd/tools/flang/include/flang
1414
fi
15-
$wd/bin/f18 -module-suffix .f18.mod -intrinsic-module-directory $module_dir "$@"
15+
opts="-module-suffix .f18.mod -intrinsic-module-directory $module_dir"
16+
if ! $wd/bin/f18 $opts "$@"
17+
then status=$?
18+
echo flang: in $PWD, f18 failed with exit status $status: $wd/bin/f18 $opts "$@" >&2
19+
exit $status
20+
fi

0 commit comments

Comments
 (0)